|
tclap 1.4.0
|
A Constraint that requires a value to fall within a closed [min, max] range, for the common "between X and Y" case that otherwise requires writing a full Constraint<T> subclass by hand. More...
#include <RangeConstraint.h>


Public Member Functions | |
| RangeConstraint (const T &min, const T &max) | |
| Constructor. | |
| std::string | description () const |
| Returns a description of the Constraint. | |
| std::string | shortID () const |
| Returns the short ID for the Constraint. | |
| bool | check (const T &value) const |
| The method used to verify that the value parsed from the command line meets the constraint. | |
Public Member Functions inherited from TCLAP::Constraint< T > | |
| virtual | ~Constraint () |
| Destructor. | |
Additional Inherited Members | |
Static Public Member Functions inherited from TCLAP::Constraint< T > | |
| static std::string | shortID (const Constraint< T > *constraint) |
A Constraint that requires a value to fall within a closed [min, max] range, for the common "between X and Y" case that otherwise requires writing a full Constraint<T> subclass by hand.
T must support <= and ostream insertion. Bounds are copied and owned. Short IDs are cached; descriptions are formatted on request. Reversed or unordered bounds accept no values; omitted optional defaults are unchecked.
Definition at line 42 of file RangeConstraint.h.
|
inline |
Constructor.
| min | - The smallest value that satisfies the constraint. |
| max | - The largest value that satisfies the constraint. |
Definition at line 49 of file RangeConstraint.h.
|
inlinevirtual |
The method used to verify that the value parsed from the command line meets the constraint.
| value | - The value that will be checked. |
Implements TCLAP::Constraint< T >.
Definition at line 65 of file RangeConstraint.h.
|
inlinevirtual |
Returns a description of the Constraint.
Implements TCLAP::Constraint< T >.
Definition at line 56 of file RangeConstraint.h.
|
inlinevirtual |
Returns the short ID for the Constraint.
Implements TCLAP::Constraint< T >.
Definition at line 63 of file RangeConstraint.h.