Parameters - Meta Information¶
Every parameter of type ito::Param can contain meta information that describe some boundary values, value ranges, allowed values... of the parameter. Once a parameter has its valid meta information, itom is able to check given input values with respect to the meta information as well as adapt any auto-created input masks to simplify the input with respect to the given constraints.
Most possible types of class ito::Param have their respective meta information structure.

The base class of all kind of meta information classes is the class ito::ParamMeta. Any instance of class ito::ParamMeta can contain a pointer to an instance of this base class. If you know the type of parameter (e.g. char, string or int), you can savely cast this ito::ParamMeta base instance to the right meta information class that fits to the type.
Class ParamMeta¶
The class ParamMeta is the base class for all meta information classes. Parameters of class Param may contain pointers of that class, which then must be cast to the final implementation.
-
class
ito::ParamMeta
Base class for all meta-information classes.
Parameters of type ito::Param can have a pointer to this class. Consider this base class to be abstract, such that it is only allowed to pass the right implementation (derived from this class) that fits to the type of the parameter. The runtime type information value m_type indicates the real type of this pointer, such that a direct cast can be executed.
- See
- ito::CharMeta, ito::IntMeta, ito::DoubleMeta, ito::StringMeta, ito::HWMeta, ito::DObjMeta, ito::CharArrayMeta, ito::IntArrayMeta, ito::DoubleArrayMeta
Public Type
- MetaRtti enum
Runtime type information.
MetaRtti is used to cast param meta objects, without having to enable runtime type information of the compiler.
Values:
rttiUnknown
= 0
-unknown parameter
rttiCharMeta
= 1
-meta for a char parameter
rttiIntMeta
= 2
-meta for an integer parameter
rttiDoubleMeta
= 3
-meta for a double parameter
rttiStringMeta
= 4
-meta for a string parameter
rttiHWMeta
= 5
-meta for a hardware plugin parameter
rttiDObjMeta
= 6
-meta for a data object parameter
rttiIntArrayMeta
= 7
-meta for an integer array parameter
rttiDoubleArrayMeta
= 8
-meta for a double array parameter
rttiCharArrayMeta
= 9
-meta for a char array parameter
rttiIntervalMeta
= 10
-meta for an integer array with two values that represent an interval [value1, value2] parameter
rttiDoubleIntervalMeta
= 11
-meta for a double array with two values that represent an interval [value1, value2] parameter (size of the interval is value2-value1)
rttiRangeMeta
= 12
-meta for an integer array with two values that represent a range [value1, value2] parameter (size of a range is 1+value2-value1)
rttiRectMeta
= 13
-meta for an integer array with four values that consists of two ranges (vertical and horizontal, e.g. for ROIs of cameras)
Class CharMeta, IntMeta and DoubleMeta¶
The classes CharMeta, IntMeta and DoubleMeta provide meta information for parameters of single numeric types.
-
class
ito::CharMeta
meta-information for Param of type Char.
An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::Char. If set, the given char number can be limited with respect to given minimum and maximum values as well as an optional step size (default: 1).
- See
- ito::Param, ito::ParamMeta
Public Functions
-
CharMeta
(char minVal, char maxVal, char stepSize = 1) constructor with minimum and maximum value
constructor with minimum and maximum value as well as optional step size (default: 1)
-
char
getMin
() const returns minimum value
-
char
getMax
() const returns maximum value
-
char
getStepSize
() const returns step size
-
void
setMin
(char val) sets the minimum value
- Parameters
val
-is the new minimum value, if this is bigger than the current maximum value, the maximum value is changed to val, too
-
void
setMax
(char val) sets the maximum value
- Parameters
val
-is the new maximum value, if this is smaller than the current minimum value, the minimum value is changed to val, too
-
void
setStepSize
(char val) sets the step size
- Parameters
val
-is the new step size, hence only discrete values [minVal, minVal+stepSize, minVal+2*stepSize...,maxVal] are allowed
-
class
ito::IntMeta
Meta-information for Param of type Int.
An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::Int. If set, the given integer number can be limited with respect to given minimum and maximum values as well as an optional step size (default: 1).
- See
- ito::Param, ito::ParamMeta
Public Functions
-
IntMeta
(int minVal, int maxVal, int stepSize = 1) constructor with minimum and maximum value as well as optional step size (default: 1)
-
int
getMin
() const returns minimum value
-
int
getMax
() const returns maximum value
-
int
getStepSize
() const returns step size
-
void
setMin
(int val) sets the minimum value
- Parameters
val
-is the new minimum value, if this is bigger than the current maximum value, the maximum value is changed to val, too
-
void
setMax
(int val) sets the maximum value
- Parameters
val
-is the new maximum value, if this is smaller than the current minimum value, the minimum value is changed to val, too
-
void
setStepSize
(int val) sets the step size
- Parameters
val
-is the new step size, hence only discrete values [minVal, minVal+stepSize, minVal+2*stepSize...,maxVal] are allowed
-
class
ito::DoubleMeta
Meta-information for ito::Param of type Double.
An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::Double. If set, the given double number can be limited with respect to given minimum and maximum values as well as an optional step size (default: 0.0 -> no step size).
- See
- ito::Param, ito::ParamMeta
Public Functions
-
DoubleMeta
(double minVal, double maxVal, double stepSize = 0.0) constructor with minimum and maximum value
-
double
getMin
() const returns minimum value
-
double
getMax
() const returns maximum value
-
double
getStepSize
() const returns step size
-
void
setMin
(double val) sets the minimum value
- Parameters
val
-is the new minimum value, if this is bigger than the current maximum value, the maximum value is changed to val, too
-
void
setMax
(double val) sets the maximum value
- Parameters
val
-is the new maximum value, if this is smaller than the current minimum value, the minimum value is changed to val, too
-
void
setStepSize
(double val) sets the step size
- Parameters
val
-is the new step size, hence only discrete values [minVal, minVal+stepSize, minVal+2*stepSize...,maxVal] are allowed
Public Static Functions
-
DoubleMeta *
all
() returns a new instance of DoubleMeta, where the min and max are set to the full range available for double.
Class CharArrayMeta, IntArrayMeta and DoubleArrayMeta¶
The classes CharArrayMeta, IntArrayMeta and DoubleArrayMeta provide meta information for array-based parameters of numeric types. These classes are derived from CharArray, IntArray or DoubleArray, such that the minimum and maximum value as well as the step size for each single value is given by the features of their base class. Additionally, it is possible to set a min, max and stepSize constraint concerning the number of elements of the arrays.
-
class
ito::CharArrayMeta
Meta-information for Param of type CharArrayMeta.
Meta-information for Param of type IntArrayMeta.
An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::CharArray. Since this meta information class is derived from ito::CharMeta, it is possible to restrict each value to the single value contraints of ito::CharMeta. Furthermore, this class allows restricting the minimum and maximum length of the array as well as the optional step size of the array’s length.
An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::IntArray. Since this meta information class is derived from ito::IntMeta, it is possible to restrict each value to the single value contraints of ito::IntMeta. Furthermore, this class allows restricting the minimum and maximum length of the array as well as the optional step size of the array’s length.
- See
- ito::Param, ito::ParamMeta, ito::IntArray
Public Functions
-
size_t
getNumMin
() const returns minimum number of values
-
size_t
getNumMax
() const returns maximum number of values
-
size_t
getNumStepSize
() const returns step size of number of values
-
void
setNumMin
(size_t val) sets the minimum number of values
- Parameters
val
-is the new minimum value, if this is bigger than the current maximum value, the maximum value is changed to val, too
-
void
setNumMax
(size_t val) sets the maximum number of values
- Parameters
val
-is the new maximum value, if this is smaller than the current minimum value, the minimum value is changed to val, too
-
void
setNumStepSize
(size_t val) sets the step size of the number of values
- Parameters
val
-is the new step size, hence only discrete values [minVal, minVal+stepSize, minVal+2*stepSize...,maxVal] are allowed
-
class
ito::IntArrayMeta
Public Functions
-
size_t
getNumMin
() const returns minimum number of values
-
size_t
getNumMax
() const returns maximum number of values
-
size_t
getNumStepSize
() const returns step size of number of values
-
void
setNumMin
(size_t val) sets the minimum number of values
- Parameters
val
-is the new minimum value, if this is bigger than the current maximum value, the maximum value is changed to val, too
-
void
setNumMax
(size_t val) sets the maximum number of values
- Parameters
val
-is the new maximum value, if this is smaller than the current minimum value, the minimum value is changed to val, too
-
void
setNumStepSize
(size_t val) sets the step size of the number of values
- Parameters
val
-is the new step size, hence only discrete values [minVal, minVal+stepSize, minVal+2*stepSize...,maxVal] are allowed
-
size_t
-
class
ito::DoubleArrayMeta
Meta-information for Param of type DoubleArrayMeta.
An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::DoubleArray. Since this meta information class is derived from ito::DoubleArray, it is possible to restrict each value to the single value contraints of ito::DoubleArray. Furthermore, this class allows restricting the minimum and maximum length of the array as well as the optional step size of the array’s length.
Public Functions
-
size_t
getNumMin
() const returns minimum number of values
-
size_t
getNumMax
() const returns maximum number of values
-
size_t
getNumStepSize
() const returns step size of number of values
-
void
setNumMin
(size_t val) sets the minimum number of values
- Parameters
val
-is the new minimum value, if this is bigger than the current maximum value, the maximum value is changed to val, too
-
void
setNumMax
(size_t val) sets the maximum number of values
- Parameters
val
-is the new maximum value, if this is smaller than the current minimum value, the minimum value is changed to val, too
-
void
setNumStepSize
(size_t val) sets the step size of the number of values
- Parameters
val
-is the new step size, hence only discrete values [minVal, minVal+stepSize, minVal+2*stepSize...,maxVal] are allowed
-
size_t
Class StringMeta¶
By this meta information you can give information about restrictions of strings to different strings. These strings can be interpreted as pure strings, as wildcard-expressions or regular expressions. The corresponding checks must be defined manually. If a string-parameter has an enumeration defined, where the strings are interpreted as strings, and if this parameter will automatically be parsed by any input mask in the GUI, the corresponding input text box becomes a drop-down menu with the given enumeration elements.
-
class
ito::StringMeta
Meta-information for Param of type String.
An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::String. If set, it is possible to restrict the a given string to fit to a given list of strings. This list of strings might be interpreted in an exact way (tType::String), as wildcard expressions (tType::Wildcard) or as regular expressions (tType::RegExp).
- See
- ito::Param, ito::ParamMeta
Public Functions
-
StringMeta
(tType type) constructor
Returns a meta information class for string-types.
- See
- tType
- Parameters
type
-indicates how the string elements should be considered
-
StringMeta
(tType type, const char * val) constructor
Returns a meta information class for string-types.
- See
- tType
- Parameters
type
-indicates how the string elements should be considered
val
-adds a first string to the element list
-
StringMeta
(const StringMeta & cpy) copy constructor
-
virtual
~StringMeta
() destructor
-
tType
getStringType
() const returns the type how strings in list should be considered.
- See
- tType
-
int
getLen
() const returns the number of string elements in meta information class.
-
const char *
getString
(int idx = 0) const returns string from list at index position or NULL, if index is out of range.
-
bool
addItem
(const char * val) adds another element to the list of patterns.
-
StringMeta &
operator+=
(const char * val) add another pattern string to the list of patterns.
Class DObjMeta¶
This meta information class provides further information about allowed types and boundaries concerning the dimension of a data object.
-
class
ito::DObjMeta
Meta-information for Param of type DObjPtr.
(not used yet)
- See
- ito::Param, ito::ParamMeta
Public Functions
-
int
getMinDim
() const returns maximum allowed dimensions of data object
-
int
getMaxDim
() const returns minimum number of dimensions of data object
Class HWMeta¶
By that implementation of a meta information class you can provide information about references to other instantiated plugins. Every plugin is defined by a bitmask of enumeration ito::tPluginType (defined in addInActuator.h). You can either add a minimum bitmask, that is required, to the HWMeta-instance or you can define an exact name of a plugin, which must be met.
-
class
ito::HWMeta
Meta-information for Param of type HWPtr.
An object of this class can be used to parametrize a parameter whose type is ito::ParamBase::HWPtr, that is an instance of another hardware plugin. If set, it is possible to restrict the given hardware plugin to a specific type (e.g. dataIO, dataIO + grabber, actuator...) and/or to limit it to a specific name of the plugin (e.g. SerialIO).
- See
- ito::Param, ito::ParamMeta
Public Functions
-
HWMeta
(uint32 minType) constructor
creates HWMeta-information struct where you can pass a bitmask which consists of values of the enumeration ito::tPluginType. The plugin reference of the corresponding Param should then only accept plugins, where all bits are set, too.
- See
- ito::Plugin, ito::tPluginType
-
HWMeta
(const char * HWAddInName) constructor
creates HWMeta-information struct where you can pass a specific name of a plugin, which only is allowed by the corresponding plugin-instance.
- See
- ito::Plugin
-
uint32
getMinType
() const returns type-bitmask which is minimally required by plugin-reference. Default 0.
- See
- ito::tPluginType
-
ito::ByteArray
getHWAddInName
() const returns name of specific hardware plugin