The Gaudi Framework  master (37c0b60a)
Gaudi::Examples::Counter Class Reference

#include </builds/gaudi/Gaudi/GaudiTestSuite/include/GaudiExamples/Counter.h>

Inheritance diagram for Gaudi::Examples::Counter:
Collaboration diagram for Gaudi::Examples::Counter:

Public Member Functions

 Counter ()
 Constructors. More...
 
const CLIDclID () const override
 Retrieve reference to class definition structure. More...
 
int value () const
 Retrieve counter value. More...
 
int increment ()
 Increment counter. More...
 
int decrement ()
 Decrement counter. More...
 
void set (int val)
 Set value. More...
 
- Public Member Functions inherited from DataObject
 DataObject ()
 Standard Constructor. More...
 
 DataObject (const DataObject &rhs)
 Copy Constructor. More...
 
DataObjectoperator= (const DataObject &rhs)
 Assignment Operator. More...
 
 DataObject (DataObject &&rhs)
 Move Constructor. More...
 
DataObjectoperator= (DataObject &&rhs)
 Move Assignment Operator. More...
 
virtual ~DataObject ()
 Standard Destructor. More...
 
virtual unsigned long addRef ()
 Add reference to object. More...
 
virtual unsigned long release ()
 release reference to object More...
 
const std::stringname () const
 Retreive DataObject name. It is the name when registered in the store. More...
 
virtual StatusCode update ()
 Provide empty placeholder for internal object reconfiguration callback. More...
 
void setRegistry (IRegistry *pRegistry)
 Set pointer to Registry. More...
 
IRegistryregistry () const
 Get pointer to Registry. More...
 
LinkManagerlinkMgr ()
 Retrieve Link manager. More...
 
const LinkManagerlinkMgr () const
 
unsigned char version () const
 Retrieve version number of this object representation. More...
 
void setVersion (unsigned char vsn)
 Set version number of this object representation. More...
 
unsigned long refCount () const
 Return the refcount. More...
 
virtual std::ostreamfillStream (std::ostream &s) const
 Fill the output stream (ASCII) More...
 

Static Public Member Functions

static const CLIDclassID ()
 
- Static Public Member Functions inherited from DataObject
static const CLIDclassID ()
 Retrieve reference to class definition structure (static access) More...
 

Private Attributes

int m_counter
 Counter number. More...
 

Detailed Description

Simple counter object

Author
Markus Frank

Definition at line 32 of file Counter.h.

Constructor & Destructor Documentation

◆ Counter()

Counter::Counter ( )

Constructors.

Definition at line 18 of file legacy_examples.cpp.

18 : DataObject(), m_counter( 0 ) {}

Member Function Documentation

◆ classID()

static const CLID& Gaudi::Examples::Counter::classID ( )
inlinestatic

Definition at line 40 of file Counter.h.

40 { return CLID_Counter; }

◆ clID()

const CLID& Gaudi::Examples::Counter::clID ( ) const
inlineoverridevirtual

Retrieve reference to class definition structure.

Reimplemented from DataObject.

Definition at line 39 of file Counter.h.

39 { return classID(); }

◆ decrement()

int Gaudi::Examples::Counter::decrement ( )
inline

Decrement counter.

Definition at line 47 of file Counter.h.

47 { return --m_counter; }

◆ increment()

int Gaudi::Examples::Counter::increment ( )
inline

Increment counter.

Definition at line 45 of file Counter.h.

45 { return ++m_counter; }

◆ set()

void Gaudi::Examples::Counter::set ( int  val)
inline

Set value.

Definition at line 49 of file Counter.h.

49 { m_counter = val; }

◆ value()

int Gaudi::Examples::Counter::value ( ) const
inline

Retrieve counter value.

Definition at line 43 of file Counter.h.

43 { return m_counter; }

Member Data Documentation

◆ m_counter

int Gaudi::Examples::Counter::m_counter
private

Counter number.

Definition at line 53 of file Counter.h.


The documentation for this class was generated from the following files:
Gaudi::Examples::Counter::classID
static const CLID & classID()
Definition: Counter.h:40
Gaudi::Examples::Counter::m_counter
int m_counter
Counter number.
Definition: Counter.h:53
DataObject::DataObject
DataObject()
Standard Constructor.
Definition: DataObject.cpp:23