eicplot  trunk
EIC ROOT plotting utilities
Public Types | Public Member Functions | Protected Attributes
erhic::Range< T > Class Template Reference

#include <Utilities.h>

Inheritance diagram for erhic::Range< T >:
TObject

List of all members.

Public Types

typedef T Type

Public Member Functions

virtual ~Range ()
 Range (const T &low=T(), const T &up=T())
lower () const
middle () const
upper () const
span () const
bool excludes (const T &t) const
bool contains (const T &t) const
std::ostream & print (std::ostream &os) const
bool operator< (const Range< T > &other) const

Protected Attributes

std::pair< T, T > mRange

Detailed Description

template<typename T>
class erhic::Range< T >

A range defined by an upper and lower bound.


Constructor & Destructor Documentation

template<typename T>
virtual erhic::Range< T >::~Range ( ) [inline, virtual]

Destructor

template<typename T>
erhic::Range< T >::Range ( const T &  low = T(),
const T &  up = T() 
) [inline]

Constructor


Member Function Documentation

template<typename T>
bool erhic::Range< T >::contains ( const T &  t) const [inline]

Returns true if the test value lies in the range [lower, upper), false if not.

template<typename T>
bool erhic::Range< T >::excludes ( const T &  t) const [inline]

Returns true if the test value lies ouside the range [lower, upper), false if not.

template<typename T>
T erhic::Range< T >::lower ( ) const [inline]

Returns the lower limit of the range

template<typename T>
T erhic::Range< T >::middle ( ) const [inline]

Returns the linear midpoint of the range

template<typename T>
bool erhic::Range< T >::operator< ( const Range< T > &  other) const [inline]

Compares first the lower then the upper limits of the range. e.g. (1, 2) < (1, 3) < (2, 1)

template<typename T>
std::ostream& erhic::Range< T >::print ( std::ostream &  os) const [inline]

Prints the lower and upper limits to a stream.

template<typename T>
T erhic::Range< T >::span ( ) const [inline]

Returns the span of the range (upper - lower)

template<typename T>
T erhic::Range< T >::upper ( ) const [inline]

Returns the upper limit of the range


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