OcaUint8Actuator#
This document describes the controller implementation of OcaUint8Actuator. This class is documented in the AES70 standard as:
8-bit unsigned integer actuator
Overview#
- ClassID: 1.1.1.1.6
- Header:
aes70/controller/OcaUint8Actuator.hpp
- Namespace:
aes70::controller
- Inheritance: aes70::controller::OcaBasicActuator, aes70::controller::OcaActuator, aes70::controller::OcaWorker, aes70::controller::OcaRoot, aes70::controller::object
Class Declaration#
namespace aes70::controller
{
class OcaUint8Actuator : public OcaBasicActuator
{
public:
OcaUint8Actuator(std::shared_ptr<connection> connection,
uin32_t object_number);
OcaUint8Actuator(const OcaUint8Actuator &o);
// Control Methods
// Calls GetSetting and calls on_result or on_failure
void GetSetting(auto on_result, failure_callback on_failure);
// Calls SetSetting and calls on_result or on_failure
void SetSetting(OcaUint8 Setting, auto on_result, failure_callback on_failure);
// Calls SetSetting and does not wait for the response
void SetSetting(OcaUint8 Setting);
// Observing Properties
subscription observeSetting(auto callback, failure_callback on_failure);
// Property Changed Subscriptions
subscription OnSettingChanged(auto callback, failure_callback on_failure);
};
}
Methods#
GetSetting#
void GetSetting(auto on_result, failure_callback on_failure)
Calls the method GetSetting in the remote device.
Parameters:#
auto on_result
: A callable (e.g. a lambda) with the following arguments:OcaUint8 Setting
OcaUint8 minSetting
OcaUint8 maxSetting
failure_callback on_failure
: A callback which is called on error.
SetSetting#
void SetSetting(OcaUint8 Setting, auto on_result, failure_callback on_failure)
Calls the method SetSetting in the remote device. If no result and error callback is specified, the method will be called without requesting a response.
Parameters:#
OcaUint8 Setting
auto on_result
: A callable (e.g. a lambda) with 0 arguments.failure_callback on_failure
: A callback which is called on error.
observeSetting#
subscription observeSetting(auto callback, failure_callback on_failure)
Fetches the remote property Setting and subscribes for modifications. The callback is called with the initial values of Setting and whenever it changes.
Parameters:#
auto callback
: A callable (e.g. a lambda) with one argument:OcaUint8 Setting
failure_callback on_failure
: A callback which is called on error.
OnSettingChanged#
subscription OnSettingChanged(auto callback, failure_callback on_failure)
Parameters#
auto callback
: A callable (e.g. a lambda) with one argument:OcaUint8 Setting
failure_callback on_failure
: A callback which is called on error.