StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StMuFgtStripAssociation.h
1 /***************************************************************************
2  *
3  * $Id: StMuFgtStripAssociation.h,v 1.1 2012/11/15 22:27:24 sangalin Exp $
4  * Author: S. Gliske, Jul 2012
5  *
6  ***************************************************************************
7  *
8  * Description: data used for keeping track of which strips are
9  * associated with which clusters, as well as the membership weight of
10  * each strip. The MuDst contains a TClonesArray of this class,
11  * ordered such that elements with the same clusIdx are contiguous.
12  * Each cluster then keeps track of the first position in this array
13  * associated with itself, as well as the number of elements in this
14  * array. Note: this class strictly inlined (no .cxx file).
15  *
16  ***************************************************************************
17  *
18  * $Log: StMuFgtStripAssociation.h,v $
19  * Revision 1.1 2012/11/15 22:27:24 sangalin
20  * Copied over from StFgtDevel.
21  *
22  * Revision 1.1 2012/07/20 16:11:24 sgliske
23  * Added StFgtStripAssociation, and removed all dynamically
24  * allocated memory from StMuFgt* containers.
25  * Also removed StMuFgtInfo
26  *
27  *
28  **************************************************************************/
29 
30 #ifndef _ST_MU_FGT_STRIP_ASSOCIATION_H_
31 #define _ST_MU_FGT_STRIP_ASSOCIATION_H_
32 
33 #include <TObject.h>
34 
35 class StFgtStrip;
36 
37 class StMuFgtStripAssociation : public TObject {
38  public:
39  // constructors
40  StMuFgtStripAssociation( Int_t clusIdx = -1, Int_t stripIdx = -1, Float_t weight = 0 );
41 
42  // defaults
43  // StMuFgtStripAssociation(const StMuFgtStripAssociation&); use default
44  // StMuFgtStripAssociation& operator=(const StMuFgtStripAssociation&); use default
45  // ~StMuFgtStripAssociation(); use default
46 
47  // accessors
48  Int_t getClusIdx() const;
49  Int_t getStripIdx() const;
50  Float_t getWeight() const;
51 
52  // modifiers
53  void setClusIdx ( Int_t clusIdx );
54  void setStripIdx ( Int_t stripIdx );
55  void setWeight ( Float_t weight );
56 
57  protected:
58  // data members
59  Int_t mClusIdx; // index of the cluster in the muFgtClusters TClonesArray
60  Int_t mStripIdx; // index of the strip in the muFgtStrips TClonesArray
61  Float_t mWeight; // membership weight of the strip in the given cluster.
62 
63  private:
64  ClassDef(StMuFgtStripAssociation,1);
65 };
66 
67 // inline functions
68 
69 // constructor
70 inline StMuFgtStripAssociation::StMuFgtStripAssociation( Int_t clusIdx, Int_t stripIdx, Float_t weight ) :
71  mClusIdx( clusIdx ), mStripIdx( stripIdx ), mWeight( weight ){ /* */ };
72 
73 // accessors
74 inline Int_t StMuFgtStripAssociation::getClusIdx() const { return mClusIdx; };
75 inline Int_t StMuFgtStripAssociation::getStripIdx() const { return mStripIdx; };
76 inline Float_t StMuFgtStripAssociation::getWeight() const { return mWeight; };
77 
78 // modifiers
79 inline void StMuFgtStripAssociation::setClusIdx ( Int_t clusIdx ){ mClusIdx = clusIdx; };
80 inline void StMuFgtStripAssociation::setStripIdx ( Int_t stripIdx ){ mStripIdx = stripIdx; };
81 inline void StMuFgtStripAssociation::setWeight ( Float_t Weight ){ mWeight = Weight; };
82 
83 #endif
84