00001
00002 #include "MessageService/MsgService.h"
00003 #include "JobControl/JobCModuleRegistry.h"
00004 #include "Algorithm/AlgHandle.h"
00005 #include "FarDetDataQuality.h"
00006 #include "FarDetDataQualityHandle.h"
00007
00008 ClassImp(FarDetDataQuality)
00009
00010 FarDetDataQuality::FarDetDataQuality() :
00011 fRun(-1), fSubRun(-1), fSnarl(-1),
00012 fDate(0), fTime(0), fTimeFrame(0), fMicrosec(0), fNanosec(0),
00013 fCrateMask(-1),
00014 fDeadPlnChips(0), fHotPlnChips(0), fColdPlnChips(0), fBusyPlnChips(0),
00015 fDeadShldChips(0), fHotShldChips(0), fColdShldChips(0), fBusyShldChips(0),
00016 fLiBox(-1), fLiLed(-1), fLiPulseHeight(0), fLiPulseWidth(0),
00017 fTpmtBox(-1), fTpmtNanosec(0),
00018 fSparsErrors(0), fEtcErrors(0),
00019 fSpillStatus(0), fSpillType(0), fSpillGpsError(-999),
00020 fLiChannels(0), fHitPlnChannels(0), fHitShldChannels(0)
00021 {
00022
00023 }
00024
00025 FarDetDataQuality::FarDetDataQuality(AlgHandle& ah) :
00026 CandBase(ah),
00027 fRun(-1), fSubRun(-1), fSnarl(-1),
00028 fDate(0), fTime(0), fTimeFrame(0), fMicrosec(0), fNanosec(0),
00029 fCrateMask(-1),
00030 fDeadPlnChips(0), fHotPlnChips(0), fColdPlnChips(0), fBusyPlnChips(0),
00031 fDeadShldChips(0), fHotShldChips(0), fColdShldChips(0), fBusyShldChips(0),
00032 fLiBox(-1), fLiLed(-1), fLiPulseHeight(0), fLiPulseWidth(0),
00033 fTpmtBox(-1), fTpmtNanosec(0),
00034 fSparsErrors(0), fEtcErrors(0),
00035 fSpillStatus(0), fSpillType(0), fSpillGpsError(-999),
00036 fLiChannels(0), fHitPlnChannels(0), fHitShldChannels(0)
00037 {
00038
00039 }
00040
00041 FarDetDataQuality::FarDetDataQuality(AlgHandle& ah, CandHandle& ch, CandContext& cx) :
00042 CandBase(ah),
00043 fRun(-1), fSubRun(-1), fSnarl(-1),
00044 fDate(0), fTime(0), fTimeFrame(0), fMicrosec(0), fNanosec(0),
00045 fCrateMask(-1),
00046 fDeadPlnChips(0), fHotPlnChips(0), fColdPlnChips(0), fBusyPlnChips(0),
00047 fDeadShldChips(0), fHotShldChips(0), fColdShldChips(0), fBusyShldChips(0),
00048 fLiBox(-1), fLiLed(-1), fLiPulseHeight(0), fLiPulseWidth(0),
00049 fTpmtBox(-1), fTpmtNanosec(0),
00050 fSparsErrors(0), fEtcErrors(0),
00051 fSpillStatus(0), fSpillType(0), fSpillGpsError(-999),
00052 fLiChannels(0), fHitPlnChannels(0), fHitShldChannels(0)
00053 {
00054 SetLocalHandle(new FarDetDataQualityHandle(this));
00055 { FarDetDataQualityHandle cth(this); ch = cth; }
00056 ah.RunAlg(ch, cx);
00057 }
00058
00059 FarDetDataQuality::FarDetDataQuality(const FarDetDataQuality& rhs) :
00060 CandBase(rhs),
00061 fRun(rhs.fRun), fSubRun(rhs.fSubRun), fSnarl(rhs.fSnarl),
00062 fDate(rhs.fDate), fTime(rhs.fTime), fTimeFrame(rhs.fTimeFrame),
00063 fMicrosec(rhs.fMicrosec), fNanosec(rhs.fNanosec),
00064 fCrateMask(rhs.fCrateMask),
00065 fDeadPlnChips(rhs.fDeadPlnChips), fHotPlnChips(rhs.fHotPlnChips),
00066 fColdPlnChips(rhs.fColdPlnChips), fBusyPlnChips(rhs.fBusyPlnChips),
00067 fDeadShldChips(rhs.fDeadShldChips), fHotShldChips(rhs.fHotShldChips),
00068 fColdShldChips(rhs.fColdShldChips), fBusyShldChips(rhs.fBusyShldChips),
00069 fLiBox(rhs.fLiBox), fLiLed(rhs.fLiLed), fLiPulseHeight(rhs.fLiPulseHeight), fLiPulseWidth(rhs.fLiPulseWidth),
00070 fTpmtBox(rhs.fTpmtBox), fTpmtNanosec(rhs.fTpmtNanosec),
00071 fSparsErrors(rhs.fSparsErrors), fEtcErrors(rhs.fEtcErrors),
00072 fSpillStatus(rhs.fSpillStatus), fSpillType(rhs.fSpillType), fSpillGpsError(rhs.fSpillGpsError),
00073 fLiChannels(rhs.fLiChannels), fHitPlnChannels(rhs.fHitPlnChannels), fHitShldChannels(rhs.fHitShldChannels)
00074 {
00075
00076 }
00077
00078 FarDetDataQuality::~FarDetDataQuality()
00079 {
00080
00081 }
00082
00083 FarDetDataQuality* FarDetDataQuality::Dup() const
00084 {
00085 FarDetDataQuality *cb = new FarDetDataQuality(*this);
00086 cb->CreateLocalHandle();
00087 TIter iterdau = GetDaughterIterator();
00088 CandHandle *dau;
00089 while ((dau=(CandHandle *) iterdau())) cb->AddDaughterLink(*dau);
00090 return cb;
00091 }
00092
00093 void FarDetDataQuality::CreateLocalHandle()
00094 {
00095 this->SetLocalHandle(new FarDetDataQualityHandle(this));
00096 }
00097
00098 FarDetDataQualityHandle FarDetDataQuality::MakeCandidate(AlgHandle& ah, CandContext& cx)
00099 {
00100 FarDetDataQualityHandle cdh;
00101 new FarDetDataQuality(ah,cdh,cx);
00102 return cdh;
00103 }
00104
00105
00106