TDriveUnit Class Reference
Drive numbers and letters.
A drive may be represented by either an integer between zero and twenty five inclusive, or by a buffer descriptor containing a character between "A" and "Z" inclusive, followed by a colon. This class encapsulates both representations. An instance of this class is constructed specifying either the drive number or the drive letter and may be converted between the two representations.
Constructor & Destructor Documentation
TDriveUnit(TInt)
IMPORT_C | TDriveUnit | ( | TInt | aDrive | ) | |
Constructor taking a drive number.
-
panic
- FSCLIENT 0 if aDrive is greater than or equal to KMaxDrives or less than 0.
KMaxDrives
Parameters
TInt aDrive | The drive number. |
TDriveUnit(const TDesC &)
IMPORT_C | TDriveUnit | ( | const TDesC & | aDrive | ) | |
Constructor taking a drive letter.
-
panic
- FSCLIENT 1 if the drive letter is invalid, i.e. does not correspond to a drive number.
RFs::CharToDrive
Parameters
const TDesC & aDrive | A descriptor containing text whose first character is the drive letter. Can be upper or lower case. Trailing text is ignored. |
Member Functions Documentation
Name()
Gets the drive unit as text.
The drive letter is returned with a trailing colon.
operator TInt()
operator TInt | ( | ) | const [inline] |
Converts the drive unit to an integer value.
operator=(TInt)
Assigns the drive number to the drive unit
-
panic
- FSCLIENT 0 if aDrive is greater than or equal to KMaxDrives.
KMaxDrives
Parameters
TInt aDrive | The new drive number. |
operator=(const TDesC &)
Assigns a drive letter to the drive unit.
The letter must be between A and Z or a panic is raised. Any trailing text within the descriptor is ignored.
-
panic
- FSCLIENT 1 if the drive letter is invalid, i.e. does not correspond to a drive number.
RFs::CharToDrive
Parameters
const TDesC & aDrive | Descriptor containing text whose first character is the drive letter. It can be upper or lower case. |
Member Data Documentation
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.