GetStateServiceServer QML Type
Answers lifecycle_msgs::srv::GetState ROS 2 service requests. More...
| Import Statement: | import QtRos2.LifecycleMsgs |
| Inherits: | |
| Status: | Experimental Extension |
Properties
- response : Qtros2LifecycleMsgs::State
Signals
Detailed Description
Set the topic and node properties and provide a handler function to answer requests. The handler is invoked as (request, reply) => response; it may return the response value directly, or return undefined and call reply.send(response) later for work that takes time.
Alternatively, answer declaratively without a handler: bind the response property, and each incoming request is answered with its current value. The binding may depend on on state changed in onRequestReceived.
The response is a Qtros2LifecycleMsgs::State value.
Property Documentation
response : Qtros2LifecycleMsgs::State
The declarative response. When no handler is set, each incoming request is answered immediately with the current value of this property. Bindings re-evaluate synchronously, so the expression may depend on state updated in onRequestReceived — both are already up to date when the response is sent. A callable handler takes precedence over this property.
Signal Documentation
requestReceived()
Emitted when a request arrives, before the handler is invoked.
Note: The corresponding handler is onRequestReceived.
© 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.