filesystemuis/memscaneng/serverinc/msengfilescanner.h
branchRCL_3
changeset 21 65326cf895ed
parent 0 6a9f87576119
equal deleted inserted replaced
20:491b3ed49290 21:65326cf895ed
       
     1 /*
       
     2 * Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0""
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description: 
       
    15 *     Scan files.
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 #ifndef MSENGFILESCANNER_H
       
    21 #define MSENGFILESCANNER_H
       
    22 
       
    23 // USER INCLUDES
       
    24 #include "msengdirectoryscanner.h"
       
    25 
       
    26 // CLASS DECLARATION
       
    27 
       
    28 /**
       
    29 * This class identifies all files in a given directory based upon a
       
    30 * directory specification.
       
    31 */
       
    32 class CMsengFileScanner : public CMsengDirectoryScanner
       
    33     {
       
    34     public:  // Constructors and destructor
       
    35         
       
    36         /**
       
    37         * C++ default constructor.
       
    38         */
       
    39         CMsengFileScanner(MMsengScannerObserver& aObserver, 
       
    40             CMsengInfoArray& aScanArray, RFs& aFsSession);
       
    41         
       
    42         
       
    43         /**
       
    44         * Destructor.
       
    45         */
       
    46         ~CMsengFileScanner();
       
    47 
       
    48     public:
       
    49     
       
    50         /**
       
    51         * 
       
    52         */
       
    53         enum TLocationResponse
       
    54             {
       
    55             EEntryWasProcessed = 0,
       
    56             EEntryWasDiscarded
       
    57             };
       
    58 
       
    59     protected: // From CMsengDirectoryScanner
       
    60 
       
    61         /**
       
    62         * Scan this directory for files matching a subclass' criteria
       
    63         */
       
    64         virtual TScanDirectoryResult ScanDirectoryL(const TDesC& aDirectory, RFs& aFsSession);
       
    65 
       
    66         /**
       
    67         * Ask the subclass to populate a CDir object with a list of files matching
       
    68         * chosen criteria
       
    69         */
       
    70         virtual CDir* FindFilesL(const TDesC& aDirectory, TBool& aMoveToNextDirectory) = 0;
       
    71 
       
    72         /**
       
    73         * Inform the subclass of a matching entry
       
    74         */
       
    75         virtual TLocationResponse HandleLocatedEntryL(const TDesC& aFullFileNameAndPath, 
       
    76             const TEntry& aEntry) = 0;
       
    77     };
       
    78 
       
    79 #endif      // MSENGFILESCANNER_H   
       
    80             
       
    81 // End of File