#include <XrdFileCache.hh>
Inheritance diagram for XrdFileCache::Cache:
Public Member Functions | |
Cache (XrdOucCacheStats &) | |
Constructor. | |
virtual XrdOucCacheIO * | Attach (XrdOucCacheIO *, int Options=0) |
Obtain a new IO object that fronts existing XrdOucCacheIO. | |
virtual int | isAttached () |
Number of cache-io objects atteched through this cache. | |
virtual XrdOucCache * | Create (XrdOucCache::Parms &, XrdOucCacheIO::aprParms *) |
Unused abstract method. Plugin instantiation role is given to the Factory class. | |
Static Public Member Functions | |
static void | AddWriteTask (Prefetch *p, int ramBlockidx, size_t size, bool fromRead) |
Add downloaded block in write queue. | |
static bool | HaveFreeWritingSlots () |
Check write queue size is not over limit. | |
static void | RemoveWriteQEntriesFor (Prefetch *p) |
Remove blocks from write queue which belong to given prefetch. This method is used at the time of Prefetch destruction. | |
static void | ProcessWriteTasks () |
Separate task which writes blocks from ram to disk. | |
Private Member Functions | |
void | Detach (XrdOucCacheIO *) |
Decrease attached count. Called from IO::Detach(). | |
void | getFilePathFromURL (const char *url, std::string &res) const |
Transfor URL to path on local disk. | |
XrdCl::Log * | clLog () const |
Short log alias. | |
Private Attributes | |
XrdSysMutex | m_io_mutex |
central lock for this class | |
unsigned int | m_attached |
number of attached IO objects | |
XrdOucCacheStats & | m_stats |
global cache usage statistics | |
Static Private Attributes | |
static WriteQ | s_writeQ |
Friends | |
class | IOEntireFile |
class | IOFileBlock |
Classes | |
struct | WriteQ |
struct | WriteTask |
XrdFileCache::Cache::Cache | ( | XrdOucCacheStats & | ) |
Constructor.
static void XrdFileCache::Cache::AddWriteTask | ( | Prefetch * | p, | |
int | ramBlockidx, | |||
size_t | size, | |||
bool | fromRead | |||
) | [static] |
Add downloaded block in write queue.
virtual XrdOucCacheIO* XrdFileCache::Cache::Attach | ( | XrdOucCacheIO * | , | |
int | Options = 0 | |||
) | [virtual] |
XrdCl::Log* XrdFileCache::Cache::clLog | ( | ) | const [inline, private] |
Short log alias.
virtual XrdOucCache* XrdFileCache::Cache::Create | ( | XrdOucCache::Parms & | , | |
XrdOucCacheIO::aprParms * | ||||
) | [inline, virtual] |
Unused abstract method. Plugin instantiation role is given to the Factory class.
Implements XrdOucCache.
void XrdFileCache::Cache::Detach | ( | XrdOucCacheIO * | ) | [private] |
Decrease attached count. Called from IO::Detach().
void XrdFileCache::Cache::getFilePathFromURL | ( | const char * | url, | |
std::string & | res | |||
) | const [private] |
Transfor URL to path on local disk.
static bool XrdFileCache::Cache::HaveFreeWritingSlots | ( | ) | [static] |
Check write queue size is not over limit.
virtual int XrdFileCache::Cache::isAttached | ( | ) | [virtual] |
static void XrdFileCache::Cache::ProcessWriteTasks | ( | ) | [static] |
Separate task which writes blocks from ram to disk.
static void XrdFileCache::Cache::RemoveWriteQEntriesFor | ( | Prefetch * | p | ) | [static] |
Remove blocks from write queue which belong to given prefetch. This method is used at the time of Prefetch destruction.
friend class IOEntireFile [friend] |
friend class IOFileBlock [friend] |
unsigned int XrdFileCache::Cache::m_attached [private] |
number of attached IO objects
XrdSysMutex XrdFileCache::Cache::m_io_mutex [private] |
central lock for this class
XrdOucCacheStats& XrdFileCache::Cache::m_stats [private] |
global cache usage statistics
WriteQ XrdFileCache::Cache::s_writeQ [static, private] |