Public Member Functions | Private Attributes

Geq< ElementType > Class Template Reference

Greater-than-or-equal-to bound class. More...

#include <keyvalue/key/generic/bound/Geq.h>

List of all members.

Public Member Functions

 Geq (const ElementType &bound)
 Constructs and sets bound.
bool check (const ElementType &x) const
 Performs the check.
const ElementType & getBound () const
 Gets bound value.
const char * getName () const
 Gets comparison name.

Private Attributes

const ElementType bound_

Detailed Description

template<typename ElementType>
class keyvalue::key::Geq< ElementType >

Greater-than-or-equal-to bound class.

Given a value x this class checks if x >= bound, where bound is fixed at construction time.

Parameters:
ElementType : (template parameter) Type of bound. Accepted types are double, ptime, string and unsigned int. (Other types will generate a link error.)

Constructor & Destructor Documentation

Geq ( const ElementType &  bound  )  [explicit]

Constructs and sets bound.

Parameters:
bound : The bound value.

Member Function Documentation

bool check ( const ElementType &  x  )  const

Performs the check.

Parameters:
x : Value to be checked.
Returns:
x >= bound.
const ElementType& getBound (  )  const

Gets bound value.

Returns:
The bound.
const char* getName (  )  const

Gets comparison name.

Returns:
This method returns "greater than or equal to" unless ElementType is ptime, in which case it returns "latter than or equal to".