HSUExeMacro
class description - source file - inheritance tree (.pdf)
private:
HSUBranchElement* findAciveBranch(const char* pBranchName)
TClonesArray* getNewArrayFromBranch(const char* pBranchName)
HCategory* getNewHCategoryFromBranch(const char* pBranchName)
Bool_t notifyBranches()
public:
HSUExeMacro()
HSUExeMacro(const HSUExeMacro&)
virtual ~HSUExeMacro()
Bool_t addFilesFromList(const char* pStr)
Bool_t addInputFile(const char* pStr)
Bool_t checkBranches()
static TClass* Class()
void clear()
void deleteProgress()
TBranch* getBranch(const char* pBranchName)
void getBranchesEntry(Int_t iEntry)
Int_t getEvent(Int_t iEvent)
Int_t getEvent() const
Int_t getEvents() const
Bool_t getExitOnError() const
HCategory* getHCategory(const char* pCategoryName)
Float_t getMdcPhi(Int_t iSector, Float_t fPhiMdc) const
Float_t getMdcTheta(Float_t fThetaMdc) const
Bool_t getNotFileChange()
Bool_t getOptBool() const
Float_t getOptFloat() const
Int_t getOptInt() const
const TString& getOptString() const
const TString& getParamFileName() const
TObject* getParamObject(const char* pName)
HSUProgress* getProgress() const
TClonesArray* getTClonesArray(const char* pBranchName)
virtual TClass* IsA() const
Bool_t isParamFileOpened() const
virtual Int_t loadArgs(int iArg, char** vArg)
Int_t loadTree(Int_t iEvent)
Int_t nextEvent()
Bool_t openInput()
Bool_t openOutput()
Bool_t openParamFile(const char* pParamFileName = "0")
HSUExeMacro& operator=(const HSUExeMacro&)
virtual void printInfo(const char* pProgramName) const
void setExitOnError(Bool_t b = kTRUE)
void setNotFileChange(Bool_t b)
void setProgress(HSUProgress* pProgress)
void setProgress(Bool_t bSet = kTRUE)
virtual void ShowMembers(TMemberInspector& insp, char* parent)
virtual void Streamer(TBuffer& b)
void StreamerNVirtual(TBuffer& b)
Bool_t writeOutput()
protected:
TChain* m_pChain chain of input files
Int_t m_iCurrentFile current file in the chain
HSUProgress* m_pProgress progress bar
TFile* m_pOutputFile output file
TObjArray* m_pActiveBranches array with active branches
Bool_t m_bExitOnError if exit on any error
TString m_sOutputName name of the output file
TObjArray* m_pInputArray list of input files
Int_t m_iEvents max number of events
Int_t m_iEvent current event
TString m_sParamFileName name of a file with parameters
TFile* m_pParamFile file with parameters
TString m_sOptString string from parameters
Int_t m_iOptInt int from parameters
Float_t m_fOptFloat float from parameters
Bool_t m_bOptBool boolean from parameters
Bool_t m_bNotFileChange notify when the file changes
HSUExeMacro(void)
A constructor of the class
~HSUExeMacro()
Destructor.
Close all input and output files opened by the class and delete what was used
void setProgress(HSUProgress *pProgress)
Set a progress bar used by the class during the events loop
void setProgress(Bool_t bSet)
Set a default progress bar used by the class during the events loop.
If bSet == kFALSE - removes the progress bar
HSUProgress* getProgress(void) const
Return the progress bar used by the class
void deleteProgress(void)
Delete the progress bar used by the class
Int_t loadArgs(int iArg, char* vArg[])
Load all arguments from the program arguments given as the parameters.
All parameters supported by the class are listed in the class description.
void printInfo(const char *pProgramName) const
Print info about all standard options. Used when `-h' is in the arguments.
Bool_t openInput(void)
Create the chain from all files given as the arguments of the program
Bool_t addInputFile(const char* pStr)
Add a root file to the chain
Bool_t addFilesFromList(const char *pStr)
Add all root files listed in a text file given as the argument.
All empty lines or lines starting with `#' are skipped.
File names are trimmed before use
(all start and tail white characters are removed)
Bool_t openOutput(void)
Open the output file
Bool_t writeOutput(void)
Simple close the output file. All root objects created since the openOutput
are written to the file
TClonesArray* getTClonesArray(const char *pBranchName)
Get the TClonesArray from the file.
To get a proper branch a `.fData' suffix is added to `pBranchName'
HCategory* getHCategory(const char *pCategoryName)
Get the HCategory from the file.
To get a proper branch a `.' suffix is added to `pCategoryName'
TBranch* getBranch(const char *pBranchName)
Get the brach from the `T'
if was activated by getHCategory or getTClonesArray
TClonesArray* getNewArrayFromBranch(const char *pBranchName)
Create new branch and a TClonesArray for it
HCategory* getNewHCategoryFromBranch(const char *pBranchName)
Create new branch and a HCategory for it
HSUBranchElement* findAciveBranch(const char *pBranchName)
Find an active branch by name
Int_t loadTree(Int_t iEvent)
Load the event from tree.
All active categories and array are filled with the new data.
If switch of the files is needed then new branches are created automatically.
Bool_t notifyBranches(void)
Get branches from a new file in the chain.
Called by loadTree if needed
void clear(void)
Clear all arrays and categories before next event
void getBranchesEntry(Int_t iEntry)
Fill the array or category with the data of the current event
Int_t getEvent(Int_t iEvent)
Get all data for the event.
If no events left return value < 0
Bool_t checkBranches(void)
Check if all activated branches exist in the every file in the chain
Int_t nextEvent(void)
Get next event
Return >= 0 if ok, or < 0 when at the end of the events list
Bool_t openParamFile(const char *pParamFileName)
Open a file with parameters. The parameters from the file may be get by:
HSUExeMacro::getParamObject method
TObject* getParamObject(const char *pName)
Get an object from the parameter file (if opened)
const TString& getParamFileName(void) const
Return param file name or empty string if the name not set
Float_t getMdcPhi(Int_t iSector, Float_t fPhiMdc) const
Convert MDC's phi angle to the coordinate system used in other detectors
Float_t getMdcTheta(Float_t fThetaMdc) const
Convert MDC's theta angle to the coordinate system used in other detectors
Inline Functions
Bool_t getExitOnError() const
void setExitOnError(Bool_t b = kTRUE)
Bool_t isParamFileOpened() const
const TString& getOptString() const
Int_t getOptInt() const
Float_t getOptFloat() const
Bool_t getOptBool() const
Int_t getEvents() const
Int_t getEvent() const
Bool_t getNotFileChange()
void setNotFileChange(Bool_t b)
TClass* Class()
TClass* IsA() const
void ShowMembers(TMemberInspector& insp, char* parent)
void Streamer(TBuffer& b)
void StreamerNVirtual(TBuffer& b)
HSUExeMacro HSUExeMacro(const HSUExeMacro&)
HSUExeMacro& operator=(const HSUExeMacro&)
Last update: Fri Jan 26 12:32:09 2007
ROOT page - Class index - Class Hierarchy - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.