~maus-scifi/maus/tracker_devel

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
/* This file is part of MAUS: http://micewww.pp.rl.ac.uk/projects/maus
 *
 * MAUS is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * MAUS is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with MAUS.  If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef _SRC_COMMON_CPP_DATASTRUCTURE_SCIFINOISEHIT_HH_
#define _SRC_COMMON_CPP_DATASTRUCTURE_SCIFINOISEHIT_HH_

#include <vector>
#include "src/common_cpp/Utils/VersionNumber.hh"

namespace MAUS {

/** Identifier for the channel where noise was recorded in the SciFi 
 */
class SciFiNoiseHit {
  public:
    /** Constructor - allocate to 0 */
    SciFiNoiseHit();

    /** Constructor - initialises member variables from arguments */
    SciFiNoiseHit(int spill, int event, int tracker, int station,
               int plane, int channel, double npe, double time );

    /** Copy Constructor - copies data from noise*/
    SciFiNoiseHit(const SciFiNoiseHit& noise);

    /** Equality operator - copies data from noise */
    SciFiNoiseHit& operator=(const SciFiNoiseHit& noise);

    /** Destructor (does nothing)*/
    virtual ~SciFiNoiseHit();

    /** Get the spill number */
    int GetSpill() const { return _spill; }
    /** Set the spill number */
    void SetSpill(int spill) { _spill = spill; }

    /** Get the event number */
    int GetEvent() const {return _event;}
    /** Set the event number */
    void SetEvent(int event) {_event = event;}

    /** Get the station number (3-plane view) */
    int GetStation() const {return _station;}
    /** Set the station number (3-plane view) */
    void SetStation(int station) {_station = station;}

    /** Get the tracker number i.e. upstream or downstream */
    int GetTracker() const {return _tracker;}
    /** Set the tracker number i.e. upstream or downstream */
    void SetTracker(int tracker) {_tracker = tracker;}

    /** Get the plane number */
    int GetPlane() const {return _plane;}
    /** Set the plane number */
    void SetPlane(int plane) {_plane = plane;}

    /** Get the channel number */
    int GetChannel() const {return _channel;}
    /** Set the channel number */
    void SetChannel(int channel) {_channel = channel;}

    /** Get NPE */
    double GetNPE() const {return _npe;}
    /** Set NPE */
    void SetNPE(double npe) {_npe = npe;}

    /** Get Time */
    double GetTime() const {return _time;}
    /** Set Time */
    void SetTime(double time) {_time = time;}

    /** Get Used */
    bool GetUsed() const {return _used;}
    /** Set Used */
    void SetUsed(bool used) {_used = used;}

    /** Get the Hit-Digit ID */
    double GetID() const {return _digit_id;}
    /** Set the Hit-Digit ID */
    void SetID(double digit_id) {_digit_id = digit_id;}

  private:
    int _spill, _event;
    int _tracker, _station, _plane, _channel;
    double  _npe, _time;
    bool _used;
    double _digit_id;

    MAUS_VERSIONED_CLASS_DEF(SciFiNoiseHit)
};

typedef std::vector<SciFiNoiseHit *> SciFiNoiseHitPArray;
}

#endif