GSI Object Oriented Online Offline (Go4) GO4-6.4.0
Loading...
Searching...
No Matches
TGo4AnalysisStep.h
Go to the documentation of this file.
1// $Id$
2//-----------------------------------------------------------------------
3// The GSI Online Offline Object Oriented (Go4) Project
4// Experiment Data Processing at EE department, GSI
5//-----------------------------------------------------------------------
6// Copyright (C) 2000- GSI Helmholtzzentrum fuer Schwerionenforschung GmbH
7// Planckstr. 1, 64291 Darmstadt, Germany
8// Contact: http://go4.gsi.de
9//-----------------------------------------------------------------------
10// This software can be used under the license agreements as stated
11// in Go4License.txt file which is part of the distribution.
12//-----------------------------------------------------------------------
13
14#ifndef TGO4ANALYSISSTEP_H
15#define TGO4ANALYSISSTEP_H
16
17#include "TNamed.h"
18#include "TString.h"
19
20class TFolder;
21
22class TGo4Parameter;
23class TGo4Condition;
24class TGo4Fitter;
25
26class TGo4Analysis;
29class TGo4Condition;
30class TGo4Fitter;
34
37class TGo4EventSource;
38class TGo4EventStore;
39//class TGo4EventProcessor;
40#include "TGo4EventProcessor.h"
41
60class TGo4AnalysisStep : public TNamed {
61 public:
62
67 TGo4AnalysisStep(const char *name,
68 TGo4EventFactory *eventfactory,
69 TGo4EventSourceParameter *sourcetype = nullptr,
70 TGo4EventStoreParameter *storetype = nullptr,
71 TGo4EventProcessorParameter *processortype = nullptr);
72
73 virtual ~TGo4AnalysisStep();
74
80
82 Bool_t IsEventSourceParam() const;
83
91
94
96 void CloseEventSource();
97
103
106
108 Bool_t IsEventStoreParam() const;
109
117
119 void CloseEventStore();
120
126
134
136 void CloseEventProcessor();
137
139 void NewInputEvent();
140
142 void DeleteInputEvent();
143
145 void NewOutputEvent();
146
148 void DeleteOutputEvent();
149
152 virtual void InitEventClasses();
153
155 void SetSourceEnabled(Bool_t on = kTRUE) { fbSourceEnabled = on; }
156
158 void SetStoreEnabled(Bool_t on = kTRUE) { fbStoreEnabled = on; }
159
161 void SetProcessEnabled(Bool_t on = kTRUE) { fbProcessEnabled = on; }
162
164 void SetErrorStopEnabled(Bool_t on) { fbErrorStopEnabled = on; }
165
170
176
179
182
187
193
197
201
202 Bool_t IsStoreEnabled() const { return fbStoreEnabled; }
203
204 Bool_t IsStoreImplemented() const { return fbStoreImplemented; }
205
206 Bool_t IsSourceImplemented() const { return fbSourceImplemented; }
207
208 Bool_t IsSourceEnabled() const { return fbSourceEnabled; }
209
210 Bool_t IsProcessEnabled() const { return fbProcessEnabled; }
211
212 Bool_t IsKeepInputEvent() const { return fxEventProcessor ? fxEventProcessor->IsKeepInputEvent() : kFALSE; }
213
214 Bool_t IsKeepOutputEvent() const { return fxEventProcessor ? fxEventProcessor->IsKeepOutputEvent() : kFALSE; }
215
217 Bool_t IsErrorStopped() const { return fbErrorStopped; }
218
220 Bool_t IsErrorStopEnabled() const { return fbErrorStopEnabled; }
221
223 Int_t GetProcessStatus() const { return fiProcessStatus; }
224
226 const char *GetStatusMessage() const { return fcStatusMessage.Data(); }
227
229 void SetStatusMessage(const char *txt) { fcStatusMessage = txt; }
230
236 Bool_t IsMatchingPrevious() const;
237
240 const char *GetEventStoreName() const;
241
244 const char *GetEventSourceName() const;
245
248 void StoreCalibration();
249
251 Int_t Store(TGo4Parameter *cali);
252
254 Int_t Store(TGo4Condition *conny);
255
257 Int_t Store(TGo4Fitter *fitter);
258
260 Int_t Store(TFolder *fold);
261
266 void Process();
267
270 void Close();
271
274
277
278 private:
279
282
286
291
296
302
308
313
319
325
331
337
341 Bool_t fbSourceEnabled{kFALSE};
342
345 Bool_t fbSourceImplemented{kFALSE};
346
350 Bool_t fbStoreEnabled{kFALSE};
351
354 Bool_t fbStoreImplemented{kFALSE};
355
361 Bool_t fbProcessEnabled{kFALSE};
362
368 Bool_t fbErrorStopEnabled{kFALSE};
369
371 Bool_t fbErrorStopped{kFALSE};
372
375
378
379 ClassDefOverride(TGo4AnalysisStep,1)
380};
381
382#endif
Status of the analysis instance.
Status object of one analysis step.
Bool_t IsErrorStopped() const
True if analysis step has been stopped on error.
void SetErrorStopEnabled(Bool_t on)
Enables or disables the stop-on-error mode.
void ResetErrorStop()
Reset the stopped-after-error state of this analysis step object.
void NewInputEvent()
create input event object
Bool_t fbErrorStopEnabled
Operation mode switch.
void SetStatusMessage(const char *txt)
Set Status message of last Process() call.
Bool_t IsKeepOutputEvent() const
Int_t Store(TGo4Parameter *cali)
Saves a parameter correlated with the current event into the storage.
void SetProcessEnabled(Bool_t on=kTRUE)
Enables or disables the event processing.
TGo4EventElement * fxOutputEvent
The unpacked event (detector) structure that has been filled by the analysis step .
void SetStoreEnabled(Bool_t on=kTRUE)
Enables or disables the event store.
void Close()
Closes the analysis step.
TGo4Analysis * fxOwner
Points back to the analysis which keeps this step.
void StoreCalibration()
Store the current calibration object of the event processor into the event store instance.
virtual void InitEventClasses()
Initialization of the event class plugins which are delivered from the user defined event factory.
Bool_t IsStoreEnabled() const
TGo4EventStore * fxEventStore
The storage instance for the unpacked events (detector) structures.
Bool_t fbSourceImplemented
Flag for the previous analysis step.
void DeleteOutputEvent()
Delete input event object.
Bool_t fbProcessEnabled
Enables processing of the input event.
void NewEventProcessor(TGo4EventProcessorParameter *kind)
For lazy initialization of event processor.
Bool_t IsStoreImplemented() const
void NewEventSource(TGo4EventSourceParameter *kind)
For lazy initialization of event source.
void CloseEventStore()
Unregister and close eventstore, if existing.
TGo4AnalysisStep * GetPreviousStep() const
Get previous analysis step.
void SetPreviousStep(TGo4AnalysisStep *pre)
Sets reference to previous analysis step.
void DeleteInputEvent()
Delete input event object.
TGo4AnalysisStepStatus * CreateStatus()
Create a copy of the analysis step internal state.
void SetEventProcessor(TGo4EventProcessorParameter *kind)
Sets the event processor parameter which is used on initialization of this step.
TGo4EventElement * fxInputEvent
points to the last input event delivered from the event source 1 aggregation
void CloseEventProcessor()
Unregister and close eventprocessor, if existing.
TGo4EventStoreParameter * fxStoreType
Parameter object of next event storage to be activated.
Bool_t IsProcessEnabled() const
void Process()
The main analysis action which is invoked by the external go4 analysis.
Bool_t IsEventStoreParam() const
Return kTRUE, if event store parameter specified.
void CloseEventSource()
Unregister and close eventsource, if existing.
Bool_t IsSourceImplemented() const
Int_t fiProcessStatus
Contains current analysis step status value.
void NewOutputEvent()
create input event object
TGo4EventProcessor * fxEventProcessor
The processing class which works on the input event and fills the output event.
TGo4EventStoreParameter * GetEventStore() const
Return current event store parameter.
TGo4EventProcessorParameter * fxProcessorType
Parameter object of next event processor to be activated.
TGo4AnalysisStep * fxPrevious
Points to the previous analysis step.
TGo4EventProcessor * GetEventProcessor() const
Access to the event processor.
void SetEventSource(TGo4EventSourceParameter *kind)
Sets the event source parameter which is used on initialization of this step.
TGo4EventFactory * GetStepFactory() const
Access to step factory.
const char * GetEventStoreName() const
Access to name of currently active event store.
void SetStatus(TGo4AnalysisStepStatus *state)
Set all analysis step parameters to that of given status object.
Bool_t IsErrorStopEnabled() const
True if analysis step allows stop on error.
TGo4EventSourceParameter * fxSourceType
Parameter object of next event source to be activated.
TGo4EventElement * GetOutputEvent() const
Access to the output event which has been filled last.
TGo4EventSourceParameter * GetEventSource() const
Return current event source parameter.
Bool_t IsKeepInputEvent() const
const char * GetEventSourceName() const
Access to name of currently active event source.
Bool_t fbSourceEnabled
Enables event source.If true, the event source is used to get the input event; otherwise we use the o...
Bool_t IsSourceEnabled() const
Bool_t IsEventSourceParam() const
Return kTRUE, if event source parameter specified.
void NewEventStore(TGo4EventStoreParameter *kind)
For lazy initialization of event store.
Bool_t fbErrorStopped
True if the analysis step has been stopped after input error.
TGo4EventElement * GetInputEvent() const
Access to the input event of this step.
Bool_t fbStoreEnabled
Enables event store.
Int_t GetProcessStatus() const
Status of the last event.
Bool_t IsMatchingPrevious() const
Check if an analysis step is matching as a previous step to this step.
void SetInputEvent(TGo4EventElement *in)
Sets reference to external input event.
TGo4EventFactory * fxEventFactory
The abstract factory implementation which provides the event classes.
void SetSourceEnabled(Bool_t on=kTRUE)
Enables or disables the event source.
TString fcStatusMessage
Most recent status message.
const char * GetStatusMessage() const
Status message of last Process() call.
void SetEventStore(TGo4EventStoreParameter *kind)
Sets the event store parameter which is used on initialization of this step.
TGo4AnalysisStep()
default ctor for streamer.
Bool_t fbStoreImplemented
Flag for the subsequent analysis step.
TGo4EventSource * fxEventSource
The source of the input events.
The mother of all go4 analysis.
Go4 condition class.
The abstract base class for the data elements of which the unpacked events (or detector structure dat...
Abstract factory for the event related classes.
Basic type for all classes containing information to parametrize the event processor.
Abstract event processor.
Basic type for all classes containing information to parameterize the event source.
Basic type for all classes containing information to parametrize the event store.
The abstract interface class for the raw event store.
Central class of Go4Fit package.
Definition TGo4Fitter.h:38
Base class for all parameter aggregations, e.g.