CGEM BOSS 6.6.5.h
BESIII Offline Software System
Loading...
Searching...
No Matches
RootAddress.h
Go to the documentation of this file.
1#ifndef RootAddress_H
2#define RootAddress_H 1
3
4#include <string>
5#include <vector>
6#include "GaudiKernel/StatusCode.h"
7#include "GaudiKernel/GenericAddress.h"
8
9#include "TObject.h"
10
11extern const long int ROOT_StorageType;
12
13/** @class RootAddress
14 * @brief Definition of a Root address, derived from IOpaqueAddress.
15 *
16 * Based on SICb's Address class.
17 * Contains Root Treenames and branchnames and nr of entry
18 * to be able to retrieve the object.
19 *Based on the RootAddress of Glast.
20 */
21class RootAddress : public GenericAddress {
22
23public:
25 RootAddress( unsigned char svc,const CLID& clid, const std::string path ="",const std::string treename ="",const std::string branchname ="",int entry=-1);
26 virtual ~RootAddress() {}
27 std::string getTreename() const {return m_treename;}
28 virtual void setTreename(std::string treename) {m_treename=treename;}
29 std::string getBranchname(int i) const ;
30 std::string getPath() const {return m_path;}
31 Int_t getEntryNr() const {return m_entrynr;}
32 Short_t getNrBranches() const {return m_nrBranches;}
33 void setEntryNr(int entry) {m_entrynr=entry;}
34 void Print() const;
35
36private:
37 /// name of TTree
38 std::string m_treename;
39 /// name of TBranch
40 std::string m_branchname;
41 /// path in TDS
42 std::string m_path;
43 /// entry number
44 Int_t m_entrynr;
45 /// nr of branches associated (m_branchname may contain cvoncatenation)
46 Short_t m_nrBranches;
47};
48
49
50#endif // RootAddress_H
const long int ROOT_StorageType
Definition of a Root address, derived from IOpaqueAddress.
Definition RootAddress.h:21
void setEntryNr(int entry)
Definition RootAddress.h:33
std::string getPath() const
Definition RootAddress.h:30
std::string getTreename() const
Definition RootAddress.h:27
Int_t getEntryNr() const
Definition RootAddress.h:31
std::string getBranchname(int i) const
void Print() const
virtual ~RootAddress()
Definition RootAddress.h:26
virtual void setTreename(std::string treename)
Definition RootAddress.h:28
Short_t getNrBranches() const
Definition RootAddress.h:32