C++ Based OPC UA Client/Server SDK  1.5.5.355
AggregateCalculatorAverage Class Reference

Calculates the value of the aggregates Average, TimeAverage, TimeAverage2, Total and Total2. More...

#include <aggregatecalculatoraverage.h>

Inherits AggregateCalculator.

Public Member Functions

 AggregateCalculatorAverage (UaNodeId aggregateId, UaDateTime startTime, UaDateTime endTime, double processingInterval, bool stepped, OpcUa_AggregateConfiguration &configuration)
 Initializes the aggregate calculator. More...
 
bool UsesInterpolatedBounds ()
 Indicates whether this aggregate uses Interpolated Bounding Values. More...
 

Static Public Member Functions

static
AggregateCalculatorInterface
CreateCalculator (UaNodeId aggregateId, UaDateTime startTime, UaDateTime endTime, double processingInterval, bool stepped, OpcUa_AggregateConfiguration &configuration)
 Used by the Aggregators factory to create a new instance of the aggregate calculator. More...
 

Protected Member Functions

UaDataValue ComputeValue (TimeSlice &slice)
 Computes the value for the timeslice. More...
 
UaDataValue ComputeAverage (TimeSlice &slice)
 Calculates the RegSlope, RegConst and RegStdDev aggregates for the timeslice. More...
 
UaDataValue ComputeTimeAverage (TimeSlice &slice, bool useSimpleBounds, int valueType)
 Calculates the StdDev, Variance, StdDev2 and Variance2 aggregates for the timeslice. More...
 

Detailed Description

Calculates the value of the aggregates Average, TimeAverage, TimeAverage2, Total and Total2.

Constructor & Destructor Documentation

AggregateCalculatorAverage::AggregateCalculatorAverage ( UaNodeId  aggregateId,
UaDateTime  startTime,
UaDateTime  endTime,
double  processingInterval,
bool  stepped,
OpcUa_AggregateConfiguration configuration 
)

Initializes the aggregate calculator.

Parameters
aggregateIdThe aggregate function to apply.
startTimeThe start time.
endTimeThe end time.
processingIntervalThe processing interval.
steppedWhether to use stepped interpolation.
configurationThe aggregate configuration.

Member Function Documentation

UaDataValue AggregateCalculatorAverage::ComputeAverage ( TimeSlice slice)
protected

Calculates the RegSlope, RegConst and RegStdDev aggregates for the timeslice.

UaDataValue AggregateCalculatorAverage::ComputeTimeAverage ( TimeSlice slice,
bool  useSimpleBounds,
int  valueType 
)
protected

Calculates the StdDev, Variance, StdDev2 and Variance2 aggregates for the timeslice.

UaDataValue AggregateCalculatorAverage::ComputeValue ( TimeSlice slice)
protectedvirtual

Computes the value for the timeslice.

Reimplemented from AggregateCalculator.

AggregateCalculatorInterface * AggregateCalculatorAverage::CreateCalculator ( UaNodeId  aggregateId,
UaDateTime  startTime,
UaDateTime  endTime,
double  processingInterval,
bool  stepped,
OpcUa_AggregateConfiguration configuration 
)
static

Used by the Aggregators factory to create a new instance of the aggregate calculator.

Parameters
aggregateIdThe aggregate function to apply.
startTimeThe start time.
endTimeThe end time.
processingIntervalThe processing interval.
steppedWhether to use stepped interpolation.
configurationThe aggregate configuration.
bool AggregateCalculatorAverage::UsesInterpolatedBounds ( )
virtual

Indicates whether this aggregate uses Interpolated Bounding Values.

Returns
True if this aggregate uses Interpolated Bounding Values and false if it uses Simple Bounding Values.

Reimplemented from AggregateCalculator.


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