The Gaudi Framework
master (37c0b60a)
|
Base class of array's of various gaudihandles. More...
#include </builds/gaudi/Gaudi/GaudiKernel/include/GaudiKernel/GaudiHandle.h>
Public Types | |
using | PropertyType = GaudiHandleArrayProperty |
typedef std::vector< GaudiHandleBase * > | BaseHandleArray |
typedef std::vector< const GaudiHandleBase * > | ConstBaseHandleArray |
Public Member Functions | |
bool | setTypesAndNames (const std::vector< std::string > &myTypesAndNamesList) |
Set the array of handles from list of "type/name" strings in <myTypesAndNamesList>. More... | |
const std::vector< std::string > | typesAndNames () const |
Return a vector with "type/name" strings of all handles in the array. More... | |
const std::vector< std::string > | types () const |
Return a vector with "type" strings of all handles in the array. More... | |
const std::vector< std::string > | names () const |
Return a vector with "type/name" strings of all handles in the array. More... | |
const std::vector< std::string > | getBaseInfos (auto(GaudiHandleBase::*pMemFunc)() const) const |
Helper function to get a vector of strings filled with the return value of each tool of a member function if GaudiHandleBase. More... | |
std::string | pythonPropertyClassName () const override |
Name of the componentType with "HandleArray" appended. More... | |
std::string | pythonRepr () const override |
Python representation of array of handles, i.e. More... | |
virtual bool | push_back (const std::string &myHandleTypeAndName)=0 |
Add a handle to the array with "type/name" given in <myHandleTypeAndName>. More... | |
virtual void | clear ()=0 |
Clear the list of handles. More... | |
virtual bool | empty () const =0 |
Return whether the list of tools is empty. More... | |
virtual ConstBaseHandleArray | getBaseArray () const =0 |
Get a read-only vector of const GaudiHandleBase* pointing to the real handles. More... | |
virtual BaseHandleArray | getBaseArray ()=0 |
Get a read-write vector of GaudiHandleBase* pointing to the real handles. More... | |
virtual bool | retrieved () const =0 |
To be able to tell if Array was ever retreived. More... | |
Public Member Functions inherited from GaudiHandleInfo | |
virtual | ~GaudiHandleInfo () |
virtual destructor so that derived class destructor is called. More... | |
const std::string & | componentType () const |
const std::string & | propertyName () const |
name as used in declareProperty(name,gaudiHandle) More... | |
void | setPropertyName (std::string propName) |
set name as used in declareProperty(name,gaudiHandle). More... | |
const std::string & | parentName () const |
The name of the parent. More... | |
Protected Member Functions | |
GaudiHandleArrayBase (std::string myComponentType, std::string myParentName) | |
Protected Member Functions inherited from GaudiHandleInfo | |
GaudiHandleInfo (std::string myComponentType, std::string myParentName) | |
Some basic information and helper functions shared between various handles/arrays. More... | |
void | setComponentType (std::string componentType) |
The component type. More... | |
void | setParentName (std::string parent) |
The name of the parent. More... | |
Base class of array's of various gaudihandles.
Used in communication with GaudiHandleArrayProperty. For that purpose is has some pure virtual functions. This is a non-templated class to one Property can handle all kinds of concrete handles.
Definition at line 348 of file GaudiHandle.h.
Definition at line 355 of file GaudiHandle.h.
typedef std::vector<const GaudiHandleBase*> GaudiHandleArrayBase::ConstBaseHandleArray |
Definition at line 356 of file GaudiHandle.h.
Definition at line 354 of file GaudiHandle.h.
|
inlineprotected |
Definition at line 350 of file GaudiHandle.h.
|
pure virtual |
Clear the list of handles.
Implemented in GaudiHandleArray
Implemented in GaudiHandleArray< T >, GaudiHandleArray< ToolHandle< IMyTool > >, GaudiHandleArray< ToolHandle< IThreadInitTool > >, GaudiHandleArray< ToolHandle< T > >, and GaudiHandleArray< ServiceHandle< T > >.
|
pure virtual |
Return whether the list of tools is empty.
Implemented in GaudiHandleArray< T >.
|
pure virtual |
Get a read-only vector of const GaudiHandleBase* pointing to the real handles.
Implemented in GaudiHandleArray.
Implemented in GaudiHandleArray< T >.
|
pure virtual |
Get a read-write vector of GaudiHandleBase* pointing to the real handles.
Implemented in GaudiHandleArray.
Implemented in GaudiHandleArray< T >, GaudiHandleArray< ToolHandle< IMyTool > >, GaudiHandleArray< ToolHandle< IThreadInitTool > >, GaudiHandleArray< ToolHandle< T > >, GaudiHandleArray< ServiceHandle< T > >, GaudiHandleArray< ToolHandle< IMyTool > >, GaudiHandleArray< ToolHandle< IThreadInitTool > >, GaudiHandleArray< ToolHandle< T > >, and GaudiHandleArray< ServiceHandle< T > >.
const std::vector< std::string > GaudiHandleArrayBase::getBaseInfos | ( | auto(GaudiHandleBase::*)() const | pMemFunc | ) | const |
Helper function to get a vector of strings filled with the return value of each tool of a member function if GaudiHandleBase.
Definition at line 71 of file GaudiHandle.cpp.
const std::vector< std::string > GaudiHandleArrayBase::names | ( | ) | const |
Return a vector with "type/name" strings of all handles in the array.
Definition at line 83 of file GaudiHandle.cpp.
|
pure virtual |
Add a handle to the array with "type/name" given in <myHandleTypeAndName>.
Return whether addition was successful or not. Must be implemented by derived class with concrete handle category.
Implemented in ToolHandleArray< T >, ToolHandleArray< IMyTool >, ToolHandleArray< IThreadInitTool >, and ServiceHandleArray< T >.
|
overridevirtual |
Name of the componentType with "HandleArray" appended.
Used as the python class name for the property in the genconf-generated configurables. The python class is defined in GaudiPython/python/GaudiHandles.py.
Implements GaudiHandleInfo.
Definition at line 85 of file GaudiHandle.cpp.
|
overridevirtual |
Python representation of array of handles, i.e.
list of python handles. Can be used in the genconf-generated configurables. The corresponding python classes are defined in GaudiPython/GaudiHandles.py
Implements GaudiHandleInfo.
Definition at line 87 of file GaudiHandle.cpp.
|
pure virtual |
To be able to tell if Array was ever retreived.
Implemented in GaudiHandleArray< T >.
bool GaudiHandleArrayBase::setTypesAndNames | ( | const std::vector< std::string > & | myTypesAndNamesList | ) |
Set the array of handles from list of "type/name" strings in <myTypesAndNamesList>.
Return whether set was successful or not
Definition at line 63 of file GaudiHandle.cpp.
const std::vector< std::string > GaudiHandleArrayBase::types | ( | ) | const |
Return a vector with "type" strings of all handles in the array.
Definition at line 81 of file GaudiHandle.cpp.
const std::vector< std::string > GaudiHandleArrayBase::typesAndNames | ( | ) | const |
Return a vector with "type/name" strings of all handles in the array.
Inverse of setTypesAndNames()
Definition at line 77 of file GaudiHandle.cpp.