ROOT logo
/////////////////////////////////////////////////////////////////
// Author: Henrik Tydesjo                                      //
// This class is used as a container online.                   //
// It holds information needed for a scan.                     //
// This class should only be used through the interface of the //
// AliITSOnlineSPDphys class.                                  //
/////////////////////////////////////////////////////////////////

#include "AliITSOnlineSPDphysInfo.h"

ClassImp(AliITSOnlineSPDphysInfo)

AliITSOnlineSPDphysInfo::AliITSOnlineSPDphysInfo(): 
  fNrRuns(0),
  fRunNrs(0),
  fEqNr(999),
  fNrEvents(0)
{}

AliITSOnlineSPDphysInfo::~AliITSOnlineSPDphysInfo() {}

void AliITSOnlineSPDphysInfo::ClearThis() {
  // reset all values for this object
  fNrRuns=0;
  fRunNrs=0;
  fEqNr=999;
  fNrEvents=0;
}

void AliITSOnlineSPDphysInfo::AddRunNr(UInt_t val) {
  // add a new run nr, allocate space for TArrayI
  fNrRuns++;
  fRunNrs.Set(fNrRuns);
  fRunNrs.AddAt(val, fNrRuns-1);
}

UInt_t AliITSOnlineSPDphysInfo::GetRunNr(UInt_t posi) const {
  // get run nr
  if (posi<fNrRuns) {
    return fRunNrs.At(posi);
  }
  else {
    return 0;
  }
}

void AliITSOnlineSPDphysInfo::AddNrEvents(Int_t val) {
  // add val nr of events (val could be negative)
  if (fNrEvents+val>0) {
    fNrEvents+=val;
  }
  else {
    fNrEvents=0;
  }
}
 AliITSOnlineSPDphysInfo.cxx:1
 AliITSOnlineSPDphysInfo.cxx:2
 AliITSOnlineSPDphysInfo.cxx:3
 AliITSOnlineSPDphysInfo.cxx:4
 AliITSOnlineSPDphysInfo.cxx:5
 AliITSOnlineSPDphysInfo.cxx:6
 AliITSOnlineSPDphysInfo.cxx:7
 AliITSOnlineSPDphysInfo.cxx:8
 AliITSOnlineSPDphysInfo.cxx:9
 AliITSOnlineSPDphysInfo.cxx:10
 AliITSOnlineSPDphysInfo.cxx:11
 AliITSOnlineSPDphysInfo.cxx:12
 AliITSOnlineSPDphysInfo.cxx:13
 AliITSOnlineSPDphysInfo.cxx:14
 AliITSOnlineSPDphysInfo.cxx:15
 AliITSOnlineSPDphysInfo.cxx:16
 AliITSOnlineSPDphysInfo.cxx:17
 AliITSOnlineSPDphysInfo.cxx:18
 AliITSOnlineSPDphysInfo.cxx:19
 AliITSOnlineSPDphysInfo.cxx:20
 AliITSOnlineSPDphysInfo.cxx:21
 AliITSOnlineSPDphysInfo.cxx:22
 AliITSOnlineSPDphysInfo.cxx:23
 AliITSOnlineSPDphysInfo.cxx:24
 AliITSOnlineSPDphysInfo.cxx:25
 AliITSOnlineSPDphysInfo.cxx:26
 AliITSOnlineSPDphysInfo.cxx:27
 AliITSOnlineSPDphysInfo.cxx:28
 AliITSOnlineSPDphysInfo.cxx:29
 AliITSOnlineSPDphysInfo.cxx:30
 AliITSOnlineSPDphysInfo.cxx:31
 AliITSOnlineSPDphysInfo.cxx:32
 AliITSOnlineSPDphysInfo.cxx:33
 AliITSOnlineSPDphysInfo.cxx:34
 AliITSOnlineSPDphysInfo.cxx:35
 AliITSOnlineSPDphysInfo.cxx:36
 AliITSOnlineSPDphysInfo.cxx:37
 AliITSOnlineSPDphysInfo.cxx:38
 AliITSOnlineSPDphysInfo.cxx:39
 AliITSOnlineSPDphysInfo.cxx:40
 AliITSOnlineSPDphysInfo.cxx:41
 AliITSOnlineSPDphysInfo.cxx:42
 AliITSOnlineSPDphysInfo.cxx:43
 AliITSOnlineSPDphysInfo.cxx:44
 AliITSOnlineSPDphysInfo.cxx:45
 AliITSOnlineSPDphysInfo.cxx:46
 AliITSOnlineSPDphysInfo.cxx:47
 AliITSOnlineSPDphysInfo.cxx:48
 AliITSOnlineSPDphysInfo.cxx:49
 AliITSOnlineSPDphysInfo.cxx:50
 AliITSOnlineSPDphysInfo.cxx:51
 AliITSOnlineSPDphysInfo.cxx:52
 AliITSOnlineSPDphysInfo.cxx:53
 AliITSOnlineSPDphysInfo.cxx:54
 AliITSOnlineSPDphysInfo.cxx:55