![]() |
OpendTect
6.3
|
Public Member Functions | |
| ReadCache (FileSizeType knownsize=0) | |
| ~ReadCache () | |
| virtual void | clearData () |
| virtual void | setMinCacheSize (FileSizeType) |
| bool | isAvailable (FilePosType, FileSizeType) const |
| FileSizeType | getAt (FilePosType, BufType *, FileSizeType) const |
| FileChunkSetType | stillNeededDataFor (FilePosType, ChunkSizeType) const |
| bool | setData (FileChunkType, const BufType *) |
| if fail, memory was full; now the cache is cleared More... | |
Public Member Functions inherited from Network::FileCache | |
| virtual | ~FileCache () |
| FileSizeType | size () const |
| bool | isEmpty () const |
| BlockIdxType | blockIdx (FilePosType) const |
| BlockSizeType | blockSize (BlockIdxType) const |
| bool | validBlockIdx (BlockIdxType bidx) const |
| bool | isLiveBlock (BlockIdxType) const |
| BufType * | getBlock (BlockIdxType) |
| const BufType * | getBlock (BlockIdxType) const |
Protected Member Functions | |
| virtual void | handleNewLiveBlock (BlockIdxType) |
Protected Member Functions inherited from Network::FileCache | |
| FileCache (FileSizeType) | |
| Block * | gtBlk (BlockIdxType) const |
| void | dismissBlock (BlockIdxType) |
| void | clearBlocks () |
| FilePosType | lastBlockPos () const |
| FilePosType | lastFilePos () const |
Protected Attributes | |
| TypeSet< BlockIdxType > | liveblockidxs_ |
| BlockIdxType | maxnrliveblocks_ |
Protected Attributes inherited from Network::FileCache | |
| ObjectSet< Block > | blocks_ |
| const BlockSizeType | lastblocksz_ |
| const FileSizeType | knownfilesize_ |
Additional Inherited Members | |
Public Types inherited from Network::FileCache | |
| typedef unsigned char | BufType |
| typedef int | ChunkSizeType |
| typedef od_stream_Count | FileSizeType |
| typedef od_stream_Pos | FilePosType |
| typedef Interval< FilePosType > | FileChunkType |
| typedef TypeSet< FileChunkType > | FileChunkSetType |
| typedef ObjectSet< Block >::size_type | BlockIdxType |
| typedef Block::SizeType | BlockSizeType |
Static Public Member Functions inherited from Network::FileCache | |
| static FilePosType | blockStart (BlockIdxType) |
Write Cache.
When writing, we need a buffer to write data to. To allow jumping around a bit, we'll have to retain the first block (so a header can be updated later), and a couple of blocks before the last block. Therefore, the cache assumes writing steadily on, with maybe going back to the first block, or one of the near previous ones. Random jumping around may lead to bad stuff.
| Network::ReadCache::ReadCache | ( | FileSizeType | knownsize = 0 | ) |
| Network::ReadCache::~ReadCache | ( | ) |
|
virtual |
Implements Network::FileCache.
| FileSizeType Network::ReadCache::getAt | ( | FilePosType | , |
| BufType * | , | ||
| FileSizeType | |||
| ) | const |
|
protectedvirtual |
Reimplemented from Network::FileCache.
| bool Network::ReadCache::isAvailable | ( | FilePosType | , |
| FileSizeType | |||
| ) | const |
| bool Network::ReadCache::setData | ( | FileChunkType | , |
| const BufType * | |||
| ) |
if fail, memory was full; now the cache is cleared
|
virtual |
Implements Network::FileCache.
| FileChunkSetType Network::ReadCache::stillNeededDataFor | ( | FilePosType | , |
| ChunkSizeType | |||
| ) | const |
|
protected |
|
protected |
Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B. V. 2017