#include <RootAddress.h>
Public Member Functions | |
std::string | getBranchname (int i) const |
std::string | getBranchname (int i) const |
Int_t | getEntryNr () const |
Int_t | getEntryNr () const |
Short_t | getNrBranches () const |
Short_t | getNrBranches () const |
std::string | getPath () const |
std::string | getPath () const |
std::string | getTreename () const |
std::string | getTreename () const |
void | Print () const |
void | Print () const |
RootAddress (unsigned char svc, const CLID &clid, const std::string path="", const std::string treename="", const std::string branchname="", int entry=-1) | |
RootAddress () | |
RootAddress (unsigned char svc, const CLID &clid, const std::string path="", const std::string treename="", const std::string branchname="", int entry=-1) | |
RootAddress () | |
void | setEntryNr (int entry) |
void | setEntryNr (int entry) |
virtual void | setTreename (std::string treename) |
virtual void | setTreename (std::string treename) |
virtual | ~RootAddress () |
virtual | ~RootAddress () |
Private Attributes | |
std::string | m_branchname |
name of TBranch | |
Int_t | m_entrynr |
entry number | |
Short_t | m_nrBranches |
nr of branches associated (m_branchname may contain cvoncatenation) | |
std::string | m_path |
path in TDS | |
std::string | m_treename |
name of TTree |
Based on SICb's Address class. Contains Root Treenames and branchnames and nr of entry to be able to retrieve the object. Based on the RootAddress of Glast.
|
00024 {;}
|
|
00008 : GenericAddress(svc, clid, path, "", 0, 0) 00009 { 00010 // parse branchname and store what has to be read 00011 m_branchname = branchname; 00012 int s=branchname.size(); 00013 m_nrBranches=0; 00014 if (branchname.size()) { 00015 int pos=0,where=1; 00016 while (where!=std::string::npos) { 00017 m_nrBranches++; 00018 where=branchname.find(":",pos); 00019 pos=where+1; 00020 } 00021 } 00022 00023 m_treename = treename; 00024 m_path=path; 00025 m_entrynr=entry; 00026 }
|
|
00026 {}
|
|
00024 {;}
|
|
|
|
00026 {}
|
|
|
|
00031 { 00032 int pos,where=-1; 00033 int i=0; 00034 while (i<=nb) { 00035 pos=where+1; 00036 where=m_branchname.find(":",pos); 00037 i++; 00038 } 00039 if (where==std::string::npos) where=m_branchname.size(); 00040 00041 return m_branchname.substr(pos,where-pos); 00042 }
|
|
00031 {return m_entrynr;}
|
|
00031 {return m_entrynr;}
|
|
00032 {return m_nrBranches;}
|
|
00032 {return m_nrBranches;}
|
|
00030 {return m_path;}
|
|
00030 {return m_path;}
|
|
00027 {return m_treename;}
|
|
00027 {return m_treename;}
|
|
|
|
00027 { 00028 std::cout << "RootAddress: path "<<m_path<< ", treename "<<m_treename <<" branchname "<<m_branchname<<" entry "<<m_entrynr<<std::endl; 00029 }
|
|
00033 {m_entrynr=entry;}
|
|
00033 {m_entrynr=entry;}
|
|
00028 {m_treename=treename;}
|
|
00028 {m_treename=treename;}
|
|
name of TBranch
|
|
entry number
|
|
nr of branches associated (m_branchname may contain cvoncatenation)
|
|
path in TDS
|
|
name of TTree
|