Gets a directory items content. More...
Gets a directory items content.
Public Member Methods | |
DirectoryIterator () | |
Default constructor. More... | |
DirectoryIterator (PCChar8 directoryPath) | |
Constructor. More... | |
void | OpenDirectory (PCChar8 directoryPath) |
Open a directory. More... | |
bool | TryOpenDirectory (PCChar8 directoryPath) |
Try to Open a directory. More... | |
bool | FindNextSubDirectory (BaseStaticString &subDirectoryName) |
Find a next item in the current directory. More... | |
bool | FindNextFile (BaseStaticString &fileName, UInt64 *fileSize=NULL) |
Find a next item in the current directory. More... | |
const BaseStaticString & | GetDirectoryPath () const |
Gets the current directory path. More... | |
String | GetDirectoryPath (PCChar8 fileName) const |
Gets a sub directory path. More... | |
~DirectoryIterator () | |
Default destructor. More... | |
Default constructor.
DirectoryIterator | ( | PCChar8 | directoryPath | ) |
Constructor.
directoryPath | Directory path where to iterate. |
~DirectoryIterator | ( | ) |
Default destructor.
bool FindNextFile | ( | BaseStaticString & | fileName, |
UInt64 * | fileSize = NULL |
||
) |
Find a next item in the current directory.
fileName | [in, out] if found, the fileName. |
fileSize | [in, out] (Optional) if found return the file size of the file. Default = NULL. |
bool FindNextSubDirectory | ( | BaseStaticString & | subDirectoryName | ) |
Find a next item in the current directory.
subDirectoryName | if found, the next item. |
const BaseStaticString& GetDirectoryPath | ( | ) | const |
Gets the current directory path.
Gets a sub directory path.
fileName | file name to build a path with. |
void OpenDirectory | ( | PCChar8 | directoryPath | ) |
Open a directory.
directoryPath | Directory path where to iterate. |
Can be called whenever it's necessary to change directory. Will close the current context and open a new one.
bool TryOpenDirectory | ( | PCChar8 | directoryPath | ) |
Try to Open a directory.
directoryPath | Directory path where to iterate. |
Can be called whenever it's necessary to change directory. Will close the current context and open a new one.