g4tools  5.4.0
iobj_const_visitor
Go to the documentation of this file.
1 // Copyright (C) 2010, Guy Barrand. All rights reserved.
2 // See the file tools.license for terms.
3 
4 #ifndef tools_store_iobj_const_visitor
5 #define tools_store_iobj_const_visitor
6 
7 #include "../typedefs"
8 
9 #include <string>
10 #include <vector>
11 
12 namespace tools {
13 
14 class iobj_const_visitor;
15 
16 class istorable {
17 public:
18  virtual ~istorable() {}
19 public:
20  virtual void* cast(const std::string&) const = 0;
21 public:
22  virtual const std::string& store_cls() const = 0;
23  virtual bool visit(iobj_const_visitor&) const = 0;
24 // virtual bool read(iobj_visitor&) = 0;
25 };
26 
28 public:
29  virtual ~iobj_const_visitor() {}
30 public:
31  typedef bool(*local_func)(const istorable&,iobj_const_visitor&);
32 public:
33  virtual bool begin(const istorable&,const std::string&,local_func) = 0;
34  virtual bool end(const istorable&) = 0;
35 
36  virtual bool visit(const std::string&,bool) = 0;
37  virtual bool visit(const std::string&,char) = 0;
38 //virtual bool visit(const std::string&,unsigned char) = 0;
39  virtual bool visit(const std::string&,short) = 0;
40 //virtual bool visit(const std::string&,unsigned short) = 0;
41 
42  virtual bool visit(const std::string&,int) = 0;
43  virtual bool visit(const std::string&,unsigned int) = 0;
44 
45  virtual bool visit(const std::string&,int64) = 0;
46  virtual bool visit(const std::string&,uint64) = 0;
47 
48  virtual bool visit(const std::string&,float) = 0;
49  virtual bool visit(const std::string&,double) = 0;
50 
51  virtual bool visit(const std::string&,const std::string&) = 0;
52 //virtual bool visit(const std::string&,const char*) = 0;
53  virtual bool visit(const std::string&,const std::vector<bool>&) = 0;
54  virtual bool visit(const std::string&,const std::vector<char>&) = 0;
55  virtual bool visit(const std::string&,const std::vector<short>&) = 0;
56  virtual bool visit(const std::string&,const std::vector<int>&) = 0;
57  virtual bool visit(const std::string&,const std::vector<int64>&) = 0;
58  virtual bool visit(const std::string&,const std::vector<float>&) = 0;
59  virtual bool visit(const std::string&,const std::vector<double>&) = 0;
60 //virtual bool visit(const std::string&,const std::vector<unsigned char>&) = 0;
61  virtual bool visit(const std::string&,const std::vector<std::string>&) = 0;
62  virtual bool visit(const std::string&,const std::vector< std::vector<double> >&) = 0;
63 
64 //virtual bool visit_double(const std::string&,const IArray&) = 0;
65  virtual bool visit(const std::string&,const istorable&) = 0;
66 };
67 
68 }
69 
70 
71 #endif
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, double)=0
tools::iobj_const_visitor
Definition: iobj_const_visitor:27
tools::uint64
unsigned long long uint64
Definition: typedefs:72
tools::int64
long long int64
Definition: typedefs:67
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const istorable &)=0
tools::istorable::~istorable
virtual ~istorable()
Definition: iobj_const_visitor:18
tools::iobj_const_visitor::begin
virtual bool begin(const istorable &, const std::string &, local_func)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, float)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< bool > &)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< double > &)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< std::vector< double > > &)=0
tools::iobj_const_visitor::~iobj_const_visitor
virtual ~iobj_const_visitor()
Definition: iobj_const_visitor:29
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, char)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, int64)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, unsigned int)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< float > &)=0
tools::istorable
Definition: iobj_const_visitor:16
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, bool)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< char > &)=0
tools::istorable::cast
virtual void * cast(const std::string &) const =0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, short)=0
tools::istorable::store_cls
virtual const std::string & store_cls() const =0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, uint64)=0
tools
inlined C code : ///////////////////////////////////
Definition: aida_ntuple:26
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< short > &)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< int64 > &)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::string &)=0
tools::iobj_const_visitor::local_func
bool(* local_func)(const istorable &, iobj_const_visitor &)
Definition: iobj_const_visitor:31
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, int)=0
tools::iobj_const_visitor::end
virtual bool end(const istorable &)=0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< std::string > &)=0
tools::istorable::visit
virtual bool visit(iobj_const_visitor &) const =0
tools::iobj_const_visitor::visit
virtual bool visit(const std::string &, const std::vector< int > &)=0