epoc32/include/eikproc.h
branchSymbian2
changeset 2 2fe1408b6811
parent 0 061f57f2323e
     1.1 --- a/epoc32/include/eikproc.h	Tue Nov 24 13:55:44 2009 +0000
     1.2 +++ b/epoc32/include/eikproc.h	Tue Mar 16 16:12:26 2010 +0000
     1.3 @@ -1,1 +1,73 @@
     1.4 -eikproc.h
     1.5 +// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.6 +// All rights reserved.
     1.7 +// This component and the accompanying materials are made available
     1.8 +// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
     1.9 +// which accompanies this distribution, and is available
    1.10 +// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
    1.11 +//
    1.12 +// Initial Contributors:
    1.13 +// Nokia Corporation - initial contribution.
    1.14 +//
    1.15 +// Contributors:
    1.16 +//
    1.17 +// Description:
    1.18 +//
    1.19 +
    1.20 +#ifndef __EIKPROC_H__
    1.21 +#define __EIKPROC_H__
    1.22 +
    1.23 +#include <apparc.h>
    1.24 +#include <eikdef.h>
    1.25 +
    1.26 +class CFileStore;
    1.27 +class CEikDocument;
    1.28 +
    1.29 +/** The controlling process for an application. 
    1.30 +
    1.31 +An instance of this class is created by the Uikon environment. This instance 
    1.32 +calls CApaProcess::AddNewDocumentL() to load the application DLL and 
    1.33 +construct the new application which runs in this environment. 
    1.34 +
    1.35 +It also provides services related to an application's main (non-embedded) document, 
    1.36 +including: 
    1.37 +- saving the main document to a direct file store
    1.38 +- providing the name of the most recently accessed file
    1.39 +- getting the name of the application DLL associated with a document.
    1.40 +
    1.41 +@publishedAll 
    1.42 +@released */
    1.43 +NONSHARABLE_CLASS(CEikProcess) : public CApaProcess
    1.44 +	{
    1.45 +public:
    1.46 +	/** Used as a parameter by CEikProcess::SetLastUsedFileL() and LastUsedFileL() 
    1.47 +	to indicate whether the function relates to the last opened or last created file.*/
    1.48 +	enum TLastUsedFile
    1.49 +		{
    1.50 +		/** Last opened file.*/
    1.51 +		ELastOpenFile,
    1.52 +		/** Last created file. */
    1.53 +		ELastCreatedFile
    1.54 +		};
    1.55 +public:
    1.56 +	static CEikProcess* NewL(const RFs& aFs, TProcessId aProcessId=KNullProcessId);
    1.57 +	IMPORT_C TPtrC CommandTailEnd() const;
    1.58 +	IMPORT_C TFileName MainDocFolder() const;
    1.59 +	IMPORT_C void SetLastUsedFileL(TLastUsedFile aType,const TDesC& aFileName) const;
    1.60 +	IMPORT_C TFileName LastUsedFileL(TLastUsedFile aType) const;
    1.61 +	IMPORT_C void SetMainStore(CFileStore* aMainStore);
    1.62 +	IMPORT_C CFileStore* MainStore() const;
    1.63 +	IMPORT_C void AppFromDocL(TDes& aLibraryName,const TDesC& aDocumentName) const;
    1.64 +	IMPORT_C void SaveToDirectFileStoreL(CEikDocument* aDoc,const TFileName* aNewFileName=NULL);
    1.65 +	IMPORT_C void SaveToDirectFileStoreL(CEikDocument* aDoc,const TFileName* aNewFileName,TBool aReopen,TFileName* aTempFile=NULL);
    1.66 +	IMPORT_C ~CEikProcess();
    1.67 +private:
    1.68 +	CEikProcess(const RFs& aFs);
    1.69 +	void GetLibraryNameL(TDes& aLibraryName,const CFileStore& aDocStore, const CStreamDictionary& aStreamDic) const;
    1.70 +	void OpenNewFileL(const TFileName* aNewFileName, const TParse& aNewFilePath);
    1.71 +	CDictionaryStore* OpenMainAppIniFileLC() const;
    1.72 +private:
    1.73 +	TPtrC iCommandTailEnd;
    1.74 +	CFileStore* iMainStore;
    1.75 +	};
    1.76 +
    1.77 +#endif	// __EIKPROC_H__