23#ifndef RestCore_TRestEvent
24#define RestCore_TRestEvent
26#include <TBufferFile.h>
29#include <TTimeStamp.h>
33#include "TRestTools.h"
52 void RestartPad(Int_t nElements);
56 inline void SetRunOrigin(Int_t run_origin) {
fRunOrigin = run_origin; }
57 inline void SetSubRunOrigin(Int_t sub_run_origin) {
fSubRunOrigin = sub_run_origin; }
59 inline void SetID(Int_t
id) {
fEventID = id; }
60 inline void SetSubID(Int_t
id) {
fSubEventID = id; }
61 inline void SetSubEventTag(
const TString& tag) {
fSubEventTag = tag; }
64 void SetTime(Double_t seconds, Double_t nanoseconds);
65 inline void SetTimeStamp(
const TTimeStamp& time) {
fEventTime = time; }
67 inline void SetState(Bool_t state) {
fOk = state; }
68 inline void SetOK(Bool_t state) {
fOk = state; }
73 inline Int_t GetID()
const {
return fEventID; }
74 inline Int_t GetSubID()
const {
return fSubEventID; }
75 inline TString GetSubEventTag()
const {
return fSubEventTag; }
77 inline Int_t GetRunOrigin()
const {
return fRunOrigin; }
78 inline Int_t GetSubRunOrigin()
const {
return fSubRunOrigin; }
80 inline Double_t GetTime()
const {
return fEventTime.AsDouble(); }
81 inline TTimeStamp GetTimeStamp()
const {
return fEventTime; }
83 inline Bool_t isOk()
const {
return fOk; }
86 virtual void InitializeWithMetadata(
TRestRun* run);
A base class for any REST event.
void SetTime(Double_t time)
virtual void InitializeReferences(TRestRun *run)
Initialize dynamical references when loading the event from a root file.
virtual void CloneTo(TRestEvent *target)
Clone the content of this TRestEvent object to another.
virtual TPad * DrawEvent(const TString &option="")
Draw the event.
void SetEventInfo(TRestEvent *eve)
virtual void PrintEvent() const
Int_t fRunOrigin
Run ID number of the event.
TString fSubEventTag
A short length label to identify the sub-Event.
TTimeStamp fEventTime
Absolute event time.
Bool_t fOk
Flag to be used by processes to define an event status. fOk=true is the default.
virtual void Initialize()=0
Int_t fEventID
Event identification number.
Int_t fSubEventID
Sub-Event identification number.
Int_t fSubRunOrigin
Sub-run ID number of the event.
Data provider and manager in REST.