pub trait FileExt: 'static {
Show 74 methods fn append_to<P: IsA<Cancellable>>(
        &self,
        flags: FileCreateFlags,
        cancellable: Option<&P>
    ) -> Result<FileOutputStream, Error>; fn append_to_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileOutputStream, Error>) + Send + 'static>(
        &self,
        flags: FileCreateFlags,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn copy<P: IsA<File>, Q: IsA<Cancellable>>(
        &self,
        destination: &P,
        flags: FileCopyFlags,
        cancellable: Option<&Q>,
        progress_callback: Option<&mut dyn FnMut(i64, i64)>
    ) -> Result<(), Error>; fn copy_attributes<P: IsA<File>, Q: IsA<Cancellable>>(
        &self,
        destination: &P,
        flags: FileCopyFlags,
        cancellable: Option<&Q>
    ) -> Result<(), Error>; fn create<P: IsA<Cancellable>>(
        &self,
        flags: FileCreateFlags,
        cancellable: Option<&P>
    ) -> Result<FileOutputStream, Error>; fn create_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileOutputStream, Error>) + Send + 'static>(
        &self,
        flags: FileCreateFlags,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn create_readwrite<P: IsA<Cancellable>>(
        &self,
        flags: FileCreateFlags,
        cancellable: Option<&P>
    ) -> Result<FileIOStream, Error>; fn create_readwrite_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileIOStream, Error>) + Send + 'static>(
        &self,
        flags: FileCreateFlags,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn delete<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn delete_async<P: IsA<Cancellable>, Q: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn dup(&self) -> Option<File>; fn eject_mountable_with_operation<P: IsA<MountOperation>, Q: IsA<Cancellable>, R: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        flags: MountUnmountFlags,
        mount_operation: Option<&P>,
        cancellable: Option<&Q>,
        callback: R
    ); fn equal<P: IsA<File>>(&self, file2: &P) -> bool; fn find_enclosing_mount<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<Mount, Error>; fn get_basename(&self) -> Option<PathBuf>; fn get_child<P: AsRef<Path>>(&self, name: P) -> Option<File>; fn get_child_for_display_name(
        &self,
        display_name: &str
    ) -> Result<File, Error>; fn get_parent(&self) -> Option<File>; fn get_parse_name(&self) -> Option<GString>; fn get_path(&self) -> Option<PathBuf>; fn get_relative_path<P: IsA<File>>(&self, descendant: &P) -> Option<PathBuf>; fn get_uri(&self) -> GString; fn get_uri_scheme(&self) -> GString; fn has_parent<P: IsA<File>>(&self, parent: Option<&P>) -> bool; fn has_prefix<P: IsA<File>>(&self, prefix: &P) -> bool; fn has_uri_scheme(&self, uri_scheme: &str) -> bool; fn is_native(&self) -> bool; fn load_contents<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<(Vec<u8>, GString), Error>; fn load_contents_async<P: IsA<Cancellable>, Q: FnOnce(Result<(Vec<u8>, GString), Error>) + Send + 'static>(
        &self,
        cancellable: Option<&P>,
        callback: Q
    ); fn make_directory<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn make_directory_async<P: IsA<Cancellable>, Q: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn make_directory_with_parents<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn make_symbolic_link<P: AsRef<Path>, Q: IsA<Cancellable>>(
        &self,
        symlink_value: P,
        cancellable: Option<&Q>
    ) -> Result<(), Error>; fn measure_disk_usage<P: IsA<Cancellable>>(
        &self,
        flags: FileMeasureFlags,
        cancellable: Option<&P>,
        progress_callback: Option<Box<dyn Fn(bool, u64, u64, u64) + 'static>>
    ) -> Result<(u64, u64, u64), Error>; fn monitor<P: IsA<Cancellable>>(
        &self,
        flags: FileMonitorFlags,
        cancellable: Option<&P>
    ) -> Result<FileMonitor, Error>; fn monitor_directory<P: IsA<Cancellable>>(
        &self,
        flags: FileMonitorFlags,
        cancellable: Option<&P>
    ) -> Result<FileMonitor, Error>; fn monitor_file<P: IsA<Cancellable>>(
        &self,
        flags: FileMonitorFlags,
        cancellable: Option<&P>
    ) -> Result<FileMonitor, Error>; fn mount_enclosing_volume<P: IsA<MountOperation>, Q: IsA<Cancellable>, R: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        flags: MountMountFlags,
        mount_operation: Option<&P>,
        cancellable: Option<&Q>,
        callback: R
    ); fn mount_mountable<P: IsA<MountOperation>, Q: IsA<Cancellable>, R: FnOnce(Result<File, Error>) + Send + 'static>(
        &self,
        flags: MountMountFlags,
        mount_operation: Option<&P>,
        cancellable: Option<&Q>,
        callback: R
    ); fn move_<P: IsA<File>, Q: IsA<Cancellable>>(
        &self,
        destination: &P,
        flags: FileCopyFlags,
        cancellable: Option<&Q>,
        progress_callback: Option<&mut dyn FnMut(i64, i64)>
    ) -> Result<(), Error>; fn open_readwrite<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<FileIOStream, Error>; fn open_readwrite_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileIOStream, Error>) + Send + 'static>(
        &self,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn poll_mountable<P: IsA<Cancellable>, Q: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        cancellable: Option<&P>,
        callback: Q
    ); fn query_default_handler<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<AppInfo, Error>; fn query_exists<P: IsA<Cancellable>>(&self, cancellable: Option<&P>) -> bool; fn query_file_type<P: IsA<Cancellable>>(
        &self,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> FileType; fn query_filesystem_info<P: IsA<Cancellable>>(
        &self,
        attributes: &str,
        cancellable: Option<&P>
    ) -> Result<FileInfo, Error>; fn query_filesystem_info_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileInfo, Error>) + Send + 'static>(
        &self,
        attributes: &str,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn query_info<P: IsA<Cancellable>>(
        &self,
        attributes: &str,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> Result<FileInfo, Error>; fn query_info_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileInfo, Error>) + Send + 'static>(
        &self,
        attributes: &str,
        flags: FileQueryInfoFlags,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn read<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<FileInputStream, Error>; fn read_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileInputStream, Error>) + Send + 'static>(
        &self,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn replace<P: IsA<Cancellable>>(
        &self,
        etag: Option<&str>,
        make_backup: bool,
        flags: FileCreateFlags,
        cancellable: Option<&P>
    ) -> Result<FileOutputStream, Error>; fn replace_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileOutputStream, Error>) + Send + 'static>(
        &self,
        etag: Option<&str>,
        make_backup: bool,
        flags: FileCreateFlags,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn replace_contents<P: IsA<Cancellable>>(
        &self,
        contents: &[u8],
        etag: Option<&str>,
        make_backup: bool,
        flags: FileCreateFlags,
        cancellable: Option<&P>
    ) -> Result<GString, Error>; fn replace_readwrite<P: IsA<Cancellable>>(
        &self,
        etag: Option<&str>,
        make_backup: bool,
        flags: FileCreateFlags,
        cancellable: Option<&P>
    ) -> Result<FileIOStream, Error>; fn replace_readwrite_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileIOStream, Error>) + Send + 'static>(
        &self,
        etag: Option<&str>,
        make_backup: bool,
        flags: FileCreateFlags,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn resolve_relative_path<P: AsRef<Path>>(
        &self,
        relative_path: P
    ) -> Option<File>; fn set_attribute_byte_string<P: IsA<Cancellable>>(
        &self,
        attribute: &str,
        value: &str,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn set_attribute_int32<P: IsA<Cancellable>>(
        &self,
        attribute: &str,
        value: i32,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn set_attribute_int64<P: IsA<Cancellable>>(
        &self,
        attribute: &str,
        value: i64,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn set_attribute_string<P: IsA<Cancellable>>(
        &self,
        attribute: &str,
        value: &str,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn set_attribute_uint32<P: IsA<Cancellable>>(
        &self,
        attribute: &str,
        value: u32,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn set_attribute_uint64<P: IsA<Cancellable>>(
        &self,
        attribute: &str,
        value: u64,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn set_attributes_async<P: IsA<Cancellable>, Q: FnOnce(Result<FileInfo, Error>) + Send + 'static>(
        &self,
        info: &FileInfo,
        flags: FileQueryInfoFlags,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn set_attributes_from_info<P: IsA<Cancellable>>(
        &self,
        info: &FileInfo,
        flags: FileQueryInfoFlags,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn set_display_name<P: IsA<Cancellable>>(
        &self,
        display_name: &str,
        cancellable: Option<&P>
    ) -> Result<File, Error>; fn set_display_name_async<P: IsA<Cancellable>, Q: FnOnce(Result<File, Error>) + Send + 'static>(
        &self,
        display_name: &str,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn start_mountable<P: IsA<MountOperation>, Q: IsA<Cancellable>, R: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        flags: DriveStartFlags,
        start_operation: Option<&P>,
        cancellable: Option<&Q>,
        callback: R
    ); fn stop_mountable<P: IsA<MountOperation>, Q: IsA<Cancellable>, R: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        flags: MountUnmountFlags,
        mount_operation: Option<&P>,
        cancellable: Option<&Q>,
        callback: R
    ); fn supports_thread_contexts(&self) -> bool; fn trash<P: IsA<Cancellable>>(
        &self,
        cancellable: Option<&P>
    ) -> Result<(), Error>; fn trash_async<P: IsA<Cancellable>, Q: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        io_priority: Priority,
        cancellable: Option<&P>,
        callback: Q
    ); fn unmount_mountable_with_operation<P: IsA<MountOperation>, Q: IsA<Cancellable>, R: FnOnce(Result<(), Error>) + Send + 'static>(
        &self,
        flags: MountUnmountFlags,
        mount_operation: Option<&P>,
        cancellable: Option<&Q>,
        callback: R
    );
}

Required Methods

Implementors