1 #ifndef __XRDPFC_CACHE_IO_HH__
2 #define __XRDPFC_CACHE_IO_HH__
26 const char *
Path()
override {
return m_io->Path(); }
29 int Sync()
override {
return 0; }
32 int Trunc(
long long Offset)
override {
return -ENOTSUP; }
35 int Write(
char *Buffer,
long long Offset,
int Length)
override {
return -ENOTSUP; }
55 const char*
GetPath() {
return m_io->Path(); }
68 void Done(
int result)
override
84 time_t m_attach_time {0};
85 int m_active_prefetches {0};
86 bool m_allow_prefetching {
true};
87 bool m_in_detach {
false};
const std::string & GetPath() const
Get the path.
virtual int Write(char *buff, long long offs, int wlen)=0
virtual int Trunc(long long offs)=0
Attaches/creates and detaches/deletes cache-io objects for disk based cache.
Base cache-io class that implements some XrdOucCacheIO abstract methods.
virtual XrdOucCacheIO * Base()
Original data source.
std::string GetFilename()
IO(XrdOucCacheIO *io, Cache &cache)
XrdOucCacheIO * GetInput()
int Trunc(long long Offset) override
Cache & m_cache
reference to Cache object
RAtomic_int m_active_read_reqs
number of active read requests
const char * Path() override
Original data source URL.
const char * RefreshLocation()
bool Detach(XrdOucCacheIOCD &iocdP) final
virtual bool ioActive()=0
const char * GetLocation()
int Write(char *Buffer, long long Offset, int Length) override
void Update(XrdOucCacheIO &iocp) override
unsigned short ObtainReadSid()
virtual void DetachFinalize()=0
void Done(int result) override
ReadReqRH(unsigned short sid, XrdOucCacheIOCB *iocb)