StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StSsdLadderHitCollection.cxx
1 /***************************************************************************
2  *
3  * $Id: StSsdLadderHitCollection.cxx,v 2.2 2001/04/05 04:00:55 ullrich Exp $
4  *
5  * Author: Lilian Martin, Thomas Ullrich, Dec 1999
6  ***************************************************************************
7  *
8  * Description:
9  *
10  ***************************************************************************
11  *
12  * $Log: StSsdLadderHitCollection.cxx,v $
13  * Revision 2.2 2001/04/05 04:00:55 ullrich
14  * Replaced all (U)Long_t by (U)Int_t and all redundant ROOT typedefs.
15  *
16  * Revision 2.1 2000/01/05 16:00:08 ullrich
17  * Initial Revision.
18  *
19  **************************************************************************/
20 #include "StSsdLadderHitCollection.h"
21 
22 static const char rcsid[] = "$Id: StSsdLadderHitCollection.cxx,v 2.2 2001/04/05 04:00:55 ullrich Exp $";
23 
25 
27 
28 StSsdLadderHitCollection::~StSsdLadderHitCollection() { /* noop */ }
29 
30 unsigned int
31 StSsdLadderHitCollection::numberOfWafers() const {return mMaxNumberOfWafers;}
32 
33 unsigned int
34 StSsdLadderHitCollection::numberOfHits() const
35 {
36  unsigned int sum = 0;
37  for (unsigned int j=0; j<numberOfWafers(); j++) {
38  sum += mWafers[j].hits().size();
39  }
40  return sum;
41 }
42 
44 StSsdLadderHitCollection::wafer(unsigned int i)
45 {
46  if (i < numberOfWafers())
47  return &(mWafers[i]);
48  else
49  return 0;
50 }
51 
53 StSsdLadderHitCollection::wafer(unsigned int i) const
54 {
55  if (i < numberOfWafers())
56  return &(mWafers[i]);
57  else
58  return 0;
59 }
60