xrootd
XrdClientReadAhead.hh
Go to the documentation of this file.
1 
2 // //
3 // XrdClientReadAhead //
4 // //
5 // Author: Fabrizio Furano (CERN IT-DM, 2009) //
6 // //
7 // Classes to implement a selectable read ahead decision maker //
8 // //
10 
11 // $Id$
12 
13 #ifndef XRD_CLI_READAHEAD
14 #define XRD_CLI_READAHEAD
15 
16 
17 
19 public:
24  };
25 
26 protected:
27  long RASize;
29 
30 public:
31 
33 
34 
36  virtual ~XrdClientReadAheadMgr() {};
37 
38  virtual int GetReadAheadHint(long long offset, long len, long long &raoffset, long &ralen, long blksize) = 0;
39  virtual int Reset() = 0;
40  virtual void SetRASize(long bytes) { RASize = bytes; };
41 
42  static bool TrimReadRequest(long long &offs, long &len, long rasize, long blksize);
43 
45 };
46 
47 
48 
49 
50 
51 
52 
53 
54 #endif