#ifndef VEGA_VFrCondition #define VEGA_VFrCondition //*-- Modified : v0.50 06/07/00 by D. Buskulic //*-- Modified : v0.45 10/02/00 by D. Buskulic //*-- Author : Damir Buskulic 19/11/99 #include "TNamed.h" #include "TString.h" #include "TArrayF.h" #include "VGPSTime.h" ////////////////////////////////////////////////////////////////////////// // // // VFrCondition // // // // One set of data putting conditions on a frame or set of frames, // // may be a trigger data or a slow monitoring station data or... // // // ////////////////////////////////////////////////////////////////////////// class VFrCondition : public TNamed { private : Bool_t mActive; // Flag for Active mode. if mActive==kFALSE, nothing written to disk (Not yet used) VGPSTime mTime; // GPS time at which the event occured Float_t mTimeBefore; // Duration of event before occurence time Float_t mTimeAfter; // Duration of event after occurence time Bool_t mTriggerStatus; // Boolean value returned by trigger Float_t mAmplitude; // Continuous value returned by trigger Float_t mProbability; // Likelihood estimate of event TString mVarNames; // Names of the various variables, separated by space TArrayF mVar; // Values of variables relevant to this condition Int_t mGroup; // Values of variables relevant to this condition public : VFrCondition(); VFrCondition(Text_t* name, VGPSTime time, Bool_t triggerStatus, Float_t amplitude, Float_t prob, TString varNames, Int_t nv, Float_t* vars); VFrCondition(Text_t* name, VGPSTime time, Bool_t triggerStatus, Float_t amplitude, Float_t prob, TString varNames, TArrayF tvars); ~VFrCondition() {} virtual void Copy(TObject& obj); virtual VGPSTime GetTime() {return mTime;} virtual Float_t GetTimeBefore() {return mTimeBefore;} virtual Float_t GetTimeAfter() {return mTimeAfter;} virtual Double_t GetStartTime() {return mTime.GetTimeD() - mTimeBefore;} virtual Double_t GetEndTime() {return mTime.GetTimeD() + mTimeAfter;} virtual Bool_t GetTriggerStatus() {return mTriggerStatus;} virtual Float_t GetAmplitude() {return mAmplitude;} virtual Float_t GetProbability() {return mProbability;} virtual TString GetVarNames() {return mVarNames;} virtual Float_t GetVar(Int_t i) {return mVar[i];} virtual Float_t GetVar(TString name); virtual Int_t GetGroup() {return mGroup;} virtual Bool_t IsActive() {return mActive;} virtual void SetActive(Bool_t active) {mActive = active;} virtual void SetTime(Long_t timeS, Long_t timeN) {mTime.SetSec(timeS); mTime.SetNsec(timeN);} virtual void SetTime(VGPSTime time) {mTime = time;} virtual void SetTimeBefore(Float_t timebefore) {mTimeBefore = timebefore;} virtual void SetTimeAfter(Float_t timeafter) {mTimeAfter = timeafter;} virtual void SetTriggerStatus(Bool_t triggerStatus) {mTriggerStatus = triggerStatus;} virtual void SetAmplitude(Double_t amplitude) {mAmplitude = amplitude;} virtual void SetProbability(Double_t prob) {mProbability = prob;} virtual void SetVarNames(const Text_t* names) {mVarNames = names;} virtual void SetVar(Int_t n, Float_t* array) {mVar.Set(n,array);} virtual void SetVar(TArrayF tarray) {mVar = tarray;} virtual void SetGroup(Int_t group) {mGroup = group;} virtual void Print(Option_t * opt="") {} ClassDef(VFrCondition,1) // Condition (trigger, sms,...) object for a frame }; #endif