adapted macro to QAManager
[u/mrichter/AliRoot.git] / STEER / AliESDHeader.cxx
CommitLineData
d5ebf00e 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// Implementation of Class AliESDHeader
18// Header data
19// for the ESD
20// Origin: Christian Klein-Boesing, CERN, Christian.Klein-Boesing@cern.ch
21//-------------------------------------------------------------------------
22
23#include "AliESDHeader.h"
24
25
26ClassImp(AliESDHeader)
27
28//______________________________________________________________________________
29AliESDHeader::AliESDHeader() :
9ae2e5e6 30 AliVHeader(),
d5ebf00e 31 fTriggerMask(0),
32 fOrbitNumber(0),
33 fTimeStamp(0),
34 fEventType(0),
4f036e6e 35 fPeriodNumber(0),
d5ebf00e 36 fEventNumberInFile(0),
37 fBunchCrossNumber(0),
53eef471 38 fTriggerCluster(0),
39 fL0TriggerInputs(0),
40 fL1TriggerInputs(0),
41 fL2TriggerInputs(0)
42// fTriggerScalers(0x0)
d5ebf00e 43{
9ae2e5e6 44 // default constructor
45
46 SetName("AliESDHeader");
47}
48
49
50AliESDHeader::~AliESDHeader()
51{
52 // destructor
d5ebf00e 53}
54
55
56AliESDHeader::AliESDHeader(const AliESDHeader &header) :
9ae2e5e6 57 AliVHeader(header),
d5ebf00e 58 fTriggerMask(header.fTriggerMask),
59 fOrbitNumber(header.fOrbitNumber),
60 fTimeStamp(header.fTimeStamp),
61 fEventType(header.fEventType),
4f036e6e 62 fPeriodNumber(header.fPeriodNumber),
d5ebf00e 63 fEventNumberInFile(header.fEventNumberInFile),
64 fBunchCrossNumber(header.fBunchCrossNumber),
53eef471 65 fTriggerCluster(header.fTriggerCluster),
66 fL0TriggerInputs(header.fL0TriggerInputs),
67 fL1TriggerInputs(header.fL1TriggerInputs),
68 fL2TriggerInputs(header.fL2TriggerInputs)
69// fTriggerScalers(header.fTriggerScalers),
d5ebf00e 70{
71 // copy constructor
9ae2e5e6 72
73 SetName(header.fName);
74 SetTitle(header.fTitle);
d5ebf00e 75}
76
77AliESDHeader& AliESDHeader::operator=(const AliESDHeader &header)
78{
79 // assigment operator
80 if(this!=&header) {
9ae2e5e6 81 AliVHeader::operator=(header);
d5ebf00e 82 fTriggerMask = header.fTriggerMask;
83 fOrbitNumber = header.fOrbitNumber;
84 fTimeStamp = header.fTimeStamp;
85 fEventType = header.fEventType;
4f036e6e 86 fPeriodNumber = header.fPeriodNumber;
d5ebf00e 87 fEventNumberInFile = header.fEventNumberInFile;
88 fBunchCrossNumber = header.fBunchCrossNumber;
89 fTriggerCluster = header.fTriggerCluster;
53eef471 90 fL0TriggerInputs = header.fL0TriggerInputs;
91 fL1TriggerInputs = header.fL1TriggerInputs;
92 fL2TriggerInputs = header.fL2TriggerInputs;
93// fTriggerScalers = header.fTriggerScalers;
4f036e6e 94 SetName(header.fName);
95 SetTitle(header.fTitle);
96
d5ebf00e 97 }
98 return *this;
99}
100
732a24fe 101void AliESDHeader::Copy(TObject &obj) const {
102
103 // this overwrites the virtual TOBject::Copy()
104 // to allow run time copying without casting
105 // in AliESDEvent
106
107 if(this==&obj)return;
108 AliESDHeader *robj = dynamic_cast<AliESDHeader*>(&obj);
109 if(!robj)return; // not an AliESDHeader
110 *robj = *this;
111
112}
113
d5ebf00e 114
115
116//______________________________________________________________________________
117void AliESDHeader::Reset()
118{
119 // reset all data members
120 fTriggerMask = 0;
121 fOrbitNumber = 0;
122 fTimeStamp = 0;
123 fEventType = 0;
4f036e6e 124 fPeriodNumber = 0;
d5ebf00e 125 fEventNumberInFile = 0;
126 fBunchCrossNumber = 0;
127 fTriggerCluster = 0;
53eef471 128 fL0TriggerInputs = 0;
129 fL1TriggerInputs = 0;
130 fL2TriggerInputs = 0;
131// fTriggerScalers = 0;
d5ebf00e 132}
133
134//______________________________________________________________________________
135void AliESDHeader::Print(const Option_t *) const
136{
137 // Print some data members
138 printf("Event # %d in file Bunch crossing # %d Orbit # %d Trigger %lld \n",
139 GetEventNumberInFile(),
140 GetBunchCrossNumber(),
141 GetOrbitNumber(),
142 GetTriggerMask());
143}
144