Belle II Software  release-05-02-19
ModuleParam< T > Class Template Reference

A single parameter of the module. More...

#include <ModuleParam.h>

Collaboration diagram for ModuleParam< T >:

Public Member Functions

 ModuleParam (T &paramVariable, const std::string &description="", bool force=false)
 Constructor. More...
 
virtual ~ModuleParam ()
 Destructor.
 
void setValue (const T &value)
 Sets the value of a parameter. More...
 
void setDefaultValue (const T &defaultValue)
 Sets the default value of a parameter. More...
 
T & getValue ()
 Returns the value of the parameter. More...
 
T & getDefaultValue ()
 Returns the default value of the parameter. More...
 
virtual void setValueFromPythonObject (const boost::python::object &pyObject) final
 Implements a method for setting boost::python objects. More...
 
virtual void setValueToPythonObject (boost::python::object &pyObject, bool defaultValues=false) const final
 Returns a python object containing the value or the default value of the given parameter. More...
 
virtual void setValueFromParam (const ModuleParamBase &param) final
 Set value from other ModuleParam of same type.
 
void resetValue ()
 Resets the parameter value by assigning the default value to the parameter value.
 

Static Public Member Functions

static std::string TypeInfo ()
 Static function to generate a string description for the parameter type. More...
 

Private Attributes

m_defaultValue {}
 The default value of the parameter.
 
T & m_paramVariable
 Reference to the member variable in the module which stores the parameter value.
 

Detailed Description

template<class T>
class Belle2::ModuleParam< T >

A single parameter of the module.

Implements a single parameter of the module as a template class. Inherits from the module parameter base class.

Definition at line 34 of file DisplayUI.h.


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