ATLAS Offline Software
|
Vector-like class for systematic handles which interact with decorations. More...
#include <SysHandleArray.h>
Public Types | |
using | iterator = typename std::vector< HANDLE >::iterator |
using | const_iterator = typename std::vector< HANDLE >::const_iterator |
using | reverse_iterator = typename std::vector< HANDLE >::reverse_iterator |
using | const_reverse_iterator = typename std::vector< HANDLE >::const_reverse_iterator |
Public Member Functions | |
template<typename OWNER > | |
SysHandleArray (OWNER *owner, const std::vector< std::string > &values) | |
Construct the handle directly without declaring a property. More... | |
template<typename OWNER > | |
SysHandleArray (OWNER *owner, const std::string &propertyName, const std::vector< std::string > &propertyValue, const std::string &propertyDescription) | |
Declare the handle as a property on its parent. More... | |
template<typename... Args> | |
StatusCode | initialize (Args &&...args) |
Create and initialize all the sub-handles. More... | |
std::size_t | size () const noexcept |
The number of defined handles. More... | |
bool | empty () const noexcept |
Whether any sub-handles are defined. More... | |
HANDLE & | at (std::size_t idx) |
Retrieve the handle at the specified index. More... | |
const HANDLE & | at (std::size_t idx) const |
(Const) retrieve the handle at the specified index More... | |
bool | msgLvl (const MSG::Level lvl) const |
Test the output level of the object. More... | |
MsgStream & | msg () const |
The standard message stream. More... | |
MsgStream & | msg (const MSG::Level lvl) const |
The standard message stream. More... | |
iterator | begin () |
Standard vector iterator interface. More... | |
iterator | end () |
const_iterator | begin () const |
const_iterator | end () const |
const_iterator | cbegin () const |
const_iterator | cend () const |
reverse_iterator | rbegin () |
reverse_iterator | rend () |
const_reverse_iterator | rbegin () const |
const_reverse_iterator | rend () const |
const_reverse_iterator | crbegin () const |
const_reverse_iterator | crend () const |
Private Member Functions | |
void | requireInitialized () const |
Throw a std::logic_error if the handle has not been initialized. More... | |
Private Attributes | |
std::vector< std::string > | m_decorNames |
std::vector< HANDLE > | m_handles |
std::function< MsgStream &()> | m_msg |
the message stream we use More... | |
Vector-like class for systematic handles which interact with decorations.
HANDLE | The type of handle in the vector |
Definition at line 24 of file SysHandleArray.h.
using CP::SysHandleArray< HANDLE >::const_iterator = typename std::vector<HANDLE>::const_iterator |
Definition at line 29 of file SysHandleArray.h.
using CP::SysHandleArray< HANDLE >::const_reverse_iterator = typename std::vector<HANDLE>::const_reverse_iterator |
Definition at line 31 of file SysHandleArray.h.
using CP::SysHandleArray< HANDLE >::iterator = typename std::vector<HANDLE>::iterator |
Definition at line 28 of file SysHandleArray.h.
using CP::SysHandleArray< HANDLE >::reverse_iterator = typename std::vector<HANDLE>::reverse_iterator |
Definition at line 30 of file SysHandleArray.h.
CP::SysHandleArray< HANDLE >::SysHandleArray | ( | OWNER * | owner, |
const std::vector< std::string > & | values | ||
) |
Construct the handle directly without declaring a property.
OWNER | The type providing the message stream |
owner | The owner of the handle, only used for its messaging service |
values | The decoration names of each individual handle |
CP::SysHandleArray< HANDLE >::SysHandleArray | ( | OWNER * | owner, |
const std::string & | propertyName, | ||
const std::vector< std::string > & | propertyValue, | ||
const std::string & | propertyDescription | ||
) |
Declare the handle as a property on its parent.
OWNER | The type owning the handle |
owner | The owner of the handle, used for its properties and messaging |
propertyName | The name of the property to declare |
propertyValue | The default value of the property |
propertyDescription | The description of the property |
HANDLE& CP::SysHandleArray< HANDLE >::at | ( | std::size_t | idx | ) |
Retrieve the handle at the specified index.
idx | The index of the handle to retrieve |
const HANDLE& CP::SysHandleArray< HANDLE >::at | ( | std::size_t | idx | ) | const |
(Const) retrieve the handle at the specified index
idx | The index of the handle to retrieve |
iterator CP::SysHandleArray< HANDLE >::begin | ( | ) |
Standard vector iterator interface.
const_iterator CP::SysHandleArray< HANDLE >::begin | ( | ) | const |
const_iterator CP::SysHandleArray< HANDLE >::cbegin | ( | ) | const |
const_iterator CP::SysHandleArray< HANDLE >::cend | ( | ) | const |
const_reverse_iterator CP::SysHandleArray< HANDLE >::crbegin | ( | ) | const |
const_reverse_iterator CP::SysHandleArray< HANDLE >::crend | ( | ) | const |
|
noexcept |
Whether any sub-handles are defined.
Note that this will return False if any sub-handles are defined, even if all of these are actually themselves empty
iterator CP::SysHandleArray< HANDLE >::end | ( | ) |
const_iterator CP::SysHandleArray< HANDLE >::end | ( | ) | const |
StatusCode CP::SysHandleArray< HANDLE >::initialize | ( | Args &&... | args | ) |
Create and initialize all the sub-handles.
The arguments to this function should be the arguments to the initialize function on the wrapped handle type
|
inherited |
The standard message stream.
Definition at line 24 of file AsgMessagingForward.cxx.
|
inherited |
|
inherited |
Test the output level of the object.
lvl | The message level to test against |
true
If messages at level "lvl" will be printed Definition at line 11 of file AsgMessagingForward.cxx.
reverse_iterator CP::SysHandleArray< HANDLE >::rbegin | ( | ) |
const_reverse_iterator CP::SysHandleArray< HANDLE >::rbegin | ( | ) | const |
reverse_iterator CP::SysHandleArray< HANDLE >::rend | ( | ) |
const_reverse_iterator CP::SysHandleArray< HANDLE >::rend | ( | ) | const |
|
private |
Throw a std::logic_error if the handle has not been initialized.
|
noexcept |
The number of defined handles.
|
private |
Definition at line 113 of file SysHandleArray.h.
|
private |
Definition at line 114 of file SysHandleArray.h.
|
privateinherited |
the message stream we use
This used to be a simple pointer to the MsgStream
itself, but in AthenaMT the actual object used is local to the thread. So instead of pointing to it directly we are now using a function to look it up, which will get the thread-local object.
Definition at line 77 of file AsgMessagingForward.h.