Geant4 10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4CsvAnalysisManager Class Reference

#include <G4CsvAnalysisManager.hh>

+ Inheritance diagram for G4CsvAnalysisManager:

Public Member Functions

 G4CsvAnalysisManager (G4bool isMaster=true)
 
 ~G4CsvAnalysisManager ()
 
tools::wcsv::ntuple * GetNtuple () const
 
tools::wcsv::ntuple * GetNtuple (G4int ntupleId) const
 
std::vector< tools::wcsv::ntuple * >::iterator BeginNtuple ()
 
std::vector< tools::wcsv::ntuple * >::iterator EndNtuple ()
 
std::vector< tools::wcsv::ntuple * >::const_iterator BeginConstNtuple () const
 
std::vector< tools::wcsv::ntuple * >::const_iterator EndConstNtuple () const
 
void SetIsCommentedHeader (G4bool isCommentedHeader)
 
void SetIsHippoHeader (G4bool isHippoHeader)
 
- Public Member Functions inherited from G4ToolsAnalysisManager
 G4ToolsAnalysisManager (const G4String &type, G4bool isMaster=true)
 
virtual ~G4ToolsAnalysisManager ()
 
tools::histo::h1d * GetH1 (G4int id, G4bool warn=true, G4bool onlyIfActive=true) const
 
tools::histo::h2d * GetH2 (G4int id, G4bool warn=true, G4bool onlyIfActive=true) const
 
tools::histo::h3d * GetH3 (G4int id, G4bool warn=true, G4bool onlyIfActive=true) const
 
tools::histo::p1d * GetP1 (G4int id, G4bool warn=true, G4bool onlyIfActive=true) const
 
tools::histo::p2d * GetP2 (G4int id, G4bool warn=true, G4bool onlyIfActive=true) const
 
std::vector< tools::histo::h1d * >::iterator BeginH1 ()
 
std::vector< tools::histo::h1d * >::iterator EndH1 ()
 
std::vector< tools::histo::h1d * >::const_iterator BeginConstH1 () const
 
std::vector< tools::histo::h1d * >::const_iterator EndConstH1 () const
 
std::vector< tools::histo::h2d * >::iterator BeginH2 ()
 
std::vector< tools::histo::h2d * >::iterator EndH2 ()
 
std::vector< tools::histo::h2d * >::const_iterator BeginConstH2 () const
 
std::vector< tools::histo::h2d * >::const_iterator EndConstH2 () const
 
std::vector< tools::histo::h3d * >::iterator BeginH3 ()
 
std::vector< tools::histo::h3d * >::iterator EndH3 ()
 
std::vector< tools::histo::h3d * >::const_iterator BeginConstH3 () const
 
std::vector< tools::histo::h3d * >::const_iterator EndConstH3 () const
 
std::vector< tools::histo::p1d * >::iterator BeginP1 ()
 
std::vector< tools::histo::p1d * >::iterator EndP1 ()
 
std::vector< tools::histo::p1d * >::const_iterator BeginConstP1 () const
 
std::vector< tools::histo::p1d * >::const_iterator EndConstP1 () const
 
std::vector< tools::histo::p2d * >::iterator BeginP2 ()
 
std::vector< tools::histo::p2d * >::iterator EndP2 ()
 
std::vector< tools::histo::p2d * >::const_iterator BeginConstP2 () const
 
std::vector< tools::histo::p2d * >::const_iterator EndConstP2 () const
 
std::vector< tools::wroot::ntuple * >::iterator BeginNtuple ()
 
std::vector< tools::wroot::ntuple * >::iterator EndNtuple ()
 
std::vector< tools::wroot::ntuple * >::const_iterator BeginConstNtuple () const
 
std::vector< tools::wroot::ntuple * >::const_iterator EndConstNtuple () const
 
- Public Member Functions inherited from G4VAnalysisManager
 G4VAnalysisManager (const G4String &type, G4bool isMaster)
 
virtual ~G4VAnalysisManager ()
 
G4bool OpenFile (const G4String &fileName="")
 
G4bool Write ()
 
G4bool CloseFile (G4bool reset=true)
 
G4bool Merge (tools::histo::hmpi *hmpi)
 
G4bool Plot ()
 
G4bool IsOpenFile () const
 
G4bool SetFileName (const G4String &fileName)
 
G4bool SetHistoDirectoryName (const G4String &dirName)
 
G4bool SetNtupleDirectoryName (const G4String &dirName)
 
void SetCompressionLevel (G4int level)
 
G4String GetFileName () const
 
G4String GetHistoDirectoryName () const
 
G4String GetNtupleDirectoryName () const
 
G4int GetCompressionLevel () const
 
G4int CreateH1 (const G4String &name, const G4String &title, G4int nbins, G4double xmin, G4double xmax, const G4String &unitName="none", const G4String &fcnName="none", const G4String &binSchemeName="linear")
 
G4int CreateH1 (const G4String &name, const G4String &title, const std::vector< G4double > &edges, const G4String &unitName="none", const G4String &fcnName="none")
 
G4int CreateH2 (const G4String &name, const G4String &title, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &xbinSchemeName="linear", const G4String &ybinSchemeName="linear")
 
G4int CreateH2 (const G4String &name, const G4String &title, const std::vector< G4double > &xedges, const std::vector< G4double > &yedges, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none")
 
G4int CreateH3 (const G4String &name, const G4String &title, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, G4int nzbins, G4double zmin, G4double zmax, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none", const G4String &xbinSchemeName="linear", const G4String &ybinSchemeName="linear", const G4String &zbinSchemeName="linear")
 
G4int CreateH3 (const G4String &name, const G4String &title, const std::vector< G4double > &xedges, const std::vector< G4double > &yedges, const std::vector< G4double > &zedges, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none")
 
G4bool SetH1 (G4int id, G4int nbins, G4double xmin, G4double xmax, const G4String &unitName="none", const G4String &fcnName="none", const G4String &binSchemeName="linear")
 
G4bool SetH1 (G4int id, const std::vector< G4double > &edges, const G4String &unitName="none", const G4String &fcnName="none")
 
G4bool SetH2 (G4int id, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &xbinSchemeName="linear", const G4String &ybinSchemeName="linear")
 
G4bool SetH2 (G4int id, const std::vector< G4double > &xedges, const std::vector< G4double > &yedges, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none")
 
G4bool SetH3 (G4int id, G4int nxbins, G4double xmin, G4double xmax, G4int nzbins, G4double zmin, G4double zmax, G4int nybins, G4double ymin, G4double ymax, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none", const G4String &xbinSchemeName="linear", const G4String &ybinSchemeName="linear", const G4String &zbinSchemeName="linear")
 
G4bool SetH3 (G4int id, const std::vector< G4double > &xedges, const std::vector< G4double > &yedges, const std::vector< G4double > &zedges, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none")
 
G4bool ScaleH1 (G4int id, G4double factor)
 
G4bool ScaleH2 (G4int id, G4double factor)
 
G4bool ScaleH3 (G4int id, G4double factor)
 
G4int CreateP1 (const G4String &name, const G4String &title, G4int nbins, G4double xmin, G4double xmax, G4double ymin=0, G4double ymax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &xbinSchemeName="linear")
 
G4int CreateP1 (const G4String &name, const G4String &title, const std::vector< G4double > &edges, G4double ymin=0, G4double ymax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none")
 
G4int CreateP2 (const G4String &name, const G4String &title, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, G4double zmin=0, G4double zmax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none", const G4String &xbinSchemeName="linear", const G4String &ybinSchemeName="linear")
 
G4int CreateP2 (const G4String &name, const G4String &title, const std::vector< G4double > &xedges, const std::vector< G4double > &yedges, G4double zmin=0, G4double zmax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none")
 
G4bool SetP1 (G4int id, G4int nbins, G4double xmin, G4double xmax, G4double ymin=0, G4double ymax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &xbinSchemeName="linear")
 
G4bool SetP1 (G4int id, const std::vector< G4double > &edges, G4double ymin=0, G4double ymax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none")
 
G4bool SetP2 (G4int id, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, G4double zmin=0, G4double zmax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none", const G4String &xbinSchemeName="linear", const G4String &ybinSchemeName="linear")
 
G4bool SetP2 (G4int id, const std::vector< G4double > &xedges, const std::vector< G4double > &yedges, G4double zmin=0, G4double zmax=0, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &zunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none", const G4String &zfcnName="none")
 
G4bool ScaleP1 (G4int id, G4double factor)
 
G4bool ScaleP2 (G4int id, G4double factor)
 
G4int CreateNtuple (const G4String &name, const G4String &title)
 
G4int CreateNtupleIColumn (const G4String &name)
 
G4int CreateNtupleFColumn (const G4String &name)
 
G4int CreateNtupleDColumn (const G4String &name)
 
G4int CreateNtupleSColumn (const G4String &name)
 
G4int CreateNtupleIColumn (const G4String &name, std::vector< int > &vector)
 
G4int CreateNtupleFColumn (const G4String &name, std::vector< float > &vector)
 
G4int CreateNtupleDColumn (const G4String &name, std::vector< double > &vector)
 
void FinishNtuple ()
 
G4int CreateNtupleIColumn (G4int ntupleId, const G4String &name)
 
G4int CreateNtupleFColumn (G4int ntupleId, const G4String &name)
 
G4int CreateNtupleDColumn (G4int ntupleId, const G4String &name)
 
G4int CreateNtupleSColumn (G4int ntupleId, const G4String &name)
 
G4int CreateNtupleIColumn (G4int ntupleId, const G4String &name, std::vector< int > &vector)
 
G4int CreateNtupleFColumn (G4int ntupleId, const G4String &name, std::vector< float > &vector)
 
G4int CreateNtupleDColumn (G4int ntupleId, const G4String &name, std::vector< double > &vector)
 
void FinishNtuple (G4int ntupleId)
 
virtual void SetNtupleMerging (G4bool mergeNtuples, G4int nofReducedNtupleFiles=0)
 
virtual void SetNtupleRowWise (G4bool rowWise, G4bool rowMode=true)
 
virtual void SetBasketSize (unsigned int basketSize)
 
virtual void SetBasketEntries (unsigned int basketEntries)
 
G4bool SetFirstHistoId (G4int firstId)
 
G4bool SetFirstH1Id (G4int firstId)
 
G4bool SetFirstH2Id (G4int firstId)
 
G4bool SetFirstH3Id (G4int firstId)
 
G4bool SetFirstProfileId (G4int firstId)
 
G4bool SetFirstP1Id (G4int firstId)
 
G4bool SetFirstP2Id (G4int firstId)
 
G4bool SetFirstNtupleId (G4int firstId)
 
G4bool SetFirstNtupleColumnId (G4int firstId)
 
G4bool FillH1 (G4int id, G4double value, G4double weight=1.0)
 
G4bool FillH2 (G4int id, G4double xvalue, G4double yvalue, G4double weight=1.0)
 
G4bool FillH3 (G4int id, G4double xvalue, G4double yvalue, G4double zvalue, G4double weight=1.0)
 
G4bool FillP1 (G4int id, G4double xvalue, G4double yvalue, G4double weight=1.0)
 
G4bool FillP2 (G4int id, G4double xvalue, G4double yvalue, G4double zvalue, G4double weight=1.0)
 
G4bool FillNtupleIColumn (G4int id, G4int value)
 
G4bool FillNtupleFColumn (G4int id, G4float value)
 
G4bool FillNtupleDColumn (G4int id, G4double value)
 
G4bool FillNtupleSColumn (G4int id, const G4String &value)
 
G4bool AddNtupleRow ()
 
G4bool FillNtupleIColumn (G4int ntupleId, G4int columnId, G4int value)
 
G4bool FillNtupleFColumn (G4int ntupleId, G4int columnId, G4float value)
 
G4bool FillNtupleDColumn (G4int ntupleId, G4int columnId, G4double value)
 
G4bool FillNtupleSColumn (G4int ntupleId, G4int id, const G4String &value)
 
G4bool AddNtupleRow (G4int ntupleId)
 
void SetActivation (G4bool activation)
 
G4bool GetActivation () const
 
G4bool IsActive () const
 
G4bool IsAscii () const
 
G4bool IsPlotting () const
 
G4int GetFirstH1Id () const
 
G4int GetFirstH2Id () const
 
G4int GetFirstH3Id () const
 
G4int GetFirstP1Id () const
 
G4int GetFirstP2Id () const
 
G4int GetFirstNtupleId () const
 
G4int GetFirstNtupleColumnId () const
 
G4int GetNofH1s () const
 
G4int GetNofH2s () const
 
G4int GetNofH3s () const
 
G4int GetNofP1s () const
 
G4int GetNofP2s () const
 
G4int GetNofNtuples () const
 
G4int GetH1Id (const G4String &name, G4bool warn=true) const
 
G4int GetH2Id (const G4String &name, G4bool warn=true) const
 
G4int GetH3Id (const G4String &name, G4bool warn=true) const
 
G4int GetP1Id (const G4String &name, G4bool warn=true) const
 
G4int GetP2Id (const G4String &name, G4bool warn=true) const
 
void SetH1Activation (G4bool activation)
 
void SetH1Activation (G4int id, G4bool activation)
 
void SetH1Ascii (G4int id, G4bool ascii)
 
void SetH1Plotting (G4int id, G4bool plotting)
 
void SetH1FileName (G4int id, const G4String &fileName)
 
void SetH2Activation (G4bool activation)
 
void SetH2Activation (G4int id, G4bool activation)
 
void SetH2Ascii (G4int id, G4bool ascii)
 
void SetH2Plotting (G4int id, G4bool plotting)
 
void SetH2FileName (G4int id, const G4String &fileName)
 
void SetH3Activation (G4bool activation)
 
void SetH3Activation (G4int id, G4bool activation)
 
void SetH3Ascii (G4int id, G4bool ascii)
 
void SetH3Plotting (G4int id, G4bool plotting)
 
void SetH3FileName (G4int id, const G4String &fileName)
 
void SetP1Activation (G4bool activation)
 
void SetP1Activation (G4int id, G4bool activation)
 
void SetP1Ascii (G4int id, G4bool ascii)
 
void SetP1Plotting (G4int id, G4bool plotting)
 
void SetP1FileName (G4int id, const G4String &fileName)
 
void SetP2Activation (G4bool activation)
 
void SetP2Activation (G4int id, G4bool activation)
 
void SetP2Ascii (G4int id, G4bool ascii)
 
void SetP2Plotting (G4int id, G4bool plotting)
 
void SetP2FileName (G4int id, const G4String &fileName)
 
void SetNtupleActivation (G4bool activation)
 
void SetNtupleActivation (G4int id, G4bool activation)
 
void SetNtupleFileName (const G4String &fileName)
 
void SetNtupleFileName (G4int id, const G4String &fileName)
 
G4int GetH1Nbins (G4int id) const
 
G4double GetH1Xmin (G4int id) const
 
G4double GetH1Xmax (G4int id) const
 
G4double GetH1Width (G4int id) const
 
G4int GetH2Nxbins (G4int id) const
 
G4double GetH2Xmin (G4int id) const
 
G4double GetH2Xmax (G4int id) const
 
G4double GetH2XWidth (G4int id) const
 
G4int GetH2Nybins (G4int id) const
 
G4double GetH2Ymin (G4int id) const
 
G4double GetH2Ymax (G4int id) const
 
G4double GetH2YWidth (G4int id) const
 
G4int GetH3Nxbins (G4int id) const
 
G4double GetH3Xmin (G4int id) const
 
G4double GetH3Xmax (G4int id) const
 
G4double GetH3XWidth (G4int id) const
 
G4int GetH3Nybins (G4int id) const
 
G4double GetH3Ymin (G4int id) const
 
G4double GetH3Ymax (G4int id) const
 
G4double GetH3YWidth (G4int id) const
 
G4int GetH3Nzbins (G4int id) const
 
G4double GetH3Zmin (G4int id) const
 
G4double GetH3Zmax (G4int id) const
 
G4double GetH3ZWidth (G4int id) const
 
G4int GetP1Nbins (G4int id) const
 
G4double GetP1Xmin (G4int id) const
 
G4double GetP1Xmax (G4int id) const
 
G4double GetP1XWidth (G4int id) const
 
G4double GetP1Ymin (G4int id) const
 
G4double GetP1Ymax (G4int id) const
 
G4int GetP2Nxbins (G4int id) const
 
G4double GetP2Xmin (G4int id) const
 
G4double GetP2Xmax (G4int id) const
 
G4double GetP2XWidth (G4int id) const
 
G4int GetP2Nybins (G4int id) const
 
G4double GetP2Ymin (G4int id) const
 
G4double GetP2Ymax (G4int id) const
 
G4double GetP2YWidth (G4int id) const
 
G4double GetP2Zmin (G4int id) const
 
G4double GetP2Zmax (G4int id) const
 
G4String GetH1Name (G4int id) const
 
G4double GetH1Unit (G4int id) const
 
G4bool GetH1Activation (G4int id) const
 
G4bool GetH1Ascii (G4int id) const
 
G4bool GetH1Plotting (G4int id) const
 
G4String GetH1FileName (G4int id) const
 
G4String GetH2Name (G4int id) const
 
G4double GetH2XUnit (G4int id) const
 
G4double GetH2YUnit (G4int id) const
 
G4bool GetH2Activation (G4int id) const
 
G4bool GetH2Ascii (G4int id) const
 
G4bool GetH2Plotting (G4int id) const
 
G4String GetH3Name (G4int id) const
 
G4double GetH3XUnit (G4int id) const
 
G4double GetH3YUnit (G4int id) const
 
G4double GetH3ZUnit (G4int id) const
 
G4bool GetH3Activation (G4int id) const
 
G4bool GetH3Ascii (G4int id) const
 
G4bool GetH3Plotting (G4int id) const
 
G4String GetP1Name (G4int id) const
 
G4double GetP1XUnit (G4int id) const
 
G4double GetP1YUnit (G4int id) const
 
G4bool GetP1Activation (G4int id) const
 
G4bool GetP1Ascii (G4int id) const
 
G4bool GetP1Plotting (G4int id) const
 
G4String GetP2Name (G4int id) const
 
G4double GetP2XUnit (G4int id) const
 
G4double GetP2YUnit (G4int id) const
 
G4double GetP2ZUnit (G4int id) const
 
G4bool GetP2Activation (G4int id) const
 
G4bool GetP2Ascii (G4int id) const
 
G4bool GetP2Plotting (G4int id) const
 
G4bool GetNtupleActivation (G4int id) const
 
G4String GetNtupleFileName (G4int id) const
 
G4bool SetH1Title (G4int id, const G4String &title)
 
G4bool SetH1XAxisTitle (G4int id, const G4String &title)
 
G4bool SetH1YAxisTitle (G4int id, const G4String &title)
 
G4bool SetH1XAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetH1YAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetH2Title (G4int id, const G4String &title)
 
G4bool SetH2XAxisTitle (G4int id, const G4String &title)
 
G4bool SetH2YAxisTitle (G4int id, const G4String &title)
 
G4bool SetH2ZAxisTitle (G4int id, const G4String &title)
 
G4bool SetH2XAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetH2YAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetH2ZAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetH3Title (G4int id, const G4String &title)
 
G4bool SetH3XAxisTitle (G4int id, const G4String &title)
 
G4bool SetH3YAxisTitle (G4int id, const G4String &title)
 
G4bool SetH3ZAxisTitle (G4int id, const G4String &title)
 
G4bool SetH3XAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetH3YAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetH3ZAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetP1Title (G4int id, const G4String &title)
 
G4bool SetP1XAxisTitle (G4int id, const G4String &title)
 
G4bool SetP1YAxisTitle (G4int id, const G4String &title)
 
G4bool SetP1XAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetP1YAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetP2Title (G4int id, const G4String &title)
 
G4bool SetP2XAxisTitle (G4int id, const G4String &title)
 
G4bool SetP2YAxisTitle (G4int id, const G4String &title)
 
G4bool SetP2ZAxisTitle (G4int id, const G4String &title)
 
G4bool SetP2XAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetP2YAxisIsLog (G4int id, G4bool isLog)
 
G4bool SetP2ZAxisIsLog (G4int id, G4bool isLog)
 
G4String GetH1Title (G4int id) const
 
G4String GetH1XAxisTitle (G4int id) const
 
G4String GetH1YAxisTitle (G4int id) const
 
G4bool GetH1XAxisIsLog (G4int id) const
 
G4bool GetH1YAxisIsLog (G4int id) const
 
G4String GetH2Title (G4int id) const
 
G4String GetH2XAxisTitle (G4int id) const
 
G4String GetH2YAxisTitle (G4int id) const
 
G4String GetH2ZAxisTitle (G4int id) const
 
G4bool GetH2XAxisIsLog (G4int id) const
 
G4bool GetH2YAxisIsLog (G4int id) const
 
G4bool GetH2ZAxisIsLog (G4int id) const
 
G4String GetH3Title (G4int id) const
 
G4String GetH3XAxisTitle (G4int id) const
 
G4String GetH3YAxisTitle (G4int id) const
 
G4String GetH3ZAxisTitle (G4int id) const
 
G4bool GetH3XAxisIsLog (G4int id) const
 
G4bool GetH3YAxisIsLog (G4int id) const
 
G4bool GetH3ZAxisIsLog (G4int id) const
 
G4String GetP1Title (G4int id) const
 
G4String GetP1XAxisTitle (G4int id) const
 
G4String GetP1YAxisTitle (G4int id) const
 
G4bool GetP1XAxisIsLog (G4int id) const
 
G4bool GetP1YAxisIsLog (G4int id) const
 
G4String GetP2Title (G4int id) const
 
G4String GetP2XAxisTitle (G4int id) const
 
G4String GetP2YAxisTitle (G4int id) const
 
G4String GetP2ZAxisTitle (G4int id) const
 
G4bool GetP2XAxisIsLog (G4int id) const
 
G4bool GetP2YAxisIsLog (G4int id) const
 
G4bool GetP2ZAxisIsLog (G4int id) const
 
void SetVerboseLevel (G4int verboseLevel)
 
G4int GetVerboseLevel () const
 
G4String GetType () const
 
G4String GetFileType () const
 

Static Public Member Functions

static G4CsvAnalysisManagerInstance ()
 
static G4bool IsInstance ()
 
- Static Public Member Functions inherited from G4ToolsAnalysisManager
static G4ToolsAnalysisManagerInstance ()
 
static G4bool IsInstance ()
 

Protected Member Functions

virtual G4bool OpenFileImpl (const G4String &fileName) final
 
virtual G4bool WriteImpl () final
 
virtual G4bool CloseFileImpl (G4bool reset) final
 
virtual G4bool IsOpenFileImpl () const final
 
- Protected Member Functions inherited from G4ToolsAnalysisManager
virtual G4bool PlotImpl () final
 
virtual G4bool MergeImpl (tools::histo::hmpi *hmpi) final
 
G4bool Reset ()
 
- Protected Member Functions inherited from G4VAnalysisManager
virtual G4bool OpenFileImpl (const G4String &fileName)=0
 
virtual G4bool WriteImpl ()=0
 
virtual G4bool CloseFileImpl (G4bool reset)=0
 
virtual G4bool PlotImpl ()=0
 
virtual G4bool MergeImpl (tools::histo::hmpi *hmpi)=0
 
virtual G4bool IsOpenFileImpl () const =0
 
void SetH1Manager (G4VH1Manager *h1Manager)
 
void SetH2Manager (G4VH2Manager *h2Manager)
 
void SetH3Manager (G4VH3Manager *h3Manager)
 
void SetP1Manager (G4VP1Manager *p1Manager)
 
void SetP2Manager (G4VP2Manager *p2Manager)
 
void SetNtupleManager (std::shared_ptr< G4VNtupleManager > ntupleManager)
 
void SetFileManager (std::shared_ptr< G4VFileManager > fileManager)
 
void SetPlotManager (std::shared_ptr< G4PlotManager > plotManager)
 
G4bool WriteAscii (const G4String &fileName)
 

Additional Inherited Members

- Protected Attributes inherited from G4ToolsAnalysisManager
G4H1ToolsManagerfH1Manager
 
G4H2ToolsManagerfH2Manager
 
G4H3ToolsManagerfH3Manager
 
G4P1ToolsManagerfP1Manager
 
G4P2ToolsManagerfP2Manager
 
- Protected Attributes inherited from G4VAnalysisManager
G4AnalysisManagerState fState
 
std::shared_ptr< G4VFileManagerfVFileManager
 
std::shared_ptr< G4PlotManagerfPlotManager
 
std::shared_ptr< G4NtupleBookingManagerfNtupleBookingManager
 
std::shared_ptr< G4VNtupleManagerfVNtupleManager
 
- Static Protected Attributes inherited from G4ToolsAnalysisManager
static G4ThreadLocal G4ToolsAnalysisManagerfgToolsInstance = nullptr
 
- Static Protected Attributes inherited from G4VAnalysisManager
static constexpr unsigned int fgkDefaultBasketSize = 32000
 
static constexpr unsigned int fgkDefaultBasketEntries = 4000
 

Detailed Description

Definition at line 45 of file G4CsvAnalysisManager.hh.

Constructor & Destructor Documentation

◆ G4CsvAnalysisManager()

G4CsvAnalysisManager::G4CsvAnalysisManager ( G4bool  isMaster = true)
explicit

Definition at line 76 of file G4CsvAnalysisManager.cc.

77 : G4ToolsAnalysisManager("Csv", isMaster),
78 fFileManager(nullptr),
79 fNtupleFileManager(nullptr)
80{
81 if ( ( isMaster && fgMasterInstance ) || ( fgInstance ) ) {
82 G4ExceptionDescription description;
83 description << " "
84 << "G4CsvAnalysisManager already exists."
85 << "Cannot create another instance.";
86 G4Exception("G4CsvAnalysisManager::G4CsvAnalysisManager()",
87 "Analysis_F001", FatalException, description);
88 }
89
90 if ( isMaster ) fgMasterInstance = this;
91 fgInstance = this;
92
93 // File Manager
94 fFileManager = std::make_shared<G4CsvFileManager>(fState);
95 SetFileManager(fFileManager);
96
97 // Ntuple file manager
98 fNtupleFileManager = std::make_shared<G4CsvNtupleFileManager>(fState);
99 fNtupleFileManager->SetFileManager(fFileManager);
100 fNtupleFileManager->SetBookingManager(fNtupleBookingManager);
101}
@ FatalException
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
Definition: G4Exception.cc:35
std::ostringstream G4ExceptionDescription
Definition: G4Exception.hh:40
std::shared_ptr< G4NtupleBookingManager > fNtupleBookingManager
G4AnalysisManagerState fState
void SetFileManager(std::shared_ptr< G4VFileManager > fileManager)

◆ ~G4CsvAnalysisManager()

G4CsvAnalysisManager::~G4CsvAnalysisManager ( )

Definition at line 104 of file G4CsvAnalysisManager.cc.

105{
106 if ( fState.GetIsMaster() ) fgMasterInstance = nullptr;
107 fgInstance = nullptr;
108}

Member Function Documentation

◆ BeginConstNtuple()

std::vector< tools::wcsv::ntuple * >::const_iterator G4CsvAnalysisManager::BeginConstNtuple ( ) const

◆ BeginNtuple()

std::vector< tools::wcsv::ntuple * >::iterator G4CsvAnalysisManager::BeginNtuple ( )

◆ CloseFileImpl()

G4bool G4CsvAnalysisManager::CloseFileImpl ( G4bool  reset)
finalprotectedvirtual

Implements G4VAnalysisManager.

Definition at line 336 of file G4CsvAnalysisManager.cc.

337{
338 auto finalResult = true;
339
340 // close open files
341 auto result = fFileManager->CloseFiles();
342 finalResult = finalResult && result;
343
344 // Histogram and profile files are created/closed indivudually for each
345 // object in WriteHn{Pn] function
346
347 result = fNtupleFileManager->ActionAtCloseFile(reset);
348 finalResult = finalResult && result;
349
350 // Reset data
351 if ( reset ) {
352 result = Reset();
353 if ( ! result ) {
354 G4ExceptionDescription description;
355 description << " " << "Resetting data failed";
356 G4Exception("G4CsvAnalysisManager::CloseFile()",
357 "Analysis_W021", JustWarning, description);
358 }
359 }
360 finalResult = finalResult && result;
361
362 return finalResult;
363}
@ JustWarning

◆ EndConstNtuple()

std::vector< tools::wcsv::ntuple * >::const_iterator G4CsvAnalysisManager::EndConstNtuple ( ) const

◆ EndNtuple()

std::vector< tools::wcsv::ntuple * >::iterator G4CsvAnalysisManager::EndNtuple ( )

◆ GetNtuple() [1/2]

tools::wcsv::ntuple * G4CsvAnalysisManager::GetNtuple ( ) const

◆ GetNtuple() [2/2]

tools::wcsv::ntuple * G4CsvAnalysisManager::GetNtuple ( G4int  ntupleId) const

◆ Instance()

G4CsvAnalysisManager * G4CsvAnalysisManager::Instance ( )
static

Definition at line 59 of file G4CsvAnalysisManager.cc.

60{
61 if ( fgInstance == nullptr ) {
63 fgInstance = new G4CsvAnalysisManager(isMaster);
64 }
65
66 return fgInstance;
67}
bool G4bool
Definition: G4Types.hh:86
G4bool IsWorkerThread()
Definition: G4Threading.cc:123

Referenced by G4Analysis::ManagerInstance().

◆ IsInstance()

G4bool G4CsvAnalysisManager::IsInstance ( )
static

Definition at line 70 of file G4CsvAnalysisManager.cc.

71{
72 return ( fgInstance != 0 );
73}

◆ IsOpenFileImpl()

virtual G4bool G4CsvAnalysisManager::IsOpenFileImpl ( ) const
finalprotectedvirtual

Implements G4VAnalysisManager.

◆ OpenFileImpl()

G4bool G4CsvAnalysisManager::OpenFileImpl ( const G4String fileName)
finalprotectedvirtual

Implements G4VAnalysisManager.

Definition at line 251 of file G4CsvAnalysisManager.cc.

252{
253 // Create ntuple manager(s)
254 // and set it to base class which takes then their ownership
255 SetNtupleManager(fNtupleFileManager->CreateNtupleManager());
256
257 auto finalResult = true;
258
259 // Save file name in file manager
260 auto result = fFileManager->OpenFile(fileName);
261 finalResult = finalResult && result;
262
263 // Open ntuple files and create ntuples from bookings
264 result = fNtupleFileManager->ActionAtOpenFile(fFileManager->GetFullFileName());
265 finalResult = finalResult && result;
266
267 return finalResult;
268}
void SetNtupleManager(std::shared_ptr< G4VNtupleManager > ntupleManager)

◆ SetIsCommentedHeader()

void G4CsvAnalysisManager::SetIsCommentedHeader ( G4bool  isCommentedHeader)

◆ SetIsHippoHeader()

void G4CsvAnalysisManager::SetIsHippoHeader ( G4bool  isHippoHeader)

◆ WriteImpl()

G4bool G4CsvAnalysisManager::WriteImpl ( )
finalprotectedvirtual

Implements G4VAnalysisManager.

Definition at line 271 of file G4CsvAnalysisManager.cc.

272{
273 // nothing to be done for Csv file
274 auto finalResult = true;
275
276#ifdef G4VERBOSE
277 if ( fState.GetVerboseL4() ) {
278 fState.GetVerboseL4()->Message("write", "files", "");
279 }
280#endif
281
282
283 if ( ! fgMasterInstance &&
284 ( ( ! fH1Manager->IsEmpty() ) || ( ! fH2Manager->IsEmpty() ) ||
285 ( ! fH3Manager->IsEmpty() ) || ( ! fP1Manager->IsEmpty() ) ||
286 ( ! fP2Manager->IsEmpty() ) ) ) {
287
288 G4ExceptionDescription description;
289 description
290 << " " << "No master G4CsvAnalysisManager instance exists."
291 << G4endl
292 << " " << "Histogram data will not be merged.";
293 G4Exception("G4CsvAnalysisManager::Write()",
294 "Analysis_W031", JustWarning, description);
295 }
296
297 // H1
298 auto result = WriteH1();
299 finalResult = finalResult && result;
300
301 // H2
302 result = WriteH2();
303 finalResult = finalResult && result;
304
305 // H3
306 result = WriteH3();
307 finalResult = finalResult && result;
308
309 // P1
310 result = WriteP1();
311 finalResult = finalResult && result;
312
313 // P2
314 result = WriteP2();
315 finalResult = finalResult && result;
316
317 // Ntuples
318 // Nothing to be done
319
320 // Write ASCII if activated
321 // Not available
322 //if ( IsAscii() ) {
323 // result = WriteAscii();
324 //}
325
326#ifdef G4VERBOSE
327 if ( fState.GetVerboseL2() ) {
328 fState.GetVerboseL2()->Message("write", "files", "", finalResult);
329 }
330#endif
331
332 return result;
333}
#define G4endl
Definition: G4ios.hh:57
const G4AnalysisVerbose * GetVerboseL2() const
const G4AnalysisVerbose * GetVerboseL4() const
void Message(const G4String &action, const G4String &object, const G4String &objectName, G4bool success=true) const
G4bool IsEmpty() const

The documentation for this class was generated from the following files: