rclcpp  beta1
C++ ROS Client Library API
rclcpp.hpp
Go to the documentation of this file.
1 // Copyright 2014 Open Source Robotics Foundation, Inc.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 
121 #ifndef RCLCPP__RCLCPP_HPP_
122 #define RCLCPP__RCLCPP_HPP_
123 
124 #include <csignal>
125 #include <memory>
126 
127 #include "rclcpp/executors.hpp"
128 #include "rclcpp/node.hpp"
129 #include "rclcpp/parameter.hpp"
132 #include "rclcpp/rate.hpp"
133 #include "rclcpp/utilities.hpp"
135 
136 namespace rclcpp
137 {
138 
139 // Namespace escalations.
140 // For example, this next line escalates type "rclcpp:node::Node" to "rclcpp::Node"
141 using rclcpp::node::Node;
150 using ContextSharedPtr = rclcpp::context::Context::SharedPtr;
155 
156 } // namespace rclcpp
157 
158 #endif // RCLCPP__RCLCPP_HPP_
bool ok()
Check rclcpp&#39;s status.
Generic timer templated on the clock type. Periodically executes a user-specified callback...
Definition: timer.hpp:103
void init(int argc, char *argv[])
Initialize communications via the rmw implementation and set up a global signal handler.
Definition: allocator_common.hpp:24
Definition: timer.hpp:43
rclcpp::context::Context::SharedPtr ContextSharedPtr
Definition: rclcpp.hpp:150
Node is the single point of entry for creating publishers and subscribers.
Definition: node.hpp:62
Definition: subscription.hpp:51
Subscription implementation, templated on the type of message this subscription receives.
Definition: subscription.hpp:122
Definition: rate.hpp:46
A publisher publishes messages of any type to a topic.
Definition: publisher.hpp:146
bool sleep_for(const std::chrono::nanoseconds &nanoseconds)
Use the global condition variable to block for the specified amount of time.
GenericRate< std::chrono::steady_clock > WallRate
Definition: rate.hpp:117
GenericTimer< CallbackType, std::chrono::steady_clock > WallTimer
Definition: timer.hpp:179
void shutdown()
Notify the signal handler and rmw that rclcpp is shutting down.