|
||
class TParse : public TParseBase;
Parses filenames.
The class uses the full filename structure supported by Symbian OS.
TParse works by using the Set()
function to set up the filename to be parsed. Then, various getter functions defined in the base class, TParseBase
, such as: FullName()
, Drive()
, Path()
, DriveAndPath()
, Name()
, Ext()
and NameAndExt()
may be used to retrieve path components.
There are a number of restrictions to valid path components, which are described in guide documentation.
TParseBase
- Base class for file name parsing
TParse
- Parses filenames
Defined in TParse
:
NameBuf()
Gets a reference to the descriptor containing the file specification passed to the constructor of this objectNameBufC()
Gets a const reference to the descriptor containing the file specification passed to the constructor of this objectSet()
Parses a file specification, allowing wildcards in the filename and extensionSetNoWild()
Parses a file specification; disallows wildcards in any part of the file name or extensionTParse()
Default constructorInherited from TParseBase
:
AddDir()
Adds a single directory onto the end of the path in the fully parsed specificationDrive()
Gets the drive letterDriveAndPath()
Gets the drive letter and pathDrivePresent()
Tests whether a drive is presentExt()
Gets the extensionExtPresent()
Tests whether an extension is presentFullName()
Gets the complete file specificationIsExtWild()
Tests whether the extension in the fully parsed specification contains one or more wildcard charactersIsKMatchAny()
Tests whether the name or the extension contains asterisk wildcardsIsKMatchOne()
Tests whether the name or the extension contains a question mark wildcardIsNameWild()
Tests whether the filename in the fully parsed specification contains one or more wildcard charactersIsRoot()
Tests whether the path in the fully parsed specification is the root directoryIsWild()
Tests whether the filename or the extension in the fully parsed specification contains one or more wildcard charactersName()
Gets the filenameNameAndExt()
Gets the filename and extensionNameOrExtPresent()
Tests whether a filename or an extension are presentNamePresent()
Tests whether a file name is presentPath()
Gets the pathPathPresent()
Tests whether a path is presentPopDir()
Removes the last directory from the path in the fully parsed specificationiMod
IMPORT_C TInt Set(const TDesC &aName, const TDesC *aRelated, const TDesC *aDefault);
Parses a file specification, allowing wildcards in the filename and extension.
This function sets up the TParse object so that it can be used to provide useful information.
|
|
IMPORT_C TInt SetNoWild(const TDesC &aName, const TDesC *aRelated, const TDesC *aDefault);
Parses a file specification; disallows wildcards in any part of the file name or extension.
If you need to specify wildcards use Set()
. Otherwise, this function behaves in the same way as Set()
.
|
|
protected: virtual IMPORT_C TDes &NameBuf();
Gets a reference to the descriptor containing the file specification passed to the constructor of this object.
|
protected: virtual IMPORT_C const TDesC &NameBufC() const;
Gets a const reference to the descriptor containing the file specification passed to the constructor of this object.
|