6 #ifndef StMuDstFilterMaker_hh
7 #define StMuDstFilterMaker_hh
12 #include "StMuDstMaker.h"
14 #include "StMuEvent.h"
15 #include "StMuTrack.h"
16 #ifndef __NO_STRANGE_MUDST__
40 virtual const char *GetCVS()
const {
41 static const char cvs[]=
"Tag $Name: $ $Id: StMuDstFilterMaker.h,v 1.11 2014/08/06 11:43:31 jeromel Exp $ built " __DATE__
" " __TIME__ ;
45 void setOutputDirName(
const char* name) { mOutDirName = string(name); }
46 void setOutputFileName(
const char* name) { mOutFileName = string(name); }
47 void setMuDstMaker(
StMuDstMaker* maker) { mMuDstMaker = maker; }
48 void setFilterGlobals(
int filterGlobals = 1) {
mFilterGlobals = filterGlobals; }
49 void setDoBemc(
int doBemc=1) {
mDoBemc = doBemc;}
50 void setDoEemc(
int doEemc=1) {
mDoEemc = doEemc;}
54 template<
class T>
bool filter(T* t) {
return false;}
79 void open(
const Char_t *);
81 int addType(TClonesArray* tcaTo , T t);
83 int addType(TClonesArray *tca, TClonesArray* tcaTo , T *t);
87 #ifndef __NO_STRANGE_MUDST__
88 TClonesArray* mStrangeArrays[__NSTRANGEARRAYS__];
90 TClonesArray* mEmcArrays[__NEMCARRAYS__];
Int_t mFilterGlobals
If set, keep also globals that fulfill cuts, while primary does not.
Int_t mDoBemc
Copy barrel data (if it passes cuts)
StThreeVectorF primaryVertexPosition(int vtx_id=-1) const
The StMuDst is supposed to be structured in 'physical events'. Therefore there is only 1 primary vert...
bool filter(StMuEvent *ev)
Now I specialize the filter function to select individual object.
int Make()
Filters the muDst and writes the filtered version.
StMuDstFilterMaker(const char *name="muDstFilter")
Default constructor; get pointer to StMuDstMaker.
TClonesArray * mArrays[__NARRAYS__]
the list of TClonesArrays to copy
int Finish()
Writes and closes the output file.
void open(const Char_t *)
bool filter(StMuDst *mu)
If this function returns false, the whole event is discarded.
static StMuEvent * event()
returns pointer to current StMuEvent (class holding the event wise information, e.g. event number, run number)
Int_t mDoEemc
Copy endcap data (if it passes cuts)
bool filter(T *t)
specialize this function to apply filters to the individual branches