#include <XrdClient.hh>
Public Member Functions | |
XrdClient (const char *url, XrdClientCallback *XrdCcb=0, void *XrdCcbArg=0) | |
virtual | ~XrdClient () |
UnsolRespProcResult | ProcessUnsolicitedMsg (XrdClientUnsolMsgSender *sender, XrdClientMessage *unsolmsg) |
bool | Close () |
bool | Sync () |
bool | Copy (const char *localpath) |
bool | GetCacheInfo (int &size, long long &bytessubmitted, long long &byteshit, long long &misscount, float &missrate, long long &readreqcnt, float &bytesusefulness) |
bool | GetCounters (XrdClientCounters *cnt) |
bool | IsOpen () |
bool | IsOpen_inprogress () |
bool | IsOpen_wait () |
bool | Open (kXR_unt16 mode, kXR_unt16 options, bool doitparallel=true) |
int | Read (void *buf, long long offset, int len) |
kXR_int64 | ReadV (char *buf, long long *offsets, int *lens, int nbuf) |
XReqErrorType | Read_Async (long long offset, int len, bool updatecounters=true) |
bool | Stat (struct XrdClientStatInfo *stinfo, bool force=false) |
bool | UseCache (bool u=true) |
void | RemoveAllDataFromCache () |
void | RemoveDataFromCache (long long begin_offs, long long end_offs, bool remove_overlapped=false) |
void | SetCacheParameters (int CacheSize, int ReadAheadSize, int RmPolicy) |
void | SetReadAheadStrategy (int strategy) |
void | SetBlockReadTrimming (int blocksize) |
bool | Truncate (long long len) |
bool | Write (const void *buf, long long offset, int len) |
Public Attributes | |
std::vector< std::string > | fExcludedHosts |
Protected Member Functions | |
virtual bool | OpenFileWhenRedirected (char *newfhandle, bool &wasopen) |
virtual bool | CanRedirOnError () |
Protected Attributes | |
XrdClientCounters | fCounters |
Private Member Functions | |
bool | TryOpen (kXR_unt16 mode, kXR_unt16 options, bool doitparallel) |
bool | LowOpen (const char *file, kXR_unt16 mode, kXR_unt16 options, char *additionalquery=0) |
void | TerminateOpenAttempt () |
void | WaitForNewAsyncData () |
kXR_int64 | ReadVEach (char *buf, kXR_int64 *offsets, int *lens, int &nbuf) |
bool | IsOpenedForWrite () |
void | PrintCounters () |
Private Attributes | |
struct XrdClientOpenInfo | fOpenPars |
XrdSysCondVar * | fOpenProgCnd |
XrdClientThread * | fOpenerTh |
bool | fOpenWithRefresh |
XrdSysCondVar * | fReadWaitData |
struct XrdClientStatInfo | fStatInfo |
long | fReadTrimBlockSize |
bool | fUseCache |
XrdOucString | fInitialUrl |
XrdClientUrlInfo | fUrl |
XrdClientReadAheadMgr * | fReadAheadMgr |
Static Private Attributes | |
static XrdSysSemWait | fConcOpenSem |
Friends | |
void * | FileOpenerThread (void *, XrdClientThread *) |
XrdClient::XrdClient | ( | const char * | url, | |
XrdClientCallback * | XrdCcb = 0 , |
|||
void * | XrdCcbArg = 0 | |||
) |
virtual XrdClient::~XrdClient | ( | ) | [virtual] |
virtual bool XrdClient::CanRedirOnError | ( | ) | [inline, protected, virtual] |
Implements XrdClientAbs.
References fOpenPars, IsOpenedForWrite(), and XrdClientOpenInfo::opened.
bool XrdClient::Close | ( | ) |
bool XrdClient::Copy | ( | const char * | localpath | ) |
bool XrdClient::GetCacheInfo | ( | int & | size, | |
long long & | bytessubmitted, | |||
long long & | byteshit, | |||
long long & | misscount, | |||
float & | missrate, | |||
long long & | readreqcnt, | |||
float & | bytesusefulness | |||
) |
bool XrdClient::GetCounters | ( | XrdClientCounters * | cnt | ) |
bool XrdClient::IsOpen | ( | ) | [inline] |
References fOpenPars, and XrdClientOpenInfo::opened.
bool XrdClient::IsOpen_inprogress | ( | ) |
bool XrdClient::IsOpen_wait | ( | ) | [virtual] |
Reimplemented from XrdClientAbs.
bool XrdClient::IsOpenedForWrite | ( | ) | [inline, private] |
References fOpenPars, kXR_open_read, and XrdClientOpenInfo::options.
Referenced by CanRedirOnError().
bool XrdClient::LowOpen | ( | const char * | file, | |
kXR_unt16 | mode, | |||
kXR_unt16 | options, | |||
char * | additionalquery = 0 | |||
) | [private] |
virtual bool XrdClient::OpenFileWhenRedirected | ( | char * | newfhandle, | |
bool & | wasopen | |||
) | [protected, virtual] |
Implements XrdClientAbs.
void XrdClient::PrintCounters | ( | ) | [private] |
UnsolRespProcResult XrdClient::ProcessUnsolicitedMsg | ( | XrdClientUnsolMsgSender * | sender, | |
XrdClientMessage * | unsolmsg | |||
) | [virtual] |
Implements XrdClientAbsUnsolMsgHandler.
int XrdClient::Read | ( | void * | buf, | |
long long | offset, | |||
int | len | |||
) |
XReqErrorType XrdClient::Read_Async | ( | long long | offset, | |
int | len, | |||
bool | updatecounters = true | |||
) |
kXR_int64 XrdClient::ReadV | ( | char * | buf, | |
long long * | offsets, | |||
int * | lens, | |||
int | nbuf | |||
) |
kXR_int64 XrdClient::ReadVEach | ( | char * | buf, | |
kXR_int64 * | offsets, | |||
int * | lens, | |||
int & | nbuf | |||
) | [private] |
void XrdClient::RemoveAllDataFromCache | ( | ) |
void XrdClient::RemoveDataFromCache | ( | long long | begin_offs, | |
long long | end_offs, | |||
bool | remove_overlapped = false | |||
) |
void XrdClient::SetBlockReadTrimming | ( | int | blocksize | ) |
void XrdClient::SetCacheParameters | ( | int | CacheSize, | |
int | ReadAheadSize, | |||
int | RmPolicy | |||
) |
void XrdClient::SetReadAheadStrategy | ( | int | strategy | ) |
bool XrdClient::Stat | ( | struct XrdClientStatInfo * | stinfo, | |
bool | force = false | |||
) |
bool XrdClient::Sync | ( | ) |
void XrdClient::TerminateOpenAttempt | ( | ) | [private] |
bool XrdClient::Truncate | ( | long long | len | ) |
bool XrdClient::UseCache | ( | bool | u = true |
) |
void XrdClient::WaitForNewAsyncData | ( | ) | [private] |
bool XrdClient::Write | ( | const void * | buf, | |
long long | offset, | |||
int | len | |||
) |
void* FileOpenerThread | ( | void * | , | |
XrdClientThread * | ||||
) | [friend] |
XrdSysSemWait XrdClient::fConcOpenSem [static, private] |
XrdClientCounters XrdClient::fCounters [protected] |
std::vector<std::string> XrdClient::fExcludedHosts |
XrdOucString XrdClient::fInitialUrl [private] |
XrdClientThread* XrdClient::fOpenerTh [private] |
struct XrdClientOpenInfo XrdClient::fOpenPars [read, private] |
Referenced by CanRedirOnError(), IsOpen(), and IsOpenedForWrite().
XrdSysCondVar* XrdClient::fOpenProgCnd [private] |
bool XrdClient::fOpenWithRefresh [private] |
XrdClientReadAheadMgr* XrdClient::fReadAheadMgr [private] |
long XrdClient::fReadTrimBlockSize [private] |
XrdSysCondVar* XrdClient::fReadWaitData [private] |
struct XrdClientStatInfo XrdClient::fStatInfo [read, private] |
XrdClientUrlInfo XrdClient::fUrl [private] |
bool XrdClient::fUseCache [private] |