The Gaudi Framework  master (37c0b60a)
IIoComponentMgr.h
Go to the documentation of this file.
1 /***********************************************************************************\
2 * (c) Copyright 1998-2024 CERN for the benefit of the LHCb and ATLAS collaborations *
3 * *
4 * This software is distributed under the terms of the Apache version 2 licence, *
5 * copied verbatim in the file "LICENSE". *
6 * *
7 * In applying this licence, CERN does not waive the privileges and immunities *
8 * granted to it by virtue of its status as an Intergovernmental Organization *
9 * or submit itself to any jurisdiction. *
10 \***********************************************************************************/
12 // IIoComponentMgr.h
13 // Header file for class IIoComponentMgr
14 // Author: S.Binet<binet@cern.ch>
16 #ifndef GAUDIKERNEL_IIOCOMPONENTMGR_H
17 #define GAUDIKERNEL_IIOCOMPONENTMGR_H 1
18 
22 // STL includes
23 #include <string>
24 
25 // GaudiKernel includes
27 #include <GaudiKernel/StatusCode.h>
28 
29 // forward declare
30 class IIoComponent;
31 
32 class GAUDI_API IIoComponentMgr : virtual public INamedInterface {
33 public:
35 
37  // Public enums:
39 public:
40  struct IoMode {
41  enum Type { READ = 0, WRITE, RW, INVALID };
42  };
43 
45  // Public methods:
47 public:
54  virtual StatusCode io_register( IIoComponent* iocomponent ) = 0;
55 
63  const std::string& fname, const std::string& pfn = "" ) = 0;
64 
68  virtual StatusCode io_update( IIoComponent* iocomponent, const std::string& old_fname,
69  const std::string& new_fname ) = 0;
70 
74  virtual StatusCode io_update( IIoComponent* iocomponent, const std::string& work_dir ) = 0;
75 
76  // VT. new method
79  virtual StatusCode io_update_all( const std::string& work_dir ) = 0;
80 
83  virtual bool io_hasitem( IIoComponent* iocomponent ) const = 0;
84 
88  virtual bool io_contains( IIoComponent* iocomponent, const std::string& fname ) const = 0;
89 
92  virtual std::vector<std::string> io_retrieve( IIoComponent* iocomponent ) = 0;
93 
97  virtual StatusCode io_retrieve( IIoComponent* iocomponent, std::string& fname ) = 0;
98 
104 
109  virtual StatusCode io_finalize() = 0;
110 };
111 
112 #endif //> !GAUDIKERNEL_IIOCOMPONENTMGR_H
IIoComponentMgr::io_reinitialize
virtual StatusCode io_reinitialize()=0
: reinitialize the I/O subsystem.
IIoComponentMgr::io_finalize
virtual StatusCode io_finalize()=0
: finalize the I/O subsystem.
std::string
STL class.
Io::INVALID
@ INVALID
Definition: IFileMgr.h:47
IIoComponent
Definition: IIoComponent.h:26
IIoComponentMgr::io_register
virtual StatusCode io_register(IIoComponent *iocomponent, IIoComponentMgr::IoMode::Type iomode, const std::string &fname, const std::string &pfn="")=0
: allow a IIoComponent to register itself with this manager so appropriate actions can be taken when ...
std::vector< std::string >
IIoComponentMgr::DeclareInterfaceID
DeclareInterfaceID(IIoComponentMgr, 1, 0)
StatusCode.h
IIoComponentMgr::IoMode::Type
Type
Definition: IIoComponentMgr.h:41
IIoComponentMgr::io_update
virtual StatusCode io_update(IIoComponent *iocomponent, const std::string &old_fname, const std::string &new_fname)=0
: allow a IIoComponent to update the contents of the registry with a new file name
IIoComponentMgr::io_update_all
virtual StatusCode io_update_all(const std::string &work_dir)=0
: Update all IIoComponents with a new work directory
INamedInterface.h
StatusCode
Definition: StatusCode.h:65
IIoComponentMgr::io_register
virtual StatusCode io_register(IIoComponent *iocomponent)=0
: allow a IIoComponent to register itself with this manager so appropriate actions can be taken when ...
IIoComponentMgr::io_update
virtual StatusCode io_update(IIoComponent *iocomponent, const std::string &work_dir)=0
: allow a IIoComponent to update the contents of the registry with a new work directory
IIoComponentMgr::io_contains
virtual bool io_contains(IIoComponent *iocomponent, const std::string &fname) const =0
: check if the registry contains a given IIoComponent and that component had
IIoComponentMgr::io_hasitem
virtual bool io_hasitem(IIoComponent *iocomponent) const =0
: check if the registry contains a given IIoComponent
INamedInterface
Definition: INamedInterface.h:25
IIoComponentMgr
Definition: IIoComponentMgr.h:32
IIoComponentMgr::io_retrieve
virtual StatusCode io_retrieve(IIoComponent *iocomponent, std::string &fname)=0
: retrieve the new filename for a given IIoComponent and
IIoComponentMgr::io_retrieve
virtual std::vector< std::string > io_retrieve(IIoComponent *iocomponent)=0
: retrieve all registered filenames for a given IIoComponent
IIoComponentMgr::IoMode
Definition: IIoComponentMgr.h:40
GAUDI_API
#define GAUDI_API
Definition: Kernel.h:81
Io::READ
@ READ
Definition: IFileMgr.h:37
IIoComponentMgr::IoMode::WRITE
@ WRITE
Definition: IIoComponentMgr.h:41