CFileBase Class Reference

#include <f32file.h>

Link against: efsrv.lib

class CFileBase : public CBase

Inherits from

  • CFileBase

    Detailed Description

    Abstract base class for file management.

    It provides functions to set an observer for the derived class CFileMan, and to get information about the entry being processed.

    See also: CFileMan

    Member Attribute Documentation

    iCurrentEntry

    TInt iCurrentEntry[protected]

    iDirList

    CDir *iDirList[protected]

    iErrorInfo

    TFileManError iErrorInfo[protected]

    iFManThread

    RThread iFManThread[protected]

    iFs

    RFs iFs[protected]

    iFsOld

    RFs iFsOld[protected]

    iLastError

    TInt iLastError[protected]

    iMatchEntry

    TUint iMatchEntry[protected]

    iNumberOfFilesProcessed

    TInt iNumberOfFilesProcessed[protected]

    iObserver

    MFileManObserver *iObserver[protected]

    iScanner

    CDirScan *iScanner[protected]

    iSessionPath

    HBufC *iSessionPath[protected]

    iSrcFile

    TParse iSrcFile[protected]

    iStatus

    TRequestStatus *iStatus[protected]

    iSwitches

    TUint iSwitches[protected]

    iSynchronizer

    RSemaphore iSynchronizer[protected]

    Constructor & Destructor Documentation

    CFileBase ( RFs & )

    IMPORT_CCFileBase(RFs &anFs)[protected]

    Protected default constructor.

    Note that the class is intended only as an abstract base for other classes.

    ParameterDescription
    anFsFile server session.

    ~CFileBase ( )

    IMPORT_C~CFileBase()[protected]

    Destructor.

    Frees resources prior to destruction of the object.

    Member Function Documentation

    AbbreviatedPath ( )

    IMPORT_C TPtrCAbbreviatedPath()

    Gets the abbreviated path of the file or directory currently being processed.

    The abbreviated path is its path relative to the top level directory specified in the operation.

    Returns: The abbreviated path.

    CompleteOperationL ( )

    voidCompleteOperationL()[protected, inline, virtual]

    Called from RunL to perform tidy up after an operation.

    See also: CFileMan CFileBase::RunL

    ConstructL ( )

    IMPORT_C voidConstructL()[protected]

    Second phase constructor.

    CurrentEntry ( )

    IMPORT_C const TEntry &CurrentEntry()

    Gets the entry currently being processed.

    Returns: Contains the current entry.

    DoOperationL ( )

    voidDoOperationL()[protected, pure virtual]

    Called from RunL to perform the requested operation.

    See also: CFileMan CFileBase::RunL

    FullPath ( )

    IMPORT_C TPtrCFullPath()

    Gets the full path of the file or directory currently being processed.

    The full path includes the drive letter, path and filename.

    Returns: The full path.

    GetLastError ( )

    IMPORT_C TIntGetLastError()

    Gets the latest error code returned during a CFileMan operation.

    This function may be called from MFileManObserver::NotifyFileManEnded().

    Returns: KErrNone, or another error code that might have been returned by a CFileMan operation.

    GetMoreInfoAboutError ( )

    IMPORT_C TFileManErrorGetMoreInfoAboutError()

    Gets additional information about the latest error returned during a CFileMan operation.

    For example, if a rename fails, this function can be used to report whether the source or target name caused the problem. This information supplements that provided GetLastError().

    See also: CFileMan CFileBase::GetLastError()

    Returns: The extra information about the last CFileMan error.

    RunInSeparateThreadL ( TThreadFunction )

    IMPORT_C voidRunInSeparateThreadL(TThreadFunctionaThreadFunction)[protected]

    Creates a separate thread to run the command.

    ParameterDescription
    aThreadFunctionThe thread function.

    RunL ( )

    IMPORT_C voidRunL()[protected]

    Executes a command.

    capability
    Dependent the capabilities required by this method, of the abstract class CFileBase, will be dependent on and provided by the concrete-class implementation of the DoOperationL method

    SetObserver ( MFileManObserver * )

    IMPORT_C voidSetObserver(MFileManObserver *anObserver)

    Sets the observer.

    Use this function to provide CFileMan with an MFileManObserver, or, if one already exists, to change the observer.

    See also: CFileMan MFileManObserver

    ParameterDescription
    anObserverFile management observer.