Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
AndroidAbstractFileEngineIterator Class Reference
+ Inheritance diagram for AndroidAbstractFileEngineIterator:
+ Collaboration diagram for AndroidAbstractFileEngineIterator:

Public Member Functions

 AndroidAbstractFileEngineIterator (QDir::Filters filters, const QStringList &nameFilters, const QString &path)
 
QFileInfo currentFileInfo () const override
 The virtual function returns a QFileInfo for the current directory entry.
 
QString currentFileName () const override
 This pure virtual function returns the name of the current directory entry, excluding the path.
 
QString currentFilePath () const override
 Returns the path to the current directory entry.
 
bool hasNext () const override
 This pure virtual function returns true if there is at least one more entry in the current directory (i.e., the iterator path is valid and accessible, and the iterator has not reached the end of the entry list).
 
QString next () override
 This pure virtual function advances the iterator to the next directory entry, and returns the file path to the current entry.
 
- Public Member Functions inherited from QAbstractFileEngineIterator
 QAbstractFileEngineIterator (QDir::Filters filters, const QStringList &nameFilters)
 Constructs a QAbstractFileEngineIterator, using the entry filters filters, and wildcard name filters nameFilters.
 
virtual ~QAbstractFileEngineIterator ()
 Destroys the QAbstractFileEngineIterator.
 
virtual QString next ()=0
 This pure virtual function advances the iterator to the next directory entry, and returns the file path to the current entry.
 
virtual bool hasNext () const =0
 This pure virtual function returns true if there is at least one more entry in the current directory (i.e., the iterator path is valid and accessible, and the iterator has not reached the end of the entry list).
 
QString path () const
 Returns the path for this iterator.
 
QStringList nameFilters () const
 Returns the name filters for this iterator.
 
QDir::Filters filters () const
 Returns the entry filters for this iterator.
 
virtual QString currentFileName () const =0
 This pure virtual function returns the name of the current directory entry, excluding the path.
 
virtual QFileInfo currentFileInfo () const
 The virtual function returns a QFileInfo for the current directory entry.
 
virtual QString currentFilePath () const
 Returns the path to the current directory entry.
 

Additional Inherited Members

- Protected Types inherited from QAbstractFileEngineIterator
enum  EntryInfoType
 
- Protected Member Functions inherited from QAbstractFileEngineIterator
virtual QVariant entryInfo (EntryInfoType type) const
 

Detailed Description

Definition at line 168 of file qandroidassetsfileenginehandler.cpp.

Constructor & Destructor Documentation

◆ AndroidAbstractFileEngineIterator()

AndroidAbstractFileEngineIterator::AndroidAbstractFileEngineIterator ( QDir::Filters  filters,
const QStringList nameFilters,
const QString path 
)
inline

Definition at line 171 of file qandroidassetsfileenginehandler.cpp.

References cleanedAssetPath(), and FolderIterator::fromCache().

+ Here is the call graph for this function:

Member Function Documentation

◆ currentFileInfo()

QFileInfo AndroidAbstractFileEngineIterator::currentFileInfo ( ) const
inlineoverridevirtual

The virtual function returns a QFileInfo for the current directory entry.

This function is provided for convenience. It can also be slightly faster than creating a QFileInfo object yourself, as the object returned by this function might contain cached information that QFileInfo otherwise would have to access through the file engine.

See also
currentFileName()

Reimplemented from QAbstractFileEngineIterator.

Definition at line 179 of file qandroidassetsfileenginehandler.cpp.

References currentFilePath().

+ Here is the call graph for this function:

◆ currentFileName()

QString AndroidAbstractFileEngineIterator::currentFileName ( ) const
inlineoverridevirtual

This pure virtual function returns the name of the current directory entry, excluding the path.

See also
currentFilePath()

Implements QAbstractFileEngineIterator.

Definition at line 184 of file qandroidassetsfileenginehandler.cpp.

References FolderIterator::currentFileName().

+ Here is the call graph for this function:

◆ currentFilePath()

QString AndroidAbstractFileEngineIterator::currentFilePath ( ) const
inlineoverridevirtual

Returns the path to the current directory entry.

It's the same as prepending path() to the return value of currentFileName().

See also
currentFileName()

Reimplemented from QAbstractFileEngineIterator.

Definition at line 191 of file qandroidassetsfileenginehandler.cpp.

References FolderIterator::currentFilePath().

Referenced by currentFileInfo().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ hasNext()

bool AndroidAbstractFileEngineIterator::hasNext ( ) const
inlineoverridevirtual

This pure virtual function returns true if there is at least one more entry in the current directory (i.e., the iterator path is valid and accessible, and the iterator has not reached the end of the entry list).

See also
QDirIterator::hasNext()

Implements QAbstractFileEngineIterator.

Definition at line 198 of file qandroidassetsfileenginehandler.cpp.

References FolderIterator::hasNext().

+ Here is the call graph for this function:

◆ next()

QString AndroidAbstractFileEngineIterator::next ( )
inlineoverridevirtual

This pure virtual function advances the iterator to the next directory entry, and returns the file path to the current entry.

This function can optionally make use of nameFilters() and filters() to optimize its performance.

Reimplement this function in a subclass to advance the iterator.

See also
QDirIterator::next()

Implements QAbstractFileEngineIterator.

Definition at line 205 of file qandroidassetsfileenginehandler.cpp.

References FolderIterator::next().

+ Here is the call graph for this function:

The documentation for this class was generated from the following file: