GSI Object Oriented Online Offline (Go4)  GO4-6.3.0
TYYYEventSource.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 TYYYEventSource_H
15 #define TYYYEventSource_H
16 
17 #include "TGo4EventSource.h"
18 #include <fstream>
19 
20 class TYYYRawEvent;
22 
24  public:
25 
27 
29  TYYYEventSource(const char *name, const char *args, Int_t port);
30 
33 
34  virtual ~TYYYEventSource();
35 
37  virtual Int_t Open();
38 
40  virtual Int_t Close();
41 
43  Bool_t CheckEventClass(TClass *cl) override;
44 
51  Bool_t BuildEvent(TGo4EventElement *dest) override;
52 
53  const char *GetArgs() const { return fxArgs.Data(); }
54 
55  void SetArgs(const char *arg) { fxArgs = arg; }
56 
57  Int_t GetPort() const { return fiPort; }
58 
59  void SetPort(Int_t val) { fiPort = val; }
60 
61  private:
62 
63  Bool_t fbIsOpen{kFALSE};
64 
66  TString fxArgs;
67 
69  Int_t fiPort{0};
70 
72  std::ifstream *fxFile{nullptr};
73 
74  ClassDefOverride(TYYYEventSource, 1)
75 };
76 
77 #endif
Bool_t BuildEvent(TGo4EventElement *dest) override
void SetArgs(const char *arg)
void SetPort(Int_t val)
std::ifstream * fxFile
virtual ~TYYYEventSource()
const char * GetArgs() const
Int_t GetPort() const
Bool_t CheckEventClass(TClass *cl) override
virtual Int_t Close()
virtual Int_t Open()