RFilePagePool Class Reference
class RFilePagePool : public TCachePagePool
|
Uses a file directly to implement the page pool interface
MPagePool
.
The pages are written sequentially through the file. You should call
Close()
to release the file resource after CreateL(), OpenL(), ReplaceL() or
Temp()
.
A file page pool uses a cache to store pages in-memory and to cache frequently accessed pages. You should provide a cache object (
CPageCache
) to the pool for this purpose.
CPageCache
RFile
Constructor & Destructor Documentation
RFilePagePool()
IMPORT_C
|
RFilePagePool
|
(
|
)
|
|
RFilePagePool(CPageCache &)
Member Functions Documentation
Attach(RFile &)
void
|
Attach
|
(
|
RFile
&
|
aFile
|
)
|
[inline]
|
Sets an existing file to be used for the page pool.
Parameters
RFile
& aFile
|
File to use for the page pool
|
Create(RFs &, const TDesC &, TUint)
Creates a new file for the page pool.
TFileMode
Parameters
RFs
& aFs
|
A file server session
|
const
TDesC
& aName
|
The name of the file. Any path components which are not specified here are taken from the session path.
|
TUint
aFileMode
|
The mode in which the file is opened. For more information see the TFileMode enumeration.
|
Detach()
Ends the use of the file for the page pool, but does not close the file.
ExtendL(const TAny *, TPageReclamation)
File()
RFile
&
|
File
|
(
|
)
|
const [inline]
|
Open(RFs &, const TDesC &, TUint)
Opens a file to use for the page pool.
TFileMode
Parameters
RFs
& aFs
|
A file server session
|
const
TDesC
& aName
|
The name of the file
|
TUint
aFileMode
|
The mode in which the file is opened. For more information, see the TFileMode enumeration.
|
ReadL(TPageRef, TAny *)
IMPORT_C void
|
ReadL
|
(
|
TPageRef
|
aRef,
|
|
TAny
*
|
aPage
|
|
)
|
[protected, virtual]
|
Release()
IMPORT_C void
|
Release
|
(
|
)
|
|
Replace(RFs &, const TDesC &, TUint)
Creates or opens a file for the page pool.
If there is an existing file with the same name, this function overwrites it. If the file does not already exist, it is created.
TFileMode
Parameters
RFs
& aFs
|
A file server session.
|
const
TDesC
& aName
|
The name of the file. Any path components which are not specified here are taken from the session path.
|
TUint
aFileMode
|
The mode in which the file is opened. For more information see the TFileMode enumeration.
|
Temp(RFs &, const TDesC &, TFileName &, TUint)
Creates and opens a file for the page pool with a unique name.
Parameters
RFs
& aFs
|
A file server session.
|
const
TDesC
& aPath
|
The directory in which the file should be created.
|
TFileName
& aName
|
On return, contains the full path and name of the file. The filename is guaranteed to be unique within the directory specified by aPath.
|
TUint
aFileMode
|
The mode in which the file is opened. For more information see the TFileMode enumeration.
|
WriteL(TPageRef, const TAny *, TPageChange)
Member Data Documentation
__MUTABLE RFile iFile
__MUTABLE
RFile
|
iFile
|
[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.