CPermanentFileStore Class Reference
class CPermanentFileStore : public CFileStore |
Permanent file store.
This type of store supports full manipulation of store contents. Existing streams within this type of store can be changed.
Public Member Functions |
---|
| CPermanentFileStore(RFile &) |
| CPermanentFileStore(RFileBuf &, const TUidType &) |
| ~CPermanentFileStore() |
CPermanentFileStore * | CreateL(RFs &, const TDesC &, TUint) |
CPermanentFileStore * | CreateLC(RFs &, const TDesC &, TUint) |
CPermanentFileStore * | FromL(RFile &) |
CPermanentFileStore * | FromLC(RFile &) |
IMPORT_C TUid | Layout() |
IMPORT_C void | MarshalL() |
CPermanentFileStore * | NewL(RFile &) |
CPermanentFileStore * | NewLC(RFile &) |
CPermanentFileStore * | OpenL(RFs &, const TDesC &, TUint) |
CPermanentFileStore * | OpenLC(RFs &, const TDesC &, TUint) |
CPermanentFileStore * | ReplaceL(RFs &, const TDesC &, TUint) |
CPermanentFileStore * | ReplaceLC(RFs &, const TDesC &, TUint) |
CPermanentFileStore * | TempL(RFs &, const TDesC &, TFileName &, TUint) |
CPermanentFileStore * | TempLC(RFs &, const TDesC &, TFileName &, TUint) |
Inherited Functions |
---|
| CBase::CBase() |
| CBase::Delete(CBase *) |
| CBase::Extension_(TUint,TAny *&,TAny *) |
| CBase::operator new(TUint) |
| CBase::operator new(TUint,TAny *) |
| CBase::operator new(TUint,TLeave) |
| CBase::operator new(TUint,TLeave,TUint) |
| CBase::operator new(TUint,TUint) |
| CBase::~CBase() |
| CFileStore::CFileStore(RFile &) |
| CFileStore::CFileStore(RFileBuf &,const TUidType &) |
| CFileStore::ChangedL() |
| CFileStore::CreateL(RFs &,const TDesC &,TUint,TNewFunction) |
| CFileStore::CreateLC(RFs &,const TDesC &,TUint,TNewFunction) |
| CFileStore::Destruct() |
| CFileStore::Detach() |
| CFileStore::File()const |
| CFileStore::FromL(RFile &,TFileStoreFactoryFunction) |
| CFileStore::FromL(RFile &,const TFileStoreFactoryFunction) |
| CFileStore::FromLC(RFile &,TFileStoreFactoryFunction) |
| CFileStore::FromLC(RFile &,const TFileStoreFactoryFunction) |
| CFileStore::Host()const |
| CFileStore::IsHost(const MStreamBuf *)const |
| CFileStore::NewL(RFile &,TNewFunction) |
| CFileStore::NewLC(RFile &,TNewFunction) |
| CFileStore::OpenL(RFs &,const TDesC &,TUint,TFileStoreFactoryFunction) |
| CFileStore::OpenL(RFs &,const TDesC &,TUint,const TFileStoreFactoryFunction) |
| CFileStore::OpenLC(RFs &,const TDesC &,TUint,TFileStoreFactoryFunction) |
| CFileStore::OpenLC(RFs &,const TDesC &,TUint,const TFileStoreFactoryFunction) |
| CFileStore::Reattach(RFile &) |
| CFileStore::RefreshL() |
| CFileStore::ReplaceL(RFs &,const TDesC &,TUint,TNewFunction) |
| CFileStore::ReplaceLC(RFs &,const TDesC &,TUint,TNewFunction) |
| CFileStore::Reset() |
| CFileStore::Reset(TInt) |
| CFileStore::SetSizeL(TInt) |
| CFileStore::SetTypeL(const TUidType &) |
| CFileStore::SynchL() |
| CFileStore::TempL(RFs &,const TDesC &,TFileName &,TUint,TNewFunction) |
| CFileStore::TempLC(RFs &,const TDesC &,TFileName &,TUint,TNewFunction) |
| CFileStore::Type()const |
| CFileStore::~CFileStore() |
| CPersistentStore::CPersistentStore() |
| CPersistentStore::Root()const |
| CPersistentStore::SetRootL(TStreamId) |
| CStreamStore::Commit() |
| CStreamStore::CommitL() |
| CStreamStore::CompactL() |
| CStreamStore::Delete(TStreamId) |
| CStreamStore::DeleteL(TStreamId) |
| CStreamStore::ExtendL() |
| CStreamStore::ReclaimL() |
| CStreamStore::Revert() |
| CStreamStore::RevertL() |
Private Attributes |
---|
__MUTABLE CPermanentStoreCoord * | iCoord |
Constructor & Destructor Documentation
CPermanentFileStore(RFile &)
IMPORT_C | CPermanentFileStore | ( | RFile & | aFile | ) | |
CPermanentFileStore(RFileBuf &, const TUidType &)
~CPermanentFileStore()
IMPORT_C | ~CPermanentFileStore | ( | ) | |
Member Functions Documentation
Coord()
CPermanentStoreCoord & | Coord | ( | ) | const [private, inline] |
CoordL()
CPermanentStoreCoord & | CoordL | ( | ) | const [private] |
CreateL(RFs &, const TDesC &, TUint)
Creates a new file and constructs a new permanent file store object to be associated with this file.
TFileMode
Parameters
RFs & aFs | Handle to a file server session. |
const TDesC & aName | The full path name of the new file. A file with this name must not already exist, otherwise the function leaves. |
TUint aFileMode | The mode in which the new file is to be accessed. This mode is defined by the TFileMode type. |
CreateLC(RFs &, const TDesC &, TUint)
Creates a new file and constructs a new permanent file store object to be associated with this file, and places the pointer onto the cleanup stack.
TFileMode
Parameters
RFs & aFs | Handle to a file server session. |
const TDesC & aName | The full path name of the new file. A file with this name must not already exist, otherwise the function leaves. |
TUint aFileMode | The mode in which the new file is to be accessed. This mode is defined by the TFileMode type. |
DoCommitL()
IMPORT_C void | DoCommitL | ( | ) | [private, virtual] |
DoCreateL(TStreamId &)
Creates a new stream in the store. The function gets the allocated stream id in the anId parameter. A stream buffer for the stream should be returned, ready to write into the new stream. This provides the implementation for the RStoreWriteStream::CreateL() functions.
Parameters
TStreamId & anId | On return, contains the allocated stream id. |
DoDeleteL(TStreamId)
IMPORT_C void | DoDeleteL | ( | TStreamId | anId | ) | [private, virtual] |
DoExtendL()
IMPORT_C TStreamId | DoExtendL | ( | ) | [private, virtual] |
DoRevertL()
IMPORT_C void | DoRevertL | ( | ) | [private, virtual] |
DoSetRootL(TStreamId)
IMPORT_C void | DoSetRootL | ( | TStreamId | anId | ) | [private, virtual] |
ExternalizeL(RWriteStream &)
IMPORT_C void | ExternalizeL | ( | RWriteStream & | aStream | ) | const [private, virtual] |
FromL(RFile &)
Constructs a permanent file store object from an already opened file. It is strongly recommended to set EFileWriteDirectIO bit when opening the file. This is because that when the file server write caching is enabled, the order of file write operations is not guaranteed. This could cause data inconsistency in some circumstances, for example, when the power is lost in the middle of database transaction. Therefore, the file write caching should be switched off to maintain integrity.
The file must already be open before calling this function.
Note that ownership of the file passes to the store. The referenced RFile is cleared and is no longer valid.
Parameters
RFile & aFile | A reference to the opened file. |
FromLC(RFile &)
Constructs a permanent file store object from an already opened file, and places the pointer onto the cleanup stack.
The file must already be open before calling this function. It is strongly recommended to set EFileWriteDirectIO bit when opening the file. This is because that when the file server write caching is enabled, the order of file write operations is not guaranteed. This could cause data inconsistency in some circumstances, for example, when the power is lost in the middle of database transaction. Therefore, the file write caching should be switched off to maintain integrity.
Note that ownership of the file passes to the store. The referenced RFile is cleared and is no longer valid.
Parameters
RFile & aFile | A reference to the opened file. |
InternalizeL(RReadStream &)
IMPORT_C void | InternalizeL | ( | RReadStream & | aStream | ) | [private, virtual] |
Layout()
IMPORT_C TUid | Layout | ( | ) | const [virtual] |
NewL(RFile &)
Constructs a new permanent file store object in an already opened file.
The file must already be open before calling this function. The existing content of the file is discarded. It is strongly recommended to set EFileWriteDirectIO bit when opening the file. It is because that when file server file write cachingis on, the order of file writing is not guaranteed which could cause data inconsistency in some circumstances, for example, when the power is lost in the middle of data transaction. Therefore, the file write caching should be switched off to maintain the file integrity.
Note that ownership of the file passes to the store. The referenced RFile is cleared and is no longer valid.
Parameters
RFile & aFile | A reference to the opened file. |
NewLC(RFile &)
Constructs a new permanent file store object in an already opened file and places the pointer onto the cleanup stack.
The file must already be open before calling this function.The existing content of the file is discarded. It is strongly recommended to set EFileWriteDirectIO bit when opening the file. It is because that when the file write caching in file server is on, the order of file writing is not guaranteed which could cause data inconsistency in some circumstances, for example, when the power is lost in the middle of data transaction. Therefore, the file file write caching should be switched off to maintain the file integrity.
Note that ownership of the file passes to the store. The referenced RFile is cleared and is no longer valid.
Parameters
RFile & aFile | A reference to the opened file. |
OpenL(RFs &, const TDesC &, TUint)
Opens a file containing a permanent file store, and constructs a permanent file store object.
TFileMode
Parameters
RFs & aFs | Handle to a file server session. |
const TDesC & aName | The full path name of the file containing the store. |
TUint aFileMode | The mode in which the file is to be accessed. The mode is defined by the TFileMode type. |
OpenLC(RFs &, const TDesC &, TUint)
Opens a file containing a permanent file store, constructs a permanent file store object, and places the pointer onto the cleanup stack.
TFileMode
Parameters
RFs & aFs | Handle to a file server session. |
const TDesC & aName | The full path name of the file containing the store. |
TUint aFileMode | The mode in which the file is to be accessed. The mode is defined by the TFileMode type. |
ReplaceL(RFs &, const TDesC &, TUint)
Creates a file, constructs a permanent file store object to be associated with it.
This file replaces any existing file of the same name.
TFileMode
Parameters
RFs & aFs | Handle to a file server session. |
const TDesC & aName | The full path name of the file to be replaced. |
TUint aFileMode | The mode in which the file is to be accessed. The mode is defined by the TFileMode type. |
ReplaceLC(RFs &, const TDesC &, TUint)
Creates a file, constructs a permanent file store object to be associated with it, and places the pointer onto the cleanup stack.
This file replaces any existing file of the same name.
TFileMode
Parameters
RFs & aFs | Handle to a file server session. |
const TDesC & aName | The full path name of the file to be replaced. |
TUint aFileMode | The mode in which the file is to be accessed. The mode is defined by the TFileMode type. |
TempL(RFs &, const TDesC &, TFileName &, TUint)
Creates a temporary file and constructs a permanent file store object to be associated with it.
The new file is created in the specified path and a unique file name is generated by the file server.
Note that the store framework does not delete a temporary file after it is closed.
TFileMode
Parameters
RFs & aFs | Handle to a file server session. |
const TDesC & aPath | The path where the new file is to be created. |
TFileName & aName | On return, contains the full path name of the new file. |
TUint aFileMode | The mode in which the file is to be accessed. The mode is defined by the TFileMode type. |
TempLC(RFs &, const TDesC &, TFileName &, TUint)
Creates a temporary file, constructs a permanent file store object to be associated with it, and places the pointer onto the cleanup stack.
The new file is created in the specified path and a unique file name is generated by the file server.
Note that the store framework does not delete a temporary file after it is closed.
TFileMode
Parameters
RFs & aFs | Handle to a file server session. |
const TDesC & aPath | The path where the new file is to be created. |
TFileName & aName | On return, contains the full path name of the new file. |
TUint aFileMode | The mode in which the file is to be accessed. The mode is defined by the TFileMode type. |
TrimL()
CPermanentStoreCoord & | TrimL | ( | ) | [private] |
Member Data Documentation
__MUTABLE CPermanentStoreCoord * iCoord
__MUTABLE CPermanentStoreCoord * | iCoord | [private] |
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.