The Gaudi Framework  master (82fdf313)
Loading...
Searching...
No Matches
ComponentManager.h
Go to the documentation of this file.
1/***********************************************************************************\
2* (c) Copyright 1998-2025 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\***********************************************************************************/
11#pragma once
12
15
16class ApplicationMgr;
17
24class GAUDI_API ComponentManager : public CommonMessaging<implements<IComponentManager>> {
25public:
28 ComponentManager( IInterface* application, const InterfaceID& baseIID );
29
31 const InterfaceID& componentBaseInterface() const override;
32
36 StatusCode queryInterface( const InterfaceID& iid, void** pinterface ) override;
40 void const* i_cast( const InterfaceID& iid ) const override;
41
46
49
52
54 StatusCode start() override { return StatusCode::SUCCESS; }
55
57 StatusCode stop() override { return StatusCode::SUCCESS; }
58
61
64
67
69 StatusCode restart() override { return StatusCode::SUCCESS; }
70
72 Gaudi::StateMachine::State FSMState() const override { return m_stateful->FSMState(); }
73
76 Gaudi::StateMachine::State targetFSMState() const override { return m_stateful->targetFSMState(); }
77
78protected:
81
84
87
90
92};
#define GAUDI_API
Definition Kernel.h:49
The Application Manager class.
friend class CommonMessaging
StatusCode configure() override
Configuration (from OFFLINE to CONFIGURED).
StatusCode reinitialize() override
Initialization (from INITIALIZED or RUNNING to INITIALIZED, via CONFIGURED).
StatusCode stop() override
Stop (from RUNNING to INITIALIZED).
void const * i_cast(const InterfaceID &iid) const override
Specialized i_cast implementation.
StatusCode restart() override
Initialization (from RUNNING to RUNNING, via INITIALIZED).
StatusCode finalize() override
Finalize (from INITIALIZED to CONFIGURED).
StatusCode start() override
Start (from INITIALIZED to RUNNING).
Gaudi::StateMachine::State FSMState() const override
Get the current state.
StatusCode initialize() override
Initialization (from CONFIGURED to INITIALIZED).
const InterfaceID & componentBaseInterface() const override
Basic interface id of the managed components.
InterfaceID m_basicInterfaceId
Basic interface id of the managed components.
SmartIF< ISvcLocator > m_svcLocator
Service locator (needed to access the MessageSvc)
ComponentManager(IInterface *application, const InterfaceID &baseIID)
Constructor.
SmartIF< IStateful > m_stateful
Pointer to the IStateful interface of the owner.
StatusCode terminate() override
Initialization (from CONFIGURED to OFFLINE).
Gaudi::StateMachine::State targetFSMState() const override
When we are in the middle of a transition, get the state where the transition is leading us.
StatusCode queryInterface(const InterfaceID &iid, void **pinterface) override
Specialized queryInterface implementation.
SmartIF< IInterface > m_application
Pointer to the owner of the manager.
SmartIF< ISvcLocator > & serviceLocator() const override
Definition of the basic interface.
Definition IInterface.h:225
Interface ID class.
Definition IInterface.h:38
Small smart pointer class with automatic reference counting for IInterface.
Definition SmartIF.h:28
This class is used for returning status codes from appropriate routines.
Definition StatusCode.h:64
constexpr static const auto SUCCESS
Definition StatusCode.h:99
State
Allowed states for classes implementing the state machine (ApplicationMgr, Algorithm,...