12 #ifndef ROOT_TBranchProxyTemplate 13 #define ROOT_TBranchProxyTemplate 15 #if R__BRANCHPROXY_GENERATOR_VERSION != 2 17 # error "Please regenerate this file using TTree::MakeProxy()!" 22 #define InjecTBranchProxyInterface() \ 23 ROOT::Detail::TBranchProxy *GetProxy() { return obj.GetProxy(); } \ 24 void Reset() { obj.Reset(); } \ 25 bool Setup() { return obj.Setup(); } \ 26 bool IsInitialized() { return obj.IsInitialized(); } \ 27 bool IsaPointer() const { return obj.IsaPointer(); } \ 28 bool Read() { return obj.Read(); } 41 obj(director,top,name) {};
43 obj(director,top,name,data) {};
45 obj(director,parent, name, top,
mid) {};
52 std::cout <<
"fWhere " << obj.
GetWhere() << std::endl;
58 if (!obj.
Read())
return 0;
78 std::cout <<
"obj.GetWhere() " << obj.
GetWhere() << std::endl;
85 obj(director,top,name) {};
87 obj(director,top,name,data) {};
89 obj(director,parent, name, top,
mid) {};
98 if (!obj.
Read())
return &default_val;
99 if (obj.
GetWhere()==0)
return &default_val;
102 if (temp)
return temp;
103 else return &default_val;
106 const T* operator [](
Int_t i) {
return At(i); }
107 const T* operator [](
UInt_t i) {
return At(i); }
120 std::cout <<
"obj.GetWhere() " << obj.
GetWhere() << std::endl;
127 obj(director,top,name) {};
129 obj(director,top,name,data) {};
131 obj(director,parent, name, top,
mid) {};
141 static const value_t default_val;
142 if (!obj.
Read())
return default_val;
143 if (obj.
GetWhere()==0)
return default_val;
146 if (temp)
return *temp;
147 else return default_val;
150 const value_t& operator [](
Int_t i) {
return At(i); }
151 const value_t& operator [](
UInt_t i) {
return At(i); }
167 TObjProxy<
T>(director,top,name),fCollection(0) {};
169 TObjProxy<
T>(director,top,name,data),fCollection(0) {};
171 TObjProxy<
T>(director,parent, name, top,
mid),fCollection(0) {};
175 if (fCollection==0) {
188 if (!fCollection)
return 0;
190 return fCollection->
Size();
196 static value_t default_val;
200 if (!fCollection)
return 0;
202 return *(value_t*)(fCollection->
At(i));
204 else return default_val;
207 const value_t operator [](
Int_t i) {
return At(i); }
208 const value_t operator [](
UInt_t i) {
return At(i); }
you should not use this method at all Int_t Int_t Double_t Double_t Double_t Int_t mid
Namespace for new ROOT classes and functions.
TStlObjProxy(TBranchProxyDirector *director, Detail::TBranchProxy *parent, const char *name, const char *top=0, const char *mid=0)
TObjProxy(TBranchProxyDirector *director, const char *top, const char *name, const char *data)
TVirtualCollectionProxy * GetCollectionProxy() const
Return the proxy describing the collection (if any).
virtual void * GetStart(UInt_t=0)
const value_t & At(UInt_t i)
TStlObjProxy(TBranchProxyDirector *director, const char *top, const char *name)
TClaObjProxy(TBranchProxyDirector *director, const char *top, const char *name)
TStlObjProxy(TBranchProxyDirector *director, const char *top, const char *name, const char *data)
const TClonesArray * GetPtr()
TStlSimpleProxy(TBranchProxyDirector *director, Detail::TBranchProxy *parent, const char *name, const char *top=0, const char *mid=0)
TObjProxy(TBranchProxyDirector *director, const char *name)
TClaObjProxy(TBranchProxyDirector *director, const char *name)
TStlSimpleProxy(TBranchProxyDirector *director, const char *name)
TClaObjProxy(TBranchProxyDirector *director, Detail::TBranchProxy *parent, const char *name, const char *top=0, const char *mid=0)
virtual void * GetClaStart(UInt_t i=0)
TClaObjProxy(TBranchProxyDirector *director, const char *top, const char *name, const char *data)
TVirtualCollectionProxy * GetCollection()
TStlSimpleProxy(TBranchProxyDirector *director, const char *top, const char *name)
TStlObjProxy(TBranchProxyDirector *director, const char *name)
TObjProxy(TBranchProxyDirector *director, const char *top, const char *name)
The ROOT global object gROOT contains a list of all defined classes.
const TVirtualCollectionProxy * GetPtr()
TObjProxy(TBranchProxyDirector *director, Detail::TBranchProxy *parent, const char *name, const char *top=0, const char *mid=0)
TVirtualCollectionProxy * GetCollection()
virtual void * At(UInt_t idx)=0
virtual void * GetStlStart(UInt_t i=0)
const value_t At(UInt_t i)
static TClass * GetClass(const char *name, Bool_t load=kTRUE, Bool_t silent=kFALSE)
Static method returning pointer to TClass of the specified class name.
virtual UInt_t Size() const =0
const TClonesArray * GetPtr()
An array of clone (identical) objects.
InjecTBranchProxyInterface()
Base class for all the proxy object.
TVirtualCollectionProxy * fCollection
TStlSimpleProxy(TBranchProxyDirector *director, const char *top, const char *name, const char *data)
virtual TVirtualCollectionProxy * Generate() const =0