FieldTypePublisher QML Type
Publishes type_description_interfaces::msg::FieldType messages — Represents the type of a field and related meta-data. More...
| Import Statement: | import QtRos2.TypeDescriptionInterfaces |
| Inherits: | |
| Status: | Experimental Extension |
Properties
- capacity : uint64_t
- nestedTypeName : string
- stringCapacity : uint64_t
- typeId : uint8_t
Methods
- void publish(fieldType msg)
Detailed Description
A constant for each type supported according to: http://design.ros2.org/articles/legacy_interface_definition.html and: http://design.ros2.org/articles/idl_interface_definition.html Order is loosely coupled to the order of appearance in the IDL 4.2 spec: https://www.omg.org/spec/IDL/4.2
Layout of constants across the 0-255 decimal values in the uint8:
- 000 : Reserved for "not set" - 001-048: Primitive types, strings, and reserved space for future primitive types - 049-096: Fixed sized array of primitive and string types - 097-144: Bounded Sequences of primitive and string types - 145-192: Unbounded Sequences of primitive and string types - 193-255: Reserved space for future array/sequence-like types
FieldTypePublisher publishes fieldType values to a ROS 2 topic. Set the topic and node properties, then call publish() to send messages.
See also FieldTypeSubscriber and fieldType.
Property Documentation
capacity : uint64_t
The capacity field value included in the next publish. Setting this property emits capacityChanged and, when autoPublish is true, requests a publish at the end of the current event-loop iteration.
nestedTypeName : string
The nestedTypeName field value included in the next publish. Setting this property emits nestedTypeNameChanged and, when autoPublish is true, requests a publish at the end of the current event-loop iteration.
stringCapacity : uint64_t
The stringCapacity field value included in the next publish. Setting this property emits stringCapacityChanged and, when autoPublish is true, requests a publish at the end of the current event-loop iteration.
typeId : uint8_t
The typeId field value included in the next publish. Setting this property emits typeIdChanged and, when autoPublish is true, requests a publish at the end of the current event-loop iteration.
Method Documentation
void publish(fieldType msg)
Publishes fieldType msg to the ROS 2 topic set by the topic property. Does nothing if the publisher is not connected.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.