--- PamCut/CaloCuts/CaloNotIntCut/CaloNotIntCut.h 2009/05/27 13:30:09 1.1.1.1 +++ PamCut/CaloCuts/CaloNotIntCut/CaloNotIntCut.h 2010/07/08 14:00:29 1.4 @@ -11,15 +11,17 @@ #define CALONOTINTCUT_H_ #include "../../PamCutBase/PamCutBase.h" -#include "../../CaloAxis2.h" +#ifndef NO_CALOAXIS +#include +#endif /* NO_CALOAXIS */ /*! @brief The non-interacting track cut. * This check discards all the events who interacts in the calorimeter. It is possible to choose the track to use for - * the check. To improve computation speed, Check does NOT computes the track for the event; the track information + * the check. To improve computation speed, Check does NOT compute the track for the event; the track information * is supposed to lie in some external object, whose address has to be passed to the constructor. The user is then * demanded to fill this external object with the proper track information for the current event before calling Check * or ApplyCut. - * Currently, only the check with the calorimeter track is implemented. + * Currently, the checks with the calorimeter L2 track and with CaloAxis track are implemented. * * CUT DEPENDENCIES: CaloTrackCut for the existence of the track (it can also provide the CaloAxis objects). */ @@ -27,22 +29,24 @@ class CaloNotIntCut: public PamCut { public: - /*! @brief Constructor for tracker track. - * Use this constructor if you want to use the tracker track to perform the + /*! @brief Constructor for calorimeter L2 track. + * Use this constructor if you want to use the L2 calorimeter track to perform the * non-interaction check. * - * NOTE: Check() for this constructor is not implemented yet. - * * @param cutName The name of the cut. - * @param trkTrack Pointer to the tracker track object. - * * @param qRatioMin The minimum threshold for the ratio between track charge and total charge in CALO. + * @param pamTrack Pointer to the Pamela track object. + * @param qRatioMin The minimum threshold for the ratio between track charge and total charge in CALO. */ - CaloNotIntCut(const char *cutName, TrkTrack *trkTrack, float qRatioMin=0.8) : - PamCut(cutName), _trkTrack(trkTrack), _xCaloAxis(NULL), _yCaloAxis(NULL), _qRatioMin(qRatioMin) { + + CaloNotIntCut(const char *cutName, PamTrack **pamTrack, float qRatioMin = 0.8) : + PamCut(cutName), _pamTrack(pamTrack), _qRatioMin(qRatioMin) { +#ifndef NO_CALOAXIS + _xCaloAxis = _yCaloAxis = NULL; +#endif /* NO_CALOAXIS */ } /*! @brief Constructor for calorimeter track. - * Use this constructor if you want to use the calorimeter track to perform the + * Use this constructor if you want to use the CaloAxis track to perform the * non-interaction check. * * @param cutName The name of the cut. @@ -51,10 +55,11 @@ * @param qRatioMin The minimum threshold for the ratio between track charge and total charge in CALO. * @return */ - CaloNotIntCut(const char *cutName, CaloAxis *xCaloAxis, CaloAxis *yCaloAxis, float qRatioMin=0.8) : - PamCut(cutName), _trkTrack(NULL), _xCaloAxis(xCaloAxis), _yCaloAxis(yCaloAxis), _qRatioMin(qRatioMin) { +#ifndef NO_CALOAXIS + CaloNotIntCut(const char *cutName, CaloAxis *xCaloAxis, CaloAxis *yCaloAxis, float qRatioMin = 0.8) : + PamCut(cutName), _pamTrack(NULL), _xCaloAxis(xCaloAxis), _yCaloAxis(yCaloAxis), _qRatioMin(qRatioMin) { } - +#endif /* NO_CALOAXIS */ //TODO: aggiungere il costruttore per il TOF. /*! @brief Destructor. */ @@ -72,8 +77,10 @@ private: - TrkTrack *_trkTrack; + PamTrack **_pamTrack; +#ifndef NO_CALOAXIS CaloAxis *_xCaloAxis, *_yCaloAxis; +#endif /* NO_CALOAXIS */ float _qRatioMin; };