2 #include "StjTowerEnergyListReader.h"
10 tree->SetBranchAddress(
"eventId" , &_eventId );
11 tree->SetBranchAddress(
"nTowers" , &_nTowers );
12 tree->SetBranchAddress(
"energy" , _energy );
13 tree->SetBranchAddress(
"towerId" , _towerId );
14 tree->SetBranchAddress(
"towerEta" , _towerEta );
15 tree->SetBranchAddress(
"towerPhi" , _towerPhi );
16 tree->SetBranchAddress(
"adc" , _adc );
17 tree->SetBranchAddress(
"pedestal" , _pedestal );
18 tree->SetBranchAddress(
"rms" , _rms );
19 tree->SetBranchAddress(
"towerR" , _towerR );
20 tree->SetBranchAddress(
"vertexX" , &_vertexX );
21 tree->SetBranchAddress(
"vertexY" , &_vertexY );
22 tree->SetBranchAddress(
"vertexZ" , &_vertexZ );
23 tree->SetBranchAddress(
"status" , _status );
24 tree->SetBranchAddress(
"detectorId" , &_detectorId );
25 tree->SetBranchAddress(
"runNumber" , &_runNumber );
28 void StjTowerEnergyListReader::clearEntry()
33 void StjTowerEnergyListReader::readEntry()
37 for(
int i = 0; i < _nTowers; ++i) {
41 energy.runNumber = _runNumber;
42 energy.eventId = _eventId;
43 energy.detectorId = _detectorId;
44 energy.towerId = _towerId[i];
45 energy.towerR = _towerR[i];
46 energy.towerEta = _towerEta[i];
47 energy.towerPhi = _towerPhi[i];
48 energy.vertexX = _vertexX;
49 energy.vertexY = _vertexY;
50 energy.vertexZ = _vertexZ;
51 energy.energy = _energy[i];
53 energy.pedestal = _pedestal[i];
55 energy.status = _status[i];
57 _list.push_back(energy);