ATLAS Offline Software
VP1Alg.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 //
7 // Header file for class VP1Alg
8 //
9 //
10 // This is the Athena algorithm starting a VP1 GUI
11 //
12 // Major updates:
13 // - May 2014, riccardo.mria.bianchi
14 // - Dec 2023, riccardo.maria.bianchi@cern.ch - migration to CA
15 //
17 
18 
19 #ifndef VP1ALGS_VP1ALG
20 #define VP1ALGS_VP1ALG
21 
23 #include "GaudiKernel/IIncidentListener.h"
24 #include "Gaudi/Property.h"
25 
26 #include <string>
27 #include <vector>
28 
29 class VP1Gui;
30 
31 class VP1Alg: public AthAlgorithm,
32  public IIncidentListener
33 {
34  public:
35  VP1Alg(const std::string& name, ISvcLocator* pSvcLocator);
36  ~VP1Alg();
37 
38  virtual StatusCode initialize() override;
39  virtual StatusCode execute() override;
40  virtual StatusCode finalize() override;
41 
42  void handle(const Incident& inc) override;
43 
44  private:
45 
46  // Properties
47  // -- Athena-related
48  Gaudi::Property<std::string> m_atlasRelease{this, "AtlasRelease", "", "The current, in use Atlas release"};
49  // -- MultipleFiles mode
50  Gaudi::Property<bool> m_mfOn{this, "MultipleFilesON", false,
51  "Flag to turn the 'Multiple Files' mode ON/OFF. Default OFF"};
52  Gaudi::Property<int> m_mfLimit{this, "MFNumFileLimit", 10,
53  "MultipleFiles mode -- Maximum number of local copies to keep"};
54  Gaudi::Property<std::string> m_mfSourceDir{this, "MFSourceDir", "",
55  "MultipleFiles mode -- Path of the source directory, where input data files are stored and from which events are taken from"};
56  Gaudi::Property<std::string> m_mfLocalCopyDir{this, "MFLocalCopyDir", ".",
57  "MultipleFiles mode -- Path of the directory to keep local copies of processed events. Default '.' (the local run folder)"};
58  Gaudi::Property<std::vector<std::string>> m_mfAvailableLocalInputDirectories{this, "MFAvailableLocalInputDirectories", {},
59  "MultipleFiles mode -- Will only be used if sourcedir is set and local"};
60  // -- Cruise mode
61  Gaudi::Property<std::string> m_cruiseInitialMode{this, "CruiseInitialMode", "NONE",
62  "Cruise mode -- Initial Cruise mode: 'NONE', 'EVENT', 'TAB', 'BOTH'. Default: 'NONE'"};
63  Gaudi::Property<unsigned> m_cruiseInitialUpdateSeconds{this, "CruiseInitialSeconds", 10, "Cruise mode -- Initial Cruise update time, in seconds. Default: 10"};
64  // -- Input files
65  Gaudi::Property<std::vector<std::string>> m_initialvp1files{
66  this, "InitialInputVP1Files", {}, "a vector of input VP1 files"};
67  // -- VP1 GUI
68  Gaudi::Property<bool> m_noGui{this, "noGUI", false,
69  "Flag to turn OFF the GUI. Default: FALSE (i.e., GUI is ON)"};
70 
71 
73 /*
74  // Work In Progress
75  // The variables below are needed in different VP1 configurations,
76  // which still need to be migrated to CA. In particular:
77  // - watch mode
78  // - cruise mode
79  // - batch mode / no GUI
80  // - multiple input files
81  // - pick input files from a specific directory
82  //
83  std::vector<std::string> m_initialvp1files;
84  std::string m_initialCruiseMode;//"NONE", "EVENT", "TAB", "BOTH".
85  unsigned m_initialCruiseSeconds;
86 
87  bool m_noGui;//For testing job-options in RTT
88 
89  // Properties for multiple input files (mf)
90  bool m_mfOn; // Flag to turn multiple files ON/OFF. Default OFF
91  std::string m_mfSourceDir; // Directory to take event files from
92  std::string m_mfLocalCopyDir; // Directory to keep local copies of processed events. Default "."
93  int m_mfLimit; // Maximum number of local copies to keep
94  std::vector<std::string> m_mfAvailableLocalInputDirectories;//Will only be used if sourcedir is set and local
95 */
96 
97 };
98 
99 #endif
VP1Alg::initialize
virtual StatusCode initialize() override
Definition: VP1Alg.cxx:82
VP1Alg::m_vp1gui
VP1Gui * m_vp1gui
Definition: VP1Alg.h:72
VP1Gui
Definition: VP1Gui.h:28
VP1Alg::m_initialvp1files
Gaudi::Property< std::vector< std::string > > m_initialvp1files
Definition: VP1Alg.h:65
VP1Alg
Definition: VP1Alg.h:33
VP1Alg::m_mfSourceDir
Gaudi::Property< std::string > m_mfSourceDir
Definition: VP1Alg.h:54
VP1Alg::m_cruiseInitialMode
Gaudi::Property< std::string > m_cruiseInitialMode
Definition: VP1Alg.h:61
VP1Alg::m_noGui
Gaudi::Property< bool > m_noGui
Definition: VP1Alg.h:68
VP1Alg::m_mfOn
Gaudi::Property< bool > m_mfOn
Definition: VP1Alg.h:50
VP1Alg::execute
virtual StatusCode execute() override
Definition: VP1Alg.cxx:122
AthAlgorithm.h
VP1Alg::finalize
virtual StatusCode finalize() override
Definition: VP1Alg.cxx:182
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
VP1Alg::m_mfAvailableLocalInputDirectories
Gaudi::Property< std::vector< std::string > > m_mfAvailableLocalInputDirectories
Definition: VP1Alg.h:58
VP1Alg::m_atlasRelease
Gaudi::Property< std::string > m_atlasRelease
Definition: VP1Alg.h:48
AthAlgorithm
Definition: AthAlgorithm.h:47
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
VP1Alg::~VP1Alg
~VP1Alg()
Definition: VP1Alg.cxx:77
VP1Alg::m_mfLimit
Gaudi::Property< int > m_mfLimit
Definition: VP1Alg.h:52
VP1Alg::handle
void handle(const Incident &inc) override
Definition: VP1Alg.cxx:197
VP1Alg::m_mfLocalCopyDir
Gaudi::Property< std::string > m_mfLocalCopyDir
Definition: VP1Alg.h:56
VP1Alg::m_cruiseInitialUpdateSeconds
Gaudi::Property< unsigned > m_cruiseInitialUpdateSeconds
Definition: VP1Alg.h:63
VP1Alg::VP1Alg
VP1Alg(const std::string &name, ISvcLocator *pSvcLocator)
Definition: VP1Alg.cxx:28