Skip to content

Latest commit

 

History

History
36 lines (30 loc) · 5.1 KB

File metadata and controls

36 lines (30 loc) · 5.1 KB

class SafetyConfiguration

Member values

Member name Data type Description
handle SafetyHandle Handle to safety to configure
error_threshold float32 Safety error threshold value
warning_threshold float32 Safety warning threshold value
enable SafetyEnable Safety enable state

Member functions

Function name Return type Input type Description
has_handle() const bool void Returns true if handle is set.
handle() const SafetyHandle& void Returns the current value of handle. If handle is not set, returns a SafetyHandle with none of its fields set (possibly handle::default_instance()).
mutable_handle() SafetyHandle * void Returns a pointer to the mutable SafetyHandle object that stores the field's value. If the field was not set prior to the call, then the returned SafetyHandle will have none of its fields set (i.e. it will be identical to a newly-allocated SafetyHandle). After calling this, has_handle() will return true and handle() will return a reference to the same instance of SafetyHandle.
clear_handle() void void Clears the value of the field. After calling this, has_handle() will return false and handle() will return the default value.
set_allocated_handle() void SafetyHandle * Sets the SafetyHandle object to the field and frees the previous field value if it exists. If the SafetyHandle pointer is not NULL, the message takes ownership of the allocated SafetyHandle object and has_ SafetyHandle() will return true. Otherwise, if the handle is NULL, the behavior is the same as calling clear_handle().
release_handle() SafetyHandle * void Releases the ownership of the field and returns the pointer of the SafetyHandle object. After calling this, caller takes the ownership of the allocated SafetyHandle object, has_handle() will return false, and handle() will return the default value.
error_threshold() float32 void Returns the current value of error_threshold. If the error_threshold is not set, returns 0.
set_error_threshold() void float32 Sets the value of error_threshold. After calling this, error_threshold() will return value.
clear_error_threshold() void void Clears the value of error_threshold. After calling this, error_threshold() will return 0.
warning_threshold() float32 void Returns the current value of warning_threshold. If the warning_threshold is not set, returns 0.
set_warning_threshold() void float32 Sets the value of warning_threshold. After calling this, warning_threshold() will return value.
clear_warning_threshold() void void Clears the value of warning_threshold. After calling this, warning_threshold() will return 0.
has_enable() const bool void Returns true if enable is set.
enable() const SafetyEnable& void Returns the current value of enable. If enable is not set, returns a SafetyEnable with none of its fields set (possibly enable::default_instance()).
mutable_enable() SafetyEnable * void Returns a pointer to the mutable SafetyEnable object that stores the field's value. If the field was not set prior to the call, then the returned SafetyEnable will have none of its fields set (i.e. it will be identical to a newly-allocated SafetyEnable). After calling this, has_enable() will return true and enable() will return a reference to the same instance of SafetyEnable.
clear_enable() void void Clears the value of the field. After calling this, has_enable() will return false and enable() will return the default value.
set_allocated_enable() void SafetyEnable * Sets the SafetyEnable object to the field and frees the previous field value if it exists. If the SafetyEnable pointer is not NULL, the message takes ownership of the allocated SafetyEnable object and has_ SafetyEnable() will return true. Otherwise, if the enable is NULL, the behavior is the same as calling clear_enable().
release_enable() SafetyEnable * void Releases the ownership of the field and returns the pointer of the SafetyEnable object. After calling this, caller takes the ownership of the allocated SafetyEnable object, has_enable() will return false, and enable() will return the default value.

Parent topic: DeviceConfig (C++)