27 template <
class T>
class ParameterCore;
36 ParameterCategory(std::string
const & name_ =
"General Options", std::string
const & description_ =
"");
58 std::string
const &
name()
const;
96 template <
template <
typename>
class ValidValuesSpec>
144 std::shared_ptr<ValidValuesSpecBase<T> > itsValidValuesSpec;
145 void checkDefaultValue();
151#include <jevois/Component/details/ParameterDefImpl.H>
A changeable parameter for a Component, core class.
Base class for a Parameter definition.
ParameterCategory itsCategory
Our category.
ParameterCategory const & category() const
The Parameter category.
std::string const & name() const
The parameter name (without the leading "--")
std::string const & description() const
Description of what the parameter does.
std::string itsDescription
Our description string.
virtual std::string const validValuesString() const =0
Valid values in string representation.
virtual std::string const defaultValueString() const =0
Default value in string representation.
std::string itsName
Our name.
virtual ~ParameterDefBase()
Destructor.
ParameterDef(std::string const &name, std::string const &description, T const &defaultValue, ParameterCategory const &category)
Construct a ParameterDef with no given valid values, valid values are whatever T can take.
virtual std::string const defaultValueString() const
Default value in string representation.
ParameterDef(std::string const &name, std::string const &description, T const &defaultValue, jevois::StepRange< T > const &validrange, ParameterCategory const &category)
Shorthand to create a Parameter definition with specified valid values from a step range (bounds incl...
ParameterDef(std::string const &name, std::string const &description, T const &defaultValue, jevois::Range< T > const &validrange, ParameterCategory const &category)
Shorthand to create a Parameter definition with specified valid values from a range (bounds inclusive...
ParameterDef(std::string const &name, std::string const &description, T const &defaultValue, ValidValuesSpec< T > const &validValuesSpec, ParameterCategory const &category)
Create a Parameter definition with specified valid values from a ValidValueSpec.
ParameterDef(std::string const &name, std::string const &description, T const &defaultValue, std::vector< T > const &validvalues, ParameterCategory const &category)
Shorthand to create a Parameter definition with specified valid values from a list.
T const defaultValue() const
Get the default value that was specified for this Parameter definition.
virtual std::string const validValuesString() const
Valid values in string representation.
ParameterDef(std::string const &name, std::string const &description, T const &defaultValue, boost::regex const &validregex, ParameterCategory const &category)
Shorthand to create a Parameter definition with specified valid values in a regex.
A generic range class with a step.
Main namespace for all JeVois classes and functions.
A category to which multiple ParameterDef definitions can belong.
std::string name
The name of the category.
std::string description
An optional short description of the category.