RetrievePoseParameter Class
Retrieves a stamped pose from the MoveIt Pro parameter manager node. More...
Declaration
Included Headers
Base class
| class | ServiceClientBehaviorBase<ServiceT> |
|
A base class for behaviors which need to send a request to a ROS service client and wait for a result. More... | |
Public Constructors Index
| RetrievePoseParameter (const std::string &name, const BT::NodeConfiguration &config, const std::shared_ptr< BehaviorContext > &shared_resources) | |
| RetrievePoseParameter (const std::string &name, const BT::NodeConfiguration &config, const std::shared_ptr< BehaviorContext > &shared_resources, std::unique_ptr< ClientInterfaceBase< RetrievePose > > client_interface) | |
Private Member Functions Index
| tl::expected< std::string, std::string > | getServiceName () override |
|
Get the name of the service. More... | |
| tl::expected< RetrievePose::Request, std::string > | createRequest () override |
|
Create the service request message. More... | |
| tl::expected< bool, std::string > | processResponse (const RetrievePose::Response &response) override |
|
Handles the service response message once the service finishes. More... | |
| std::shared_future< tl::expected< bool, std::string > > & | getFuture () override |
|
Classes derived from AsyncBehaviorBase must implement getFuture() so that it returns a shared_future class member. More... | |
Private Member Attributes Index
| std::shared_future< tl::expected< bool, std::string > > | response_future_ |
|
Holds the result of calling the service asynchronously. More... | |
Public Static Functions Index
| static BT::PortsList | providedPorts () |
|
Required implementation of the static providedPorts function. More... | |
| static BT::KeyValueVector | metadata () |
Description
Retrieves a stamped pose from the MoveIt Pro parameter manager node.
If no parameter is retrieved within the provided "timeout_sec" parameter, this Behavior returns FAILURE. Specifying zero timeout (default) makes this Behavior wait indefinitely to retrieve the parameter.
| Data Port Name | Port Type | Object Type |
|---|---|---|
| timeout_sec | input | double |
| pose | output | geometry_msgs::msg::PoseStamped |
Definition at line 29 of file retrieve_pose_parameter.hpp.
Public Constructors
RetrievePoseParameter()
| explicit |
Declaration at line 32 of file retrieve_pose_parameter.hpp, definition at line 38 of file retrieve_pose_parameter.cpp.
RetrievePoseParameter()
| explicit |
Declaration at line 35 of file retrieve_pose_parameter.hpp, definition at line 44 of file retrieve_pose_parameter.cpp.
Private Member Functions
createRequest()
| virtual |
Create the service request message.
- Returns
a RetrievePose request message with the specified timeout.
Declaration at line 59 of file retrieve_pose_parameter.hpp, definition at line 71 of file retrieve_pose_parameter.cpp.
getFuture()
| inline virtual |
Classes derived from AsyncBehaviorBase must implement getFuture() so that it returns a shared_future class member.
Definition at line 69 of file retrieve_pose_parameter.hpp.
getServiceName()
| virtual |
Get the name of the service.
For this behavior the service name is always "/retrieve_pose".
- Returns
Returns the service name. Since the service name is set to a constant value, this always succeeds.
Declaration at line 53 of file retrieve_pose_parameter.hpp, definition at line 66 of file retrieve_pose_parameter.cpp.
processResponse()
|
Handles the service response message once the service finishes.
- Returns
Returns an error result if the service finished but did not succeed, since this is treated as an unexpected error state. Otherwise, returns true.
Declaration at line 66 of file retrieve_pose_parameter.hpp, definition at line 85 of file retrieve_pose_parameter.cpp.
Private Member Attributes
response_future_
|
Holds the result of calling the service asynchronously.
Definition at line 75 of file retrieve_pose_parameter.hpp.
Public Static Functions
metadata()
| static |
Declaration at line 45 of file retrieve_pose_parameter.hpp, definition at line 60 of file retrieve_pose_parameter.cpp.
providedPorts()
| static |
Required implementation of the static providedPorts function.
- Returns
The list of input and output ports used by this Behavior.
Declaration at line 43 of file retrieve_pose_parameter.hpp, definition at line 51 of file retrieve_pose_parameter.cpp.
The documentation for this class was generated from the following files:
Generated via doxygen2docusaurus 2.2.2 by Doxygen 1.9.8.