CMS 3D CMS Logo

TFileAdaptor.h
Go to the documentation of this file.
1 #ifndef IOPool_TFileAdaptor_TFileAdaptor_h
2 #define IOPool_TFileAdaptor_TFileAdaptor_h
3 
5 
6 #include <map>
7 #include <memory>
8 #include <string>
9 #include <vector>
10 
11 class TPluginManager;
12 
13 namespace edm {
14  class ActivityRegistry;
16  class ParameterSet;
17 } // namespace edm
18 
19 // Driver for configuring ROOT plug-in manager to use TStorageFactoryFile.
20 class TFileAdaptor {
21 public:
23 
24  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
25 
26  friend class TFileAdaptorUI;
27 
28 private:
29  // Write current Storage statistics on a ostream
30  void termination(void) const;
31 
32  //Called by TFileAdaptorUI
33  void stats(std::ostream& o) const;
34 
35  void statsXML(std::map<std::string, std::string>& data) const;
36 
37  static void addType(TPluginManager* mgr, char const* type, int altType = 0);
38  bool native(char const* proto) const;
39 
40  bool enabled_;
41  bool doStats_;
46  double minFree_;
47  unsigned int timeout_;
48  unsigned int debugLevel_;
49  std::vector<std::string> native_;
50 };
51 
52 namespace edm {
53  namespace service {
54  inline bool isProcessWideService(TFileAdaptor const*) { return true; }
55  } // namespace service
56 } // namespace edm
57 
58 /*
59  * wrapper to bind TFileAdaptor to root, python etc
60  * loading IOPoolTFileAdaptor library and instantiating
61  * TFileAdaptorUI will make root to use StorageAdaptor for I/O instead
62  * of its own plugins
63  */
64 
66 public:
69 
70  // print current Storage statistics on cout
71  void stats() const;
72 
73 private:
75 };
76 
77 #endif
unsigned int timeout_
Definition: TFileAdaptor.h:47
bool native(char const *proto) const
Definition: TFileAdaptor.cc:64
std::string cacheHint_
Definition: TFileAdaptor.h:43
bool isProcessWideService(TFileService const *)
Definition: TFileService.h:98
std::string readHint_
Definition: TFileAdaptor.h:44
void termination(void) const
edm::propagate_const< std::shared_ptr< TFileAdaptor > > me
Definition: TFileAdaptor.h:74
double minFree_
Definition: TFileAdaptor.h:46
std::string tempDir_
Definition: TFileAdaptor.h:45
unsigned int debugLevel_
Definition: TFileAdaptor.h:48
bool enablePrefetching_
Definition: TFileAdaptor.h:42
void stats(std::ostream &o) const
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
std::vector< std::string > native_
Definition: TFileAdaptor.h:49
static void addType(TPluginManager *mgr, char const *type, int altType=0)
Definition: TFileAdaptor.cc:38
TFileAdaptor(edm::ParameterSet const &pset, edm::ActivityRegistry &ar)
Definition: TFileAdaptor.cc:69
HLT enums.
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
void statsXML(std::map< std::string, std::string > &data) const
void stats() const