ThePEG::Level< T > Class Template Reference

Level is used to increment temporarily a given integer variable. More...

#include <Level.h>

List of all members.

Public Member Functions

 Level (T &newLevel)
 Constructor taking an integer variable which is incremented.
 ~Level ()
 Destructor decrementing the associated integer variable.

Private Member Functions

 Level ()
 Default constructor is private and not implemented.
 Level (const Level &)
 Copy constructor is private and not implemented.
Leveloperator= (const Level &)
 Assignment is private and not implemented.

Private Attributes

T & theLevel
 A reference to the integer variable to be decremmmented when this object is destroyed.


Detailed Description

template<typename T = int>
class ThePEG::Level< T >

Level is used to increment temporarily a given integer variable.

Everytime a Level object is created with a given integer variable as argument, the variable will be incremented. When the corresponding Level object is destroyed, the associated integer variable is decremented again.

See also:
HoldFlag

Definition at line 27 of file Level.h.


Constructor & Destructor Documentation

template<typename T = int>
ThePEG::Level< T >::Level ( T &  newLevel  )  [inline]

Constructor taking an integer variable which is incremented.

A reference to the variable will be stored.

Definition at line 33 of file Level.h.

template<typename T = int>
ThePEG::Level< T >::~Level (  )  [inline]

Destructor decrementing the associated integer variable.

Definition at line 36 of file Level.h.

References ThePEG::Level< T >::theLevel.


Member Data Documentation

template<typename T = int>
T& ThePEG::Level< T >::theLevel [private]

A reference to the integer variable to be decremmmented when this object is destroyed.

Definition at line 42 of file Level.h.

Referenced by ThePEG::Level< T >::~Level().


The documentation for this class was generated from the following file:

Generated on Thu Apr 29 12:43:25 2010 for ThePEG by  doxygen 1.5.5