1 // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of "Eclipse Public License v1.0"
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
25 /** The controlling process for an application.
27 An instance of this class is created by the Uikon environment. This instance
28 calls CApaProcess::AddNewDocumentL() to load the application DLL and
29 construct the new application which runs in this environment.
31 It also provides services related to an application's main (non-embedded) document,
33 - saving the main document to a direct file store
34 - providing the name of the most recently accessed file
35 - getting the name of the application DLL associated with a document.
39 NONSHARABLE_CLASS(CEikProcess) : public CApaProcess
42 /** Used as a parameter by CEikProcess::SetLastUsedFileL() and LastUsedFileL()
43 to indicate whether the function relates to the last opened or last created file.*/
46 /** Last opened file.*/
48 /** Last created file. */
52 static CEikProcess* NewL(const RFs& aFs, TProcessId aProcessId=KNullProcessId);
53 IMPORT_C TPtrC CommandTailEnd() const;
54 IMPORT_C TFileName MainDocFolder() const;
55 IMPORT_C void SetLastUsedFileL(TLastUsedFile aType,const TDesC& aFileName) const;
56 IMPORT_C TFileName LastUsedFileL(TLastUsedFile aType) const;
57 IMPORT_C void SetMainStore(CFileStore* aMainStore);
58 IMPORT_C CFileStore* MainStore() const;
59 IMPORT_C void AppFromDocL(TDes& aLibraryName,const TDesC& aDocumentName) const;
60 IMPORT_C void SaveToDirectFileStoreL(CEikDocument* aDoc,const TFileName* aNewFileName=NULL);
61 IMPORT_C void SaveToDirectFileStoreL(CEikDocument* aDoc,const TFileName* aNewFileName,TBool aReopen,TFileName* aTempFile=NULL);
62 IMPORT_C ~CEikProcess();
64 CEikProcess(const RFs& aFs);
65 void GetLibraryNameL(TDes& aLibraryName,const CFileStore& aDocStore, const CStreamDictionary& aStreamDic) const;
66 void OpenNewFileL(const TFileName* aNewFileName, const TParse& aNewFilePath);
67 CDictionaryStore* OpenMainAppIniFileLC() const;
69 TPtrC iCommandTailEnd;
70 CFileStore* iMainStore;
73 #endif // __EIKPROC_H__