![]() |
The Gaudi Framework
v27r0
|
Simple implementation of the abstract interface ICounterSvc. More...


Public Member Functions | |
| CounterSvc (const std::string &name, ISvcLocator *svcLoc) | |
| Standard Constructor. More... | |
| ~CounterSvc () override | |
| Standard destructor. More... | |
| StatusCode | finalize () override |
| Finalization. More... | |
| Counter * | get (const std::string &group, const std::string &name) const override |
| Access an existing counter object. More... | |
| ICounterSvc::Counters | get (const std::string &group) const override |
| get all counters form the given group: More... | |
| StatusCode | create (const std::string &group, const std::string &name, longlong initial_value, Counter *&refpCounter) override |
| Create a new counter object. More... | |
| CountObject | create (const std::string &group, const std::string &name, longlong initial_value=0) override |
| Create a new counter object. More... | |
| StatusCode | remove (const std::string &group, const std::string &name) override |
| Remove a counter object. More... | |
| StatusCode | remove (const std::string &group) override |
| Remove all counters of a given group. More... | |
| virtual StatusCode | remove () |
| Remove all known counter objects. More... | |
| StatusCode | print (const std::string &group, const std::string &name, Printout &printer) const override |
| Print counter value. More... | |
| StatusCode | print (const std::string &group, Printout &printer) const override |
| If no such counter exists the return code is COUNTER_NOT_PRESENT Note: This call is not direct access. More... | |
| StatusCode | print (const Counter *pCounter, Printout &printer) const override |
| Print counter value. More... | |
| StatusCode | print (const CountObject &pCounter, Printout &printer) const override |
| Print counter value. More... | |
| StatusCode | print (Printout &printer) const override |
| StatusCode | defaultPrintout (MsgStream &log, const Counter *pCounter) const override |
| Default Printout for counters. More... | |
| void | print () const |
| "standard" printout a'la GaudiCommon More... | |
Public Member Functions inherited from extends< BASE, Interfaces > | |
| void * | i_cast (const InterfaceID &tid) const override |
| Implementation of IInterface::i_cast. More... | |
| StatusCode | queryInterface (const InterfaceID &ti, void **pp) override |
| Implementation of IInterface::queryInterface. More... | |
| std::vector< std::string > | getInterfaceNames () const override |
| Implementation of IInterface::getInterfaceNames. More... | |
| ~extends () override=default | |
| Virtual destructor. More... | |
| void * | i_cast (const InterfaceID &tid) const override |
| Implementation of IInterface::i_cast. More... | |
| StatusCode | queryInterface (const InterfaceID &ti, void **pp) override |
| Implementation of IInterface::queryInterface. More... | |
| std::vector< std::string > | getInterfaceNames () const override |
| Implementation of IInterface::getInterfaceNames. More... | |
| ~extends () override=default | |
| Virtual destructor. More... | |
Public Member Functions inherited from extend_interfaces< Interfaces...> | |
| ~extend_interfaces () override=default | |
| Virtual destructor. More... | |
| ~extend_interfaces () override=default | |
| Virtual destructor. More... | |
Private Types | |
| typedef GaudiUtils::HashMap< std::string, Counter * > | NameMap |
| typedef GaudiUtils::HashMap< std::string, NameMap > | CountMap |
Private Member Functions | |
| std::pair< std::string, std::string > | _find (const Counter *c) const |
| size_t | num () const |
Private Attributes | |
| CountMap | m_counts |
| the actual map of counters More... | |
| bool | m_print = true |
| boolean flag to print statistics More... | |
| std::string | m_header |
| the header row More... | |
| std::string | m_format1 |
| format for regular statistical printout rows More... | |
| std::string | m_format2 |
| format for "efficiency" statistical printout rows More... | |
| bool | m_useEffFormat = true |
| flag to use the special "efficiency" format More... | |
Additional Inherited Members | |
Public Types inherited from extends< BASE, Interfaces > | |
| using | base_class = extends |
| Typedef to this class. More... | |
| using | extend_interfaces_base = extend_interfaces< Interfaces...> |
| Typedef to the base of this class. More... | |
| using | base_class = extends |
| Typedef to this class. More... | |
| using | extend_interfaces_base = extend_interfaces< Interfaces...> |
| Typedef to the base of this class. More... | |
Public Types inherited from extend_interfaces< Interfaces...> | |
| using | ext_iids = typename Gaudi::interface_list_cat< typename Interfaces::ext_iids...>::type |
| take union of the ext_iids of all Interfaces... More... | |
| using | ext_iids = typename Gaudi::interface_list_cat< typename Interfaces::ext_iids...>::type |
| take union of the ext_iids of all Interfaces... More... | |
Simple implementation of the abstract interface ICounterSvc.
Definition at line 24 of file CounterSvc.cpp.
|
private |
Definition at line 208 of file CounterSvc.cpp.
|
private |
Definition at line 207 of file CounterSvc.cpp.
|
inline |
Standard Constructor.
Definition at line 27 of file CounterSvc.cpp.
|
inlineoverride |
|
inlineprivate |
Definition at line 181 of file CounterSvc.cpp.
|
override |
Create a new counter object.
If the counter object exists already the existing object is returned. In this event the return code is COUNTER_EXISTS. The ownership of the actual counter stays with the service.
| group | [IN] Hint for smart printing |
| name | [IN] Counter name |
| initial_value | [IN] Initial counter value |
| refpCounter | [OUT] Reference to store pointer to counter. |
Definition at line 264 of file CounterSvc.cpp.
|
override |
Create a new counter object.
If the counter object exists already, a std::runtime_error exception is thrown. The ownership of the actual counter stays with the service.
| group | [IN] Hint for smart printing |
| name | [IN] Counter name |
| initial_value | [IN] Initial counter value |
| refpCounter | [OUT] Reference to store pointer to counter. |
Definition at line 295 of file CounterSvc.cpp.
|
override |
Default Printout for counters.
Definition at line 423 of file CounterSvc.cpp.
|
inlineoverride |
Finalization.
< finalize the base class
Definition at line 59 of file CounterSvc.cpp.
|
override |
Access an existing counter object.
| group | [IN] Hint for smart printing |
| name | [IN] Counter name |
Definition at line 230 of file CounterSvc.cpp.
|
override |
get all counters form the given group:
Definition at line 242 of file CounterSvc.cpp.
|
inlineprivate |
Definition at line 195 of file CounterSvc.cpp.
|
override |
Print counter value.
| group | [IN] Hint for smart printing |
| name | [IN] Counter name |
| printer | [IN] Print actor |
Definition at line 344 of file CounterSvc.cpp.
|
override |
If no such counter exists the return code is COUNTER_NOT_PRESENT Note: This call is not direct access.
| group | [IN] Hint for smart printing |
| printer | [IN] Print actor |
Definition at line 375 of file CounterSvc.cpp.
|
override |
Print counter value.
| pCounter | [IN] Pointer to Counter object |
| printer | [IN] Print actor |
Definition at line 392 of file CounterSvc.cpp.
|
override |
Print counter value.
| refCounter | [IN] Reference to CountObject object |
| printer | [IN] Print actor |
Definition at line 402 of file CounterSvc.cpp.
|
override |
| printer | [IN] Print actor |
Definition at line 408 of file CounterSvc.cpp.
| void CounterSvc::print | ( | ) | const |
"standard" printout a'la GaudiCommon
Definition at line 438 of file CounterSvc.cpp.
|
override |
Remove a counter object.
If the counter object does not exists, the return code is COUNTER_NOT_PRESENT. The counter may not be used anymore after this call.
| group | [IN] Hint for smart printing |
| name | [IN] Counter name |
| initial_value | [IN] Initial counter value |
| refpCounter | [OUT] Reference to store pointer to counter. |
Definition at line 308 of file CounterSvc.cpp.
|
override |
Remove all counters of a given group.
If no such counter exists the return code is COUNTER_NOT_PRESENT
| group | [IN] Hint for smart printing |
Definition at line 322 of file CounterSvc.cpp.
|
virtual |
Remove all known counter objects.
Definition at line 333 of file CounterSvc.cpp.
|
private |
the actual map of counters
Definition at line 210 of file CounterSvc.cpp.
|
private |
format for regular statistical printout rows
Definition at line 216 of file CounterSvc.cpp.
|
private |
format for "efficiency" statistical printout rows
Definition at line 218 of file CounterSvc.cpp.
|
private |
the header row
Definition at line 214 of file CounterSvc.cpp.
|
private |
boolean flag to print statistics
Definition at line 212 of file CounterSvc.cpp.
|
private |
flag to use the special "efficiency" format
Definition at line 220 of file CounterSvc.cpp.