StrictlyPositive Class Reference

A general key whose value is a strictly positive number. More...

#include "keyvalue/key/generic/StrictlyPositive.h"

Inheritance diagram for StrictlyPositive:
Inheritance graph
[legend]

List of all members.

Public Types

enum  
typedef Traits< double,
StdSingle, NoMap
Traits_
typedef StdSingle< typename
NoMap< double >::OutputType_ > 
ConverterType_
typedef ConverterType_::InputType_ InputType_
typedef ConverterType_::OutputType_ OutputType_

Public Member Functions

 StrictlyPositive (const string &name)
 Constructs key and sets its name.
void checkOutput (doubleelement) const
 Compares element against the bound(s).
string getName () const
 Gets Key's name.
void setName (const string &name)
 Sets name.
double map (const value::Variant &variant) const
 Performs the mapping.

Detailed Description

A general key whose value is a strictly positive number.


Constructor & Destructor Documentation

StrictlyPositive ( const string &  name  )  [explicit]

Constructs key and sets its name.


Member Function Documentation

void checkOutput ( double  element  )  const [inherited]

Compares element against the bound(s).

Parameters:
element : Element to be checked.
Exceptions:
RuntimeError : If element is out of bound(s).
string getName (  )  const [inherited]

Gets Key's name.

Returns:
The Key's name.

Reimplemented from Key.

void setName ( const string &  name  )  [inherited]

Sets name.

Parameters:
name : The name.
double map ( const value::Variant variant  )  const [inherited]

Performs the mapping.

This method retrieves the content of value::Variant and, by considering enabled lexical convertions, converts it to Output. (See LexicalToolKit documentation.)

Parameters:
variant : A value::Variant containing the input to be mapped.
Returns:
The mapping result.

Generated on Sat Mar 20 15:08:30 2010 for KeyValue by  doxygen 1.6.1