openDAQ
Open data acquisition platform
DimensionRuleBuilderPtr Class Reference

Configuration component of Dimension rule objects. Contains setter methods that allow for Dimension rule parameter configuration, and a build method that builds the Dimension rule. More...

Inherits ObjectPtr< IDimensionRuleBuilder >.

Detailed Description

Configuration component of Dimension rule objects. Contains setter methods that allow for Dimension rule parameter configuration, and a build method that builds the Dimension rule.

Public Member Functions

daq::DimensionRulePtr build () const
 Builds and returns a Dimension rule object using the currently set values of the Builder. More...
 
DimensionRuleBuilderPtr setType (daq::DimensionRuleType type) const
 Sets the type of the dimension rule. Rule parameters must be configured to match the requirements of the rule type. More...
 
daq::DimensionRuleType getType () const
 Gets the type of the dimension rule. More...
 
DimensionRuleBuilderPtr setParameters (const daq::DictPtr< daq::IString, daq::IBaseObject > &parameters) const
 Sets a dictionary of string-object key-value pairs representing the parameters used to evaluate the rule. More...
 
daq::DictPtr< daq::IString, daq::IBaseObject > getParameters () const
 Gets a dictionary of string-object key-value pairs representing the parameters used to evaluate the rule. More...
 
DimensionRuleBuilderPtr addParameter (const daq::StringPtr &name, const daq::BaseObjectPtr &parameter) const
 Adds a string-object pair parameter to the Dictionary of Dimension rule parameters. More...
 
DimensionRuleBuilderPtr removeParameter (const daq::StringPtr &name) const
 Removes the parameter with the given name from the Dictionary of Dimension rule parameters.
 

Member Function Documentation

◆ addParameter()

DimensionRuleBuilderPtr addParameter ( const daq::StringPtr &  name,
const daq::BaseObjectPtr &  parameter 
) const
inline

Adds a string-object pair parameter to the Dictionary of Dimension rule parameters.

Parameters
nameThe string-type name of the parameter.
parameterThe object-type parameter.

◆ build()

daq::DimensionRulePtr build ( ) const
inline

Builds and returns a Dimension rule object using the currently set values of the Builder.

Parameters
[out]dataRuleThe built Dimension rule.

◆ getParameters()

daq::DictPtr<daq::IString, daq::IBaseObject> getParameters ( ) const
inline

Gets a dictionary of string-object key-value pairs representing the parameters used to evaluate the rule.

Returns
The dictionary containing the rule parameter members.

◆ getType()

daq::DimensionRuleType getType ( ) const
inline

Gets the type of the dimension rule.

Returns
The type of the dimension rule.

◆ setParameters()

DimensionRuleBuilderPtr setParameters ( const daq::DictPtr< daq::IString, daq::IBaseObject > &  parameters) const
inline

Sets a dictionary of string-object key-value pairs representing the parameters used to evaluate the rule.

Parameters
parametersThe dictionary containing the rule parameter members.

◆ setType()

DimensionRuleBuilderPtr setType ( daq::DimensionRuleType  type) const
inline

Sets the type of the dimension rule. Rule parameters must be configured to match the requirements of the rule type.

Parameters
typeThe type of the dimension rule.

The required rule parameters are as follows:

  • Linear: delta, start, and size number parameters. Calculated as: index * delta + start for size number of elements.
  • Logarithmic: delta, start, base, and size number parameters. Calculated as: base ^ (index * delta + start) for size number of elements.
  • List: list parameter. The list contains all dimension labels.