File Data Block. More...
#include <rblockfiledata.h>
Collaboration diagram for RBlockFileData:
Public Member Functions | |
int | Compare (const RBlockFileData &block) const |
int | Compare (size_t id) const |
~RBlockFileData (void) | |
Private Member Functions | |
RBlockFileData (size_t id, size_t size) | |
Private Attributes | |
size_t | Id |
size_t | NbAccess |
bool | Dirty |
char * | Data |
RContainer< RBlockFileAccess, false, false > | Access |
RRWLock | lData |
Detailed Description
File Data Block.
The RBlockFileData class represents a block of data of a given file loaded in memory. In practice, it is only useful for internal purposes.
- See also
- RBlockFile
Constructor & Destructor Documentation
|
private |
Initiliaz a block.
- Parameters
-
id Identifier. size Block size.
~RBlockFileData | ( | void | ) |
Destructor.
Member Function Documentation
int Compare | ( | const RBlockFileData & | block | ) | const |
Compare method based on the identifier.
- Parameters
-
block Block to compare with.
- Returns
- a value depending if the current block has a higher identifier (1), an equal one (0) or a smaller one (-1) than the one used to compare with.
int Compare | ( | size_t | id | ) | const |
Compare method based on the identifier.
- Parameters
-
id Identifier to compare with.
- Returns
- a value depending if the current block has a higher identifier (1), an equal one (0) or a smaller one (-1) than the one used to compare with.
Field Documentation
|
private |
Identifier of the block.
|
private |
Number of access.
|
private |
Was the block modified ?
|
private |
Data contained in the block.
|
private |
Current access to the block.
|
private |
Read/Write Lock.