34 #include "tools/wroot/file"
35 #include "tools/wroot/ntuple"
41 fNtupleBuilder(ntupleBuilder),
42 fNtupleDirectory(nullptr),
71 <<
" " <<
"Ntuple file must be defined first."
73 <<
" " <<
"Cannot create main ntuples from builder.";
74 G4Exception(
"G4RootAnalysisManager::CreateNtuplesFromBooking",
83 ->
Message(
"create",
"main ntuple", ntupleBooking.name());
90 ntuple->set_basket_size(basketSize);
97 ->
Message(
"create",
"main ntuple", ntupleBooking.name());
110 <<
" " <<
"Ntuple file must be defined first."
112 <<
" " <<
"Cannot create main ntuples from builder.";
113 G4Exception(
"G4RootAnalysisManager::CreateNtuplesFromBooking",
118 auto& ntupleDescriptionVector
121 for (
auto ntupleDescription : ntupleDescriptionVector ) {
130 ntuple->merge_number_of_entries();
140 if ( deleteNtuple ) {
145 fNtupleVector.clear();
void Message(const G4String &action, const G4String &object, const G4String &objectName, G4bool success=true) const
std::ostringstream G4ExceptionDescription
void CreateNtuple(const tools::ntuple_booking &ntupleBooking, G4bool warn=true)
std::vector< tools::wroot::ntuple * > fNtupleVector
~G4RootMainNtupleManager()
const G4AnalysisVerbose * GetVerboseL3() const
const G4AnalysisVerbose * GetVerboseL4() const
G4bool Reset(G4bool deleteNtuple)
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
G4RootMainNtupleManager(G4RootNtupleManager *ntupleBuilder, const G4AnalysisManagerState &state)
void CreateNtuplesFromBooking()
G4RootNtupleManager * fNtupleBuilder
unsigned int GetBasketSize() const
const G4AnalysisManagerState & fState
tools::wroot::directory * fNtupleDirectory
const std::vector< NtupleDescriptionType * > & GetNtupleDescriptionVector() const