|
AgIsoStack++
A control-function-focused implementation of the major ISOBUS and J1939 protocols
|
A base class for a Task Controller Object. More...
#include <isobus_task_controller_client_objects.hpp>
Public Member Functions | |
| Object (std::string objectDesignator, std::uint16_t uniqueID) | |
| Constructor for the TC object base class. | |
| virtual | ~Object ()=default |
| Destructor for a TC Object. | |
| std::string | get_designator () const |
| Returns the Descriptive text for this object, UTF-8 encoded, 32 characters max. | |
| void | set_designator (const std::string &newDesignator) |
| Updates the designator to a new value. | |
| std::uint16_t | get_object_id () const |
| Returns the object ID of the object. | |
| void | set_object_id (std::uint16_t id) |
| Updates the object ID of the object to a new value. | |
| virtual std::string | get_table_id () const =0 |
| Returns the XML namespace for the object. | |
| virtual ObjectTypes | get_object_type () const =0 |
| Returns the derived TC object type fot the object. | |
| virtual std::vector< std::uint8_t > | get_binary_object () const =0 |
| Returns the binary representation of the TC object, or an empty vector if object is invalid. | |
Static Public Attributes | |
| static constexpr std::uint16_t | MAX_OBJECT_ID = 65534 |
| The max allowable "valid" object ID. | |
| static constexpr std::size_t | MAX_DESIGNATOR_LENGTH = 128 |
| Defines the max length of a designator (in bytes) | |
| static constexpr std::size_t | MAX_DESIGNATOR_LEGACY_LENGTH = 32 |
| Defines the max length of a designator (in bytes) for TCs older than version 4. | |
Protected Attributes | |
| std::string | designator |
| UTF-8 Descriptive text to identify this object. Max length of 32. | |
| std::uint16_t | objectID |
| Unique object ID in the DDOP. | |
A base class for a Task Controller Object.
Definition at line 33 of file isobus_task_controller_client_objects.hpp.
| isobus::task_controller_object::Object::Object | ( | std::string | objectDesignator, |
| std::uint16_t | uniqueID ) |
Constructor for the TC object base class.
| [in] | objectDesignator | Descriptive text for this object, UTF-8 encoded, 32 characters max |
| [in] | uniqueID | The object ID of the object. Must be unique in the DDOP. |
Definition at line 22 of file isobus_task_controller_client_objects.cpp.
|
pure virtual |
Returns the binary representation of the TC object, or an empty vector if object is invalid.
Implemented in isobus::task_controller_object::DeviceObject, isobus::task_controller_object::DeviceElementObject, isobus::task_controller_object::DeviceProcessDataObject, isobus::task_controller_object::DevicePropertyObject, and isobus::task_controller_object::DeviceValuePresentationObject.
| std::string isobus::task_controller_object::Object::get_designator | ( | ) | const |
Returns the Descriptive text for this object, UTF-8 encoded, 32 characters max.
Definition at line 28 of file isobus_task_controller_client_objects.cpp.
| std::uint16_t isobus::task_controller_object::Object::get_object_id | ( | ) | const |
Returns the object ID of the object.
Definition at line 38 of file isobus_task_controller_client_objects.cpp.
|
pure virtual |
Returns the derived TC object type fot the object.
Implemented in isobus::task_controller_object::DeviceObject, isobus::task_controller_object::DeviceElementObject, isobus::task_controller_object::DeviceProcessDataObject, isobus::task_controller_object::DevicePropertyObject, and isobus::task_controller_object::DeviceValuePresentationObject.
|
pure virtual |
Returns the XML namespace for the object.
Implemented in isobus::task_controller_object::DeviceObject, isobus::task_controller_object::DeviceElementObject, isobus::task_controller_object::DeviceProcessDataObject, isobus::task_controller_object::DevicePropertyObject, and isobus::task_controller_object::DeviceValuePresentationObject.
| void isobus::task_controller_object::Object::set_designator | ( | const std::string & | newDesignator | ) |
Updates the designator to a new value.
| [in] | newDesignator | The designator to set, UTF-8 encoded, 32 characters max |
Definition at line 33 of file isobus_task_controller_client_objects.cpp.
| void isobus::task_controller_object::Object::set_object_id | ( | std::uint16_t | id | ) |
Updates the object ID of the object to a new value.
| [in] | id | The object ID to set. IDs must be unique in the DDOP and less than or equal to MAX_OBJECT_ID |
Definition at line 43 of file isobus_task_controller_client_objects.cpp.
|
protected |
UTF-8 Descriptive text to identify this object. Max length of 32.
Definition at line 82 of file isobus_task_controller_client_objects.hpp.
|
staticconstexpr |
Defines the max length of a designator (in bytes) for TCs older than version 4.
Definition at line 79 of file isobus_task_controller_client_objects.hpp.
|
staticconstexpr |
Defines the max length of a designator (in bytes)
Definition at line 76 of file isobus_task_controller_client_objects.hpp.
|
staticconstexpr |
The max allowable "valid" object ID.
Definition at line 73 of file isobus_task_controller_client_objects.hpp.
|
protected |
Unique object ID in the DDOP.
Definition at line 83 of file isobus_task_controller_client_objects.hpp.