GSI Object Oriented Online Offline (Go4)  GO4-6.3.0
TGo4TreeProxy.h
Go to the documentation of this file.
1 // $Id$
2 //-----------------------------------------------------------------------
3 // The GSI Online Offline Object Oriented (Go4) Project
4 // Experiment Data Processing at EE department, GSI
5 //-----------------------------------------------------------------------
6 // Copyright (C) 2000- GSI Helmholtzzentrum fuer Schwerionenforschung GmbH
7 // Planckstr. 1, 64291 Darmstadt, Germany
8 // Contact: http://go4.gsi.de
9 //-----------------------------------------------------------------------
10 // This software can be used under the license agreements as stated
11 // in Go4License.txt file which is part of the distribution.
12 //-----------------------------------------------------------------------
13 
14 #ifndef TGO4TREESLOT_H
15 #define TGO4TREESLOT_H
16 
17 #include "TGo4Proxy.h"
18 
19 class TTree;
20 
21 class TGo4TreeProxy : public TGo4Proxy {
22  public:
23  TGo4TreeProxy();
24  TGo4TreeProxy(TTree *tree, Bool_t owner = kFALSE);
25  virtual ~TGo4TreeProxy();
26 
27  Bool_t HasSublevels() const override { return fTree!=nullptr; }
28 
29  TGo4LevelIter *MakeIter() override
30  { return !fTree ? nullptr : ProduceIter(fTree); }
31 
32  std::unique_ptr<TGo4Access> ProvideAccess(const char *name) override
33  { return CreateAccess(fTree, name); }
34 
35  Int_t GetObjectKind() const override;
36  const char *GetContainedClassName() const override;
37 
38  static std::unique_ptr<TGo4Access> CreateAccess(TTree *tree, const char *name);
39  static TGo4LevelIter *ProduceIter(TTree *tree);
40 
41  protected:
42  TTree *fTree{nullptr};
43  Bool_t fOwner{kFALSE};
44 
46 };
47 
48 #endif
49 
static TGo4LevelIter * ProduceIter(TTree *tree)
ClassDefOverride(TGo4TreeProxy, 1)
TGo4LevelIter * MakeIter() override
Definition: TGo4TreeProxy.h:29
std::unique_ptr< TGo4Access > ProvideAccess(const char *name) override
Definition: TGo4TreeProxy.h:32
Bool_t HasSublevels() const override
Definition: TGo4TreeProxy.h:27
Int_t GetObjectKind() const override
virtual ~TGo4TreeProxy()
static std::unique_ptr< TGo4Access > CreateAccess(TTree *tree, const char *name)
const char * GetContainedClassName() const override