![]() |
The Gaudi Framework
master (42b00024)
|
#include <GaudiKernel/ISvcLocator.h>
Public Member Functions | |
DeclareInterfaceID (ISvcLocator, 3, 0) | |
InterfaceID. More... | |
virtual const std::list< IService * > & | getServices () const =0 |
Return the list of Services. More... | |
virtual bool | existsService (std::string_view name) const =0 |
Check the existence of a service given a service name. More... | |
virtual SmartIF< IService > & | service (const Gaudi::Utils::TypeNameString &typeName, const bool createIf=true)=0 |
Returns a smart pointer to a service. More... | |
template<typename T > | |
SmartIF< T > | service (const Gaudi::Utils::TypeNameString &typeName, const bool createIf=true) |
Returns a smart pointer to the requested interface of a service. More... | |
template<typename IFace > | |
SmartIF< IFace > | as () |
Gaudi::Interfaces::IOptionsSvc & | getOptsSvc () |
Direct access to Gaudi::Interfaces::IOptionsSvc implementation. More... | |
Gaudi::Monitoring::Hub & | monitoringHub () |
![]() | |
virtual void * | i_cast (const InterfaceID &) const =0 |
main cast function More... | |
virtual std::vector< std::string > | getInterfaceNames () const =0 |
Returns a vector of strings containing the names of all the implemented interfaces. More... | |
virtual unsigned long | addRef ()=0 |
Increment the reference count of Interface instance. More... | |
virtual unsigned long | release ()=0 |
Release Interface instance. More... | |
virtual unsigned long | refCount () const =0 |
Current reference count. More... | |
virtual StatusCode | queryInterface (const InterfaceID &ti, void **pp)=0 |
Set the void** to the pointer to the requested interface of the instance. More... | |
virtual | ~IInterface ()=default |
Virtual destructor. More... | |
Additional Inherited Members | |
![]() | |
enum | Status : StatusCode::code_t { Status::FAILURE = 0, Status::SUCCESS = 1, Status::NO_INTERFACE, Status::VERSMISMATCH, Status::LAST_ERROR } |
Return status. More... | |
using | iid = Gaudi::InterfaceId< IInterface, 0, 0 > |
Interface ID. More... | |
using | ext_iids = Gaudi::interface_list< iid > |
Extra interfaces. More... | |
![]() | |
static const InterfaceID & | interfaceID () |
Return an instance of InterfaceID identifying the interface. More... | |
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to locate services in the framework. Clients use this interface to locate references to interfaces of services existing in the application. This operation needs to be done before the service can be used by the client. Typically "locating the services" is done at the initialization phase of the clients.
Definition at line 46 of file ISvcLocator.h.
|
inline |
Definition at line 68 of file ISvcLocator.h.
ISvcLocator::DeclareInterfaceID | ( | ISvcLocator | , |
3 | , | ||
0 | |||
) |
|
pure virtual |
Check the existence of a service given a service name.
Gaudi::Interfaces::IOptionsSvc & ISvcLocator::getOptsSvc | ( | ) |
Direct access to Gaudi::Interfaces::IOptionsSvc implementation.
Definition at line 17 of file ISvcLocator.cpp.
|
pure virtual |
Return the list of Services.
Gaudi::Monitoring::Hub & ISvcLocator::monitoringHub | ( | ) |
Definition at line 24 of file ISvcLocator.cpp.
|
inline |
Returns a smart pointer to the requested interface of a service.
Definition at line 62 of file ISvcLocator.h.
|
pure virtual |
Returns a smart pointer to a service.