JeVois  1.22
JeVois Smart Embedded Machine Vision Toolkit
Share this page:
Loading...
Searching...
No Matches

#include <jevois/Component/Parameter.H>

template<typename T>
class jevois::DynamicParameter< T >

Dynamic parameter added to a component at runtime.

Dynamic parameters can only be accessed by descriptor at the Component level (using getParamVal(), setParamVal(), etc), since there is no unique class type for them and the owning Component does not inherit from them. Typically for use via Component::addDynamicParameter(). Use with caution. Mainly developed to enable endowing python modules with JeVois parameters.

Definition at line 418 of file Parameter.H.

Inheritance diagram for jevois::DynamicParameter< T >:
Collaboration diagram for jevois::DynamicParameter< T >:

Public Types

typedef DynamicParameter< T > type
 Our type.
 

Public Member Functions

 DynamicParameter (Component *comp, ParameterDef< T > const &pdef)
 Constructor.
 
virtual ~DynamicParameter ()
 Destructor.
 
virtual Component const * owner () const override
 Handle to owning component.
 
- Public Member Functions inherited from jevois::ParameterCore< T >
 ParameterCore (ParameterDef< T > const &def)
 Constructor.
 
virtual ~ParameterCore ()
 Destructor.
 
virtual std::string const & name () const override
 Get the parameter name.
 
virtual std::string descriptor () const override
 Get the parameter fully-qualified name, aka descriptor.
 
get () const
 Get the value of this Parameter.
 
void set (T const &newVal)
 Set the value of this Parameter.
 
virtual void strset (std::string const &valstring) override
 Set the value from a string representation of it.
 
virtual std::string const strget () const override
 Get the value as a string representation of it.
 
virtual ParameterSummary const summary () const override
 Get summary info about this parameter.
 
virtual void reset () override
 Reset this parameter to its default value.
 
ParameterDef< T > const & def () const
 Access to our parameter def.
 
void changeParameterDef (ParameterDef< T > const &def)
 Change the ParameterDef of this parameter.
 
void setCallback (std::function< void(T const &)> cb)
 Set the parameter's callback.
 
- Public Member Functions inherited from jevois::ParameterBase
 ParameterBase ()
 Constructor.
 
virtual ~ParameterBase ()
 Destructor, will remove the parameter from its owner component.
 
void freeze (bool doit)
 Freeze or un-freeze a parameter; frozen parameters cannot be set(), but get() is still allowed.
 
bool frozen () const
 Returns whether parameter is frozen.
 

Additional Inherited Members

- Protected Attributes inherited from jevois::ParameterBase
boost::shared_mutex itsMutex
 Mutex to protect the parameter value.
 
volatile bool itsFrozen
 When true, parameter is frozen (read-only, does not show up in help message)
 
bool itsVirgin
 Param has not yet been explicitly set, need to call the callback (if any) at init time.
 

Member Typedef Documentation

◆ type

template<typename T >
typedef DynamicParameter<T> jevois::DynamicParameter< T >::type

Our type.

Definition at line 423 of file Parameter.H.

Constructor & Destructor Documentation

◆ DynamicParameter()

template<typename T >
jevois::DynamicParameter< T >::DynamicParameter ( Component comp,
ParameterDef< T > const &  pdef 
)

Constructor.

◆ ~DynamicParameter()

template<typename T >
virtual jevois::DynamicParameter< T >::~DynamicParameter ( )
virtual

Destructor.

Member Function Documentation

◆ owner()

template<typename T >
virtual Component const * jevois::DynamicParameter< T >::owner ( ) const
overridevirtual

Handle to owning component.

Implements jevois::ParameterCore< T >.


The documentation for this class was generated from the following file: