itom 2.0.0
ito::IntervalMeta Class Reference

Meta-information for Param of type IntArrayMeta that represent an interval [minimum, maximum). More...

#include <paramMeta.h>

Inheritance diagram for ito::IntervalMeta:
ito::IntMeta ito::ParamMeta ito::RangeMeta

List of all members.

Public Member Functions

 IntervalMeta (int minVal, int maxVal, int stepSize=1)
 IntervalMeta (int minVal, int maxVal, int stepSize, int sizeMin, int sizeMax, int intervalStep=1)
int getSizeMin () const
 returns minimum size of interval or range
int getSizeMax () const
 returns maximum size of interval or range
int getSizeStepSize () const
 returns step size of size of interval or range
bool isIntervalNotRange () const
void setIntervalMin (int val)
 sets the minimum size of the interval (= max-min)
void setIntervalMax (int val)
 sets the maximum size of the interval (= max-min)
void setIntervalStep (int val)
 sets the step size of the size of the interval (= max-min)

Protected Attributes

int m_sizeMin
int m_sizeMax
int m_sizeStep
bool m_isIntervalNotRange
 this flag describes if this object is an interval where its interval/range is (end-begin) or a range with (1+end-begin)

Detailed Description

Meta-information for Param of type IntArrayMeta that represent an interval [minimum, maximum).

An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::IntArray. This meta information class indicates that the corresponding integer array parameter is interpreted as an interval, hence, only an array consisting of two values is accepted. The size of the interval is defined by the difference (value[1] - value[0]). You can restrict this size to a certain minimum and maximum value as well as indicating a specific step size (default: 1).

An example for an interval might be a certain interval of allowed radius values when optimizing a cylinder fit.

See also:
ito::Param, ito::ParamMeta, ito::RangeMeta, ito::IntMeta, ito::IntervalMeta

Member Function Documentation

void ito::IntervalMeta::setIntervalMax ( int  val)

sets the maximum size of the interval (= max-min)

Parameters:
valis the new maximum value, if this is smaller than the current minimum value, the minimum value is changed to val, too
void ito::IntervalMeta::setIntervalMin ( int  val)

sets the minimum size of the interval (= max-min)

Parameters:
valis the new minimum value, if this is bigger than the current maximum value, the maximum value is changed to val, too
void ito::IntervalMeta::setIntervalStep ( int  val)

sets the step size of the size of the interval (= max-min)

Parameters:
valis the new step size, hence only discrete values [minVal, minVal+stepSize, minVal+2*stepSize...,maxVal] are allowed

The documentation for this class was generated from the following files:
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends