SafeValueOperator Class

(Automation::SafeValueOperator)

The SafeValueOperator forces a safe value when necessary. More...

Header: #include <SafeValueOperator>
Inherits: CDPOperator<T>

Public Functions

SafeValueOperator(const CDPPropertyBase &in)

Reimplemented Public Functions

virtual void Configure(XMLPrimitive *operatorXML) override
virtual void Create(const char *shortName, CDPBaseObject *parent) override
virtual unsigned int Process() override
virtual unsigned int Status() const override

Additional Inherited Members

Detailed Description

The SafeValueOperator forces a safe value when necessary.

A SafeValueOperator forces a safe value when when parent signal routing is invalid. It also forces a safe value when masked input value is not 0 if UseMask is true; otherwise it forces a safe value when signal routing is invalid. A SafeValueOperator sets signal output value to its last value if UseLast is true; otherwise it sets signal output value to SafeValue. In all the other cases signal output value is set to input value.

Arguments

NameDescription
InThe default input value.
OutThe default output value.
SafeValueThe value that is forced on the output when forcing is active and UseLast is not set.
MaskA mask to do bitwise AND with the input. If result != 0 , output value is set to SafeValue
ForcedIndicates whether forcing safe value is enabled.
UseLastWhen value is being forced enables keeping the last operator output.
UseMaskEnables or disables using Mask.

Member Function Documentation

SafeValueOperator::SafeValueOperator(const CDPPropertyBase &in)

Constructs a ForceOperator with input in.

[override virtual] void SafeValueOperator::Configure(XMLPrimitive *operatorXML)

Reimplemented from CDPBaseObject::Configure().

[override virtual] void SafeValueOperator::Create(const char *shortName, CDPBaseObject *parent)

Reimplemented from CDPBaseObject::Create().

[override virtual] unsigned int SafeValueOperator::Process()

Reimplemented from CDPOperatorBase::Process().

Returns STATUS_VALUE_FORCED if ForceActive is true; otherwise returns STATUS_OK.

[override virtual] unsigned int SafeValueOperator::Status() const

Reimplemented from CDPBaseObject::Status().

Returns STATUS_VALUE_FORCED if ForceActive is true; otherwise returns STATUS_OK.

© CDP Technologies AS - All rights reserved