78 template <
typename OutputType>
void setBranch(
const std::string& name, OutputType* ptr )
80 IReadBranch* new_branch =
nullptr;
81 auto branchType = getBranchType(name);
82 if( branchType ==
"Double_t" ) new_branch =
new ReadBranch<Double_t , OutputType>( name, ptr );
83 if( branchType ==
"Float_t" ) new_branch =
new ReadBranch<Float_t , OutputType>( name, ptr );
84 if( branchType ==
"Bool_t" ) new_branch =
new ReadBranch<Bool_t , OutputType>( name, ptr );
85 if( branchType ==
"Int_t" ) new_branch =
new ReadBranch<Int_t , OutputType>( name, ptr );
86 if( branchType ==
"UInt_t" ) new_branch =
new ReadBranch<UInt_t , OutputType>( name, ptr );
87 if( branchType ==
"ULong64_t") new_branch =
new ReadBranch<ULong64_t, OutputType>( name, ptr );
88 if( new_branch ==
nullptr ){
89 ERROR(
"Branch type:" << branchType <<
" not recognised" );
92 DEBUG(
"Making branch with properties: [name = " << name <<
", input type = " << branchType <<
" output type = " <<
type_string<OutputType>() <<
"]" );
94 m_branches.push_back( new_branch );