StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StBTofPidTraits.cxx
1 /***************************************************************************
2  *
3  * $Id: StBTofPidTraits.cxx,v 2.2 2009/12/08 23:24:46 fine Exp $
4  *
5  * Author: Xin Dong, Nov 2008
6  ***************************************************************************
7  *
8  * Description:
9  *
10  ***************************************************************************
11  *
12  * $Log: StBTofPidTraits.cxx,v $
13  * Revision 2.2 2009/12/08 23:24:46 fine
14  * Fix issue #1748 http://www.star.bnl.gov/rt2/Ticket/Display.html?id=1748
15  *
16  * Revision 2.1 2008/12/22 20:30:59 ullrich
17  * Initial Revision.
18  *
19  *
20  ***************************************************************************/
21 #include "StBTofPidTraits.h"
22 
23 static const char rcsid[] = "$Id: StBTofPidTraits.cxx,v 2.2 2009/12/08 23:24:46 fine Exp $";
24 
25 ClassImp(StBTofPidTraits)
26 
28 {
29  mBTofHit = 0;
30 
31  mMatchFlag = 0;
32  mYLocal = -999.;
33  mZLocal = -999.;
34  mThetaLocal = -999.;
35  mTimeOfFlight = -999.;
36  mPathLength = -999.;
37  mBeta = -999.;
38 
39  mSigmaElectron = -999.;
40  mSigmaPion = -999.;
41  mSigmaKaon = -999.;
42  mSigmaProton = -999.;
43  mProbElectron = -999.;
44  mProbPion = -999.;
45  mProbKaon = -999.;
46  mProbProton = -999.;
47 }
48 
49 StBTofPidTraits::~StBTofPidTraits() { /* noop */ }
50 
51 StBTofHit*
52 StBTofPidTraits::tofHit() { return mBTofHit; }
53 
54 const StBTofHit*
55 StBTofPidTraits::tofHit() const { return mBTofHit; }
56 
58 StBTofPidTraits::position() { return mPosition; }
59 
60 const StThreeVectorF&
61 StBTofPidTraits::position() const { return mPosition; }
62 
63 float
65 {
66  if(mBTofHit) return mBTofHit->tot();
67  else return -999.;
68 }
69 
70 void
71 StBTofPidTraits::setTofHit(StBTofHit* hit) { mBTofHit = hit; }
72 
73 void
74 StBTofPidTraits::setPosition(const StThreeVectorF& pos) { mPosition = pos; }
float tot() const
timing for PID