Coda Distributed File System
|
#include <fso_cachefile.h>
Public Member Functions | |
SegmentedCacheFile (int i) REQUIRES_TRANSACTION | |
~SegmentedCacheFile () | |
void | Associate (CacheFile *cf) REQUIRES_TRANSACTION |
int64_t | ExtractSegment (uint64_t pos, int64_t count) REQUIRES_TRANSACTION |
int64_t | InjectSegment (uint64_t pos, int64_t count) REQUIRES_TRANSACTION |
![]() | |
CacheFile (int i, int recoverable=1, int partial=0) REQUIRES_TRANSACTION | |
CacheFile () | |
~CacheFile () | |
void | Create (int newlength=0) REQUIRES_TRANSACTION |
int | Open (int flags) |
int | Close (int fd) |
FILE * | FOpen (const char *mode) |
int | FClose (FILE *f) |
void | Validate () EXCLUDES_TRANSACTION |
void | Reset () EXCLUDES_TRANSACTION |
int | Copy (CacheFile *destination) REQUIRES_TRANSACTION |
int | Copy (char *destname, int recovering=0) |
void | IncRef () |
int | DecRef () |
void | Stat (struct stat *tstat) |
void | Utimes (const struct timeval times[2]) |
void | Truncate (uint64_t newlen) REQUIRES_TRANSACTION |
void | SetLength (uint64_t newlen) REQUIRES_TRANSACTION |
void | SetValidData (uint64_t len) REQUIRES_TRANSACTION |
void | SetValidData (uint64_t start, int64_t len) REQUIRES_TRANSACTION |
CacheChunkList * | GetHoles (uint64_t start, int64_t len) |
CacheChunkList * | GetValidChunks (uint64_t start, int64_t len) |
char * | Name () |
uint64_t | Length () |
uint64_t | ValidData () |
uint64_t | ConsecutiveValidData () |
int | IsComplete () |
bool | IsPartial () |
void | SetPartial (bool is_partial) REQUIRES_TRANSACTION |
void | print () |
void | print (FILE *fp) |
void | print (int fdes) |
Additional Inherited Members | |
![]() | |
static int64_t | CopySegment (CacheFile *from, CacheFile *to, uint64_t pos, int64_t count) REQUIRES_TRANSACTION |
![]() | |
char | name [CACHEFILENAMELEN] |
Segmented cache file
SegmentedCacheFile::SegmentedCacheFile | ( | int | i | ) |
Constructor
i | cache file identifier |
SegmentedCacheFile::~SegmentedCacheFile | ( | ) |
Destructor
void SegmentedCacheFile::Associate | ( | CacheFile * | cf | ) |
Associate the segmented cache file with it's original cache file
cf | cache file pointer |
int64_t SegmentedCacheFile::ExtractSegment | ( | uint64_t | pos, |
int64_t | count | ||
) |
Extract a segment from the associated cache file
pos | offset within the file |
count | amount of bytes to be extracted |
int64_t SegmentedCacheFile::InjectSegment | ( | uint64_t | pos, |
int64_t | count | ||
) |
Inject a segment to the associated cache file
pos | offset within the file |
count | amount of bytes to be injected |