updates on TOF software:
[u/mrichter/AliRoot.git] / TOF / AliTOFDRMSummaryData.cxx
CommitLineData
5b4ed716 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14***************************************************************************/
15
16/*
17 author: Roberto Preghenella (R+), preghenella@bo.infn.it
18*/
19
20
21//////////////////////////////////////////////////////////////////////
22// //
23// //
24// This class provides a summary for DRM data. //
25// //
26// //
27//////////////////////////////////////////////////////////////////////
28
29#include "AliTOFDRMSummaryData.h"
30
31ClassImp(AliTOFDRMSummaryData)
32
33AliTOFDRMSummaryData::AliTOFDRMSummaryData() :
34 TObject(),
35 fHeader(kFALSE),
36 fTrailer(kFALSE),
37 fSlotID(0),
38 fEventWords(0),
39 fDRMID(0),
40 fLocalEventCounter(0),
41 fPartecipatingSlotID(0),
42 fCBit(0),
43 fVersID(0),
44 fDRMhSize(0),
45 fSlotEnableMask(0),
46 fFaultID(0),
47 fRTOBit(0),
48 fL0BCID(0),
49 fRunTimeInfo(0),
50 fTemperature(0),
51 fACKBit(0),
52 fSensAD(0),
53 fEventCRC(0),
54 fDecoderCRC(0),
55 fDecoderSlotEnableMask(0),
56 fLTMSummaryData(0x0)
57{
58 /* default constructor */
59 fLTMSummaryData = new AliTOFLTMSummaryData();
60 for (Int_t iTRM = 0; iTRM < N_TRM; iTRM++)
61 fTRMSummaryData[iTRM] = new AliTOFTRMSummaryData();
62}
63
64//_________________________________________________________________
65
66AliTOFDRMSummaryData::AliTOFDRMSummaryData(const AliTOFDRMSummaryData &source) :
67 TObject(),
68 fHeader(source.fHeader),
69 fTrailer(source.fTrailer),
70 fSlotID(source.fSlotID),
71 fEventWords(source.fEventWords),
72 fDRMID(source.fDRMID),
73 fLocalEventCounter(source.fLocalEventCounter),
74 fPartecipatingSlotID(source.fPartecipatingSlotID),
75 fCBit(source.fCBit),
76 fVersID(source.fVersID),
77 fDRMhSize(source.fDRMhSize),
78 fSlotEnableMask(source.fSlotEnableMask),
79 fFaultID(source.fFaultID),
80 fRTOBit(source.fRTOBit),
81 fL0BCID(source.fL0BCID),
82 fRunTimeInfo(source.fRunTimeInfo),
83 fTemperature(source.fTemperature),
84 fACKBit(source.fACKBit),
85 fSensAD(source.fSensAD),
86 fEventCRC(source.fEventCRC),
87 fDecoderCRC(source.fDecoderCRC),
88 fDecoderSlotEnableMask(source.fDecoderSlotEnableMask),
89 fLTMSummaryData(0x0)
90{
91 /* copy constructor */
92 fLTMSummaryData = new AliTOFLTMSummaryData(*source.fLTMSummaryData);
93 for (Int_t iTRM = 0; iTRM < N_TRM; iTRM++)
94 fTRMSummaryData[iTRM] = new AliTOFTRMSummaryData(*source.fTRMSummaryData[iTRM]);
95}
96
97//_________________________________________________________________
98
99AliTOFDRMSummaryData &
100AliTOFDRMSummaryData::operator = (const AliTOFDRMSummaryData &source)
101{
102 /* operator = */
103 fHeader = source.fHeader;
104 fTrailer = source.fTrailer;
105 fSlotID = source.fSlotID;
106 fEventWords = source.fEventWords;
107 fDRMID = source.fDRMID;
108 fLocalEventCounter = source.fLocalEventCounter;
109 fPartecipatingSlotID = source.fPartecipatingSlotID;
110 fCBit = source.fCBit;
111 fVersID = source.fVersID;
112 fDRMhSize = source.fDRMhSize;
113 fSlotEnableMask = source.fSlotEnableMask;
114 fFaultID = source.fFaultID;
115 fRTOBit = source.fRTOBit;
116 fL0BCID = source.fL0BCID;
117 fRunTimeInfo = source.fRunTimeInfo;
118 fTemperature = source.fTemperature;
119 fACKBit = source.fACKBit;
120 fSensAD = source.fSensAD;
121 fEventCRC = source.fEventCRC;
122 fDecoderCRC = source.fDecoderCRC;
123 fDecoderSlotEnableMask = source.fDecoderSlotEnableMask;
124 *fLTMSummaryData = *source.fLTMSummaryData;
125 for (Int_t iTRM = 0; iTRM < N_TRM; iTRM++)
126 *fTRMSummaryData[iTRM] = *source.fTRMSummaryData[iTRM];
127 return *this;
128}
129
130//_________________________________________________________________
131
132AliTOFDRMSummaryData::~AliTOFDRMSummaryData()
133{
134 /* default destructor */
135 delete fLTMSummaryData;
136 for (Int_t iTRM = 0; iTRM < N_TRM; iTRM++)
137 delete fTRMSummaryData[iTRM];
138}
139
140//_________________________________________________________________
141
142void
143AliTOFDRMSummaryData::Reset()
144{
145 /* reset function */
146 fHeader = kFALSE;
147 fTrailer = kFALSE;
148 fSlotID = 0;
149 fEventWords = 0;
150 fDRMID = 0;
151 fLocalEventCounter = 0;
152 fPartecipatingSlotID = 0;
153 fCBit = 0;
154 fVersID = 0;
155 fDRMhSize = 0;
156 fSlotEnableMask = 0;
157 fFaultID = 0;
158 fRTOBit = 0;
159 fL0BCID = 0;
160 fRunTimeInfo = 0;
161 fTemperature = 0;
162 fACKBit = 0;
163 fSensAD = 0;
164 fEventCRC = 0;
165 fDecoderCRC = 0;
166 fDecoderSlotEnableMask = 0;
167 fLTMSummaryData->Reset();
168 for (Int_t iTRM = 0; iTRM < N_TRM; iTRM++)
169 fTRMSummaryData[iTRM]->Reset();
170}