[]Struct gio::FileEnumerator

pub struct FileEnumerator(_, _);

FileEnumerator allows you to operate on a set of GFiles, returning a FileInfo structure for each file enumerated (e.g. File::enumerate_children will return a FileEnumerator for each of the children within a directory).

To get the next file's information from a FileEnumerator, use FileEnumeratorExt::next_file or its asynchronous version, FileEnumeratorExt::next_files_async. Note that the asynchronous version will return a list of GFileInfos, whereas the synchronous will only return the next file in the enumerator.

The ordering of returned files is unspecified for non-Unix platforms; for more information, see glib::Dir::read_name. On Unix, when operating on local files, returned files will be sorted by inode number. Effectively you can assume that the ordering of returned files will be stable between successive calls (and applications) assuming the directory is unchanged.

If your application needs a specific ordering, such as by name or modification time, you will have to implement that in your application code.

To close a FileEnumerator, use FileEnumeratorExt::close, or its asynchronous version, FileEnumeratorExt::close_async. Once a FileEnumerator is closed, no further actions may be performed on it, and it should be freed with gobject::ObjectExt::unref.

Implements

FileEnumeratorExt, glib::object::ObjectExt

Trait Implementations

impl Clone for FileEnumerator

impl Debug for FileEnumerator

impl Display for FileEnumerator[src]

impl Eq for FileEnumerator

impl Hash for FileEnumerator

impl Iterator for FileEnumerator[src]

type Item = Result<FileInfo, Error>

The type of the elements being iterated over.

impl Ord for FileEnumerator

impl<T: ObjectType> PartialEq<T> for FileEnumerator

impl<T: ObjectType> PartialOrd<T> for FileEnumerator

impl StaticType for FileEnumerator

Auto Trait Implementations

impl RefUnwindSafe for FileEnumerator

impl !Send for FileEnumerator

impl !Sync for FileEnumerator

impl Unpin for FileEnumerator

impl UnwindSafe for FileEnumerator

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<Super, Sub> CanDowncast<Sub> for Super where
    Sub: IsA<Super>,
    Super: IsA<Super>, 

impl<T> Cast for T where
    T: ObjectType, 

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

impl<T> ObjectExt for T where
    T: ObjectType, 

impl<'a, T> ToGlibContainerFromSlice<'a, *const GList> for T where
    T: GlibPtrDefault + ToGlibPtr<'a, <T as GlibPtrDefault>::GlibType>, 

type Storage = (Option<List>, Vec<Stash<'a, <T as GlibPtrDefault>::GlibType, T>>)

impl<'a, T> ToGlibContainerFromSlice<'a, *const GPtrArray> for T where
    T: GlibPtrDefault + ToGlibPtr<'a, <T as GlibPtrDefault>::GlibType>, 

type Storage = (Option<PtrArray>, Vec<Stash<'a, <T as GlibPtrDefault>::GlibType, T>>)

impl<'a, T> ToGlibContainerFromSlice<'a, *mut GArray> for T where
    T: GlibPtrDefault + ToGlibPtr<'a, <T as GlibPtrDefault>::GlibType>, 

type Storage = (Option<Array>, Vec<Stash<'a, <T as GlibPtrDefault>::GlibType, T>>)

impl<'a, T> ToGlibContainerFromSlice<'a, *mut GList> for T where
    T: GlibPtrDefault + ToGlibPtr<'a, <T as GlibPtrDefault>::GlibType>, 

type Storage = (Option<List>, Vec<Stash<'a, <T as GlibPtrDefault>::GlibType, T>>)

impl<'a, T> ToGlibContainerFromSlice<'a, *mut GPtrArray> for T where
    T: GlibPtrDefault + ToGlibPtr<'a, <T as GlibPtrDefault>::GlibType>, 

type Storage = (Option<PtrArray>, Vec<Stash<'a, <T as GlibPtrDefault>::GlibType, T>>)

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T> ToValue for T where
    T: SetValue + ?Sized

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.