Template class for checking topic reception. More...
#include <topic_status_check_base.hpp>
Inheritance diagram for system_health_check::base::TopicStatusCheckBase< MessageT >:
Collaboration diagram for system_health_check::base::TopicStatusCheckBase< MessageT >:Protected Member Functions | |
| void | set_status_id (const std::string id) |
| Set the status id for cache check. | |
| void | set_config (const std::string topic_name, const uint32_t timeout_ms) |
| virtual void | prepare_check (rclcpp::Node::SharedPtr node) override=0 |
| Prepares the check before execution. | |
| virtual bool | validate (const MessageT &msg) |
| Virtual function to verify message content. Defaults to "OK if received". Override in a derived class to inspect content (e.g., msg->data == true). | |
| virtual std::string | get_unique_id () const |
| Generates a unique identifier for the check instance. | |
| virtual void | prepare_check (rclcpp::Node::SharedPtr node) |
| Prepares the check before execution. | |
| virtual bool | check_impl (rclcpp::Node::SharedPtr node)=0 |
| Actual implementation of the check logic. | |
| virtual std::string | report_impl (rclcpp::Node::SharedPtr node)=0 |
| Generates a detailed report of the check. | |
Additional Inherited Members | |
Public Member Functions inherited from system_health_check::base::SystemCheckBase | |
| virtual | ~SystemCheckBase () |
| bool | check (rclcpp::Node::SharedPtr node) |
| Executes the system check with caching support. | |
| std::string | report (rclcpp::Node::SharedPtr node) |
| Generates a human-readable report of the check. | |
Template class for checking topic reception.
| MessageT | The message type to check (e.g., std_msgs::msg::Bool). |
|
overrideprotectedpure virtual |
Prepares the check before execution.
| node | Shared pointer to the ROS 2 node. |
Derived classes can override this function to perform any necessary setup.
Reimplemented from system_health_check::base::SystemCheckBase.
|
inlineprotected |
|
inlineprotected |
Set the status id for cache check.
| id | status id (e.g., "depth_status") |
|
inlineprotectedvirtual |
Virtual function to verify message content. Defaults to "OK if received". Override in a derived class to inspect content (e.g., msg->data == true).