BOSS
7.1.0
BESIII Offline Software System
Loading...
Searching...
No Matches
MdcHitMapGuts.h
Go to the documentation of this file.
1
//--------------------------------------------------------------------------
2
// File and Version Information:
3
// $Id: MdcHitMapGuts.h,v 1.2 2005/07/18 03:16:11 zhangy Exp $
4
//
5
// Description:
6
// Singleton implementation of MdcHitMap. Requesting an instance either
7
// creates one (first call) or clears the existing one (all subsequent calls).
8
//
9
// Environment:
10
// Software developed for the BaBar Detector at the SLAC B-Factory.
11
//
12
// Author(s): Steve Schaffner
13
//
14
//------------------------------------------------------------------------
15
16
#ifndef DCHHITMAPGUTS_HH
17
#define DCHHITMAPGUTS_HH
18
19
#include <vector>
20
class
MdcHit
;
21
class
MdcDetector
;
22
23
// Class interface //
24
class
MdcHitMapGuts
{
25
26
friend
class
MdcHitMap
;
// only one who can make one of these
27
28
public
:
29
virtual
~MdcHitMapGuts
();
30
31
MdcHit
*
hitWire
(
int
lay,
int
wire)
const
{
32
return
_hits[lay][wire];
33
}
34
35
void
addHit
(
MdcHit
& theHit) ;
36
37
void
removeHit
(
int
lay,
int
wire) {
38
// could switch to () notation to avoid overhead for bounds-checking
39
_hits[lay][wire] = 0;
40
}
41
42
void
clear
();
43
44
private
:
45
46
static
MdcHitMapGuts
* instance(
const
MdcDetector
&);
47
MdcHitMapGuts
(
const
MdcDetector
&);
// only used internally
48
49
typedef
std::vector<std::vector< MdcHit* > > MdcHitMap_t;
50
MdcHitMap_t _hits;
51
52
// Preempt
53
MdcHitMapGuts
& operator= (
const
MdcHitMapGuts
&);
54
MdcHitMapGuts
(
const
MdcHitMapGuts
&);
55
};
56
57
#endif
MdcDetector
Definition:
MdcDetector.h:20
MdcHitMapGuts
Definition:
MdcHitMapGuts.h:24
MdcHitMapGuts::hitWire
MdcHit * hitWire(int lay, int wire) const
Definition:
MdcHitMapGuts.h:31
MdcHitMapGuts::clear
void clear()
Definition:
MdcHitMapGuts.cxx:43
MdcHitMapGuts::addHit
void addHit(MdcHit &theHit)
Definition:
MdcHitMapGuts.cxx:51
MdcHitMapGuts::removeHit
void removeHit(int lay, int wire)
Definition:
MdcHitMapGuts.h:37
MdcHitMapGuts::~MdcHitMapGuts
virtual ~MdcHitMapGuts()
Definition:
MdcHitMapGuts.cxx:30
MdcHitMap
Definition:
MdcHitMap.h:28
MdcHit
Definition:
MdcHit.h:44
source
Reconstruction
MdcPatRec
MdcData
MdcData-00-01-27
MdcData
MdcHitMapGuts.h
Generated by
1.9.6