Skip to content

Commit

Permalink
Add a method to the LifecycleNode class to get the logging interface (#…
Browse files Browse the repository at this point in the history
…652)

There are getters for the other interfaces, but the logging interface
appears to have been overlooked.

Signed-off-by: Michael Jeronimo <michael.jeronimo@intel.com>
  • Loading branch information
Michael Jeronimo authored and Karsten1987 committed Mar 6, 2019
1 parent c51b284 commit d2d9ad8
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
5 changes: 5 additions & 0 deletions rclcpp_lifecycle/include/rclcpp_lifecycle/lifecycle_node.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,11 @@ class LifecycleNode : public node_interfaces::LifecycleNodeInterface,
rclcpp::node_interfaces::NodeGraphInterface::SharedPtr
get_node_graph_interface();

/// Return the Node's internal NodeLoggingInterface implementation.
RCLCPP_LIFECYCLE_PUBLIC
rclcpp::node_interfaces::NodeLoggingInterface::SharedPtr
get_node_logging_interface();

/// Return the Node's internal NodeTimersInterface implementation.
RCLCPP_LIFECYCLE_PUBLIC
rclcpp::node_interfaces::NodeTimersInterface::SharedPtr
Expand Down
6 changes: 6 additions & 0 deletions rclcpp_lifecycle/src/lifecycle_node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,12 @@ LifecycleNode::get_node_graph_interface()
return node_graph_;
}

rclcpp::node_interfaces::NodeLoggingInterface::SharedPtr
LifecycleNode::get_node_logging_interface()
{
return node_logging_;
}

rclcpp::node_interfaces::NodeTimersInterface::SharedPtr
LifecycleNode::get_node_timers_interface()
{
Expand Down

0 comments on commit d2d9ad8

Please sign in to comment.