examples/Messaging/TextMTM/txts/TXTMBOX.H

00001 // Copyright (c) 1999-2009 Nokia Corporation and/or its subsidiary(-ies).
00002 // All rights reserved.
00003 // This component and the accompanying materials are made available
00004 // under the terms of "Eclipse Public License v1.0"
00005 // which accompanies this distribution, and is available
00006 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
00007 //
00008 // Initial Contributors:
00009 // Nokia Corporation - initial contribution.
00010 //
00011 // Contributors:
00012 //
00013 // Description:
00014 //
00015 
00016 
00017 #ifndef __TXTMBOX_H__
00018 #define __TXTMBOX_H__
00019 
00020 #include <e32base.h>
00021 #include <f32file.h>
00022 #include <msvstd.h>
00023 #include <msventry.h>
00024 #include <e32def.h>
00025 #include "TXUT.H"
00026 
00027 //
00028 //      CTxtRefreshMBox: refresher class to synchronize real folder and service
00029 //
00030 
00031 class CTxtRefreshMBox : public CBase
00032         {
00033         public:
00034                 static CTxtRefreshMBox* NewL(RFs& aFs, TFileName& aRelativePath, 
00035                         TMsvId aCurrentRootEntryId, CMsvServerEntry *aEntry, TMsvId aServiceEntryId,
00036                         const TMTMTxtSettings& aTxtSettings);
00037                 ~CTxtRefreshMBox();
00038                 TBool DoStepL(); // Returns ETrue if finished.
00039         private: // Construction
00040                 CTxtRefreshMBox(RFs& aFs,TFileName& aRelativePath, TMsvId aCurrentRootEntryId, 
00041                         CMsvServerEntry *aEntry, TMsvId aServiceEntryId, const TMTMTxtSettings& aTxtSettings) 
00042                         : iFs(aFs) , iRelativePath(aRelativePath), iCurrentRootEntryId(aCurrentRootEntryId), 
00043                         iEntry(aEntry), iTxtSettings(aTxtSettings), iServiceEntryId(aServiceEntryId)
00044                         {};
00045                 void ConstructL();
00046         private: // Tools
00047                 TInt CreateChild(const TDesC& aDescription, const TDesC& aDetails, 
00048                         TUid aMessageType, const TTime& aDate, const TInt aSize);
00049                 void DeleteEntryL();
00050                 TMsvId InsertFileL();
00051         private:
00052                 RFs&  iFs;
00053                 TFileName& iRelativePath;
00054                 TMsvId  iCurrentRootEntryId;
00055                 CDir* iFilelist;
00056                 CMsvServerEntry* iEntry;
00057                 CMsvEntrySelection* iExistingEntries;
00058                 
00059                 TInt iCurrentFile;      // index for file list
00060                 TInt iCurrentEntry;     // index for entry list
00061                 const TMTMTxtSettings& iTxtSettings;
00062                 TMsvId iServiceEntryId;
00063         };
00064 #endif

Generated on Thu Jan 21 10:32:59 2010 for TB10.1 Example Applications by  doxygen 1.5.3