From 467fef0f365bacd82f71a2c00eb768fac2cd00a5 Mon Sep 17 00:00:00 2001 From: Jacob Perron Date: Wed, 12 Jan 2022 14:26:37 -0800 Subject: [PATCH] Fix include order for cpplint (#221) Relates to https://github.com/ament/ament_lint/pull/324 Signed-off-by: Jacob Perron --- .../image_transport/camera_publisher.hpp | 16 ++++++++-------- .../image_transport/camera_subscriber.hpp | 10 +++++----- .../image_transport/image_transport.hpp | 18 +++++++++--------- .../include/image_transport/publisher.hpp | 18 +++++++++--------- .../image_transport/publisher_plugin.hpp | 12 ++++++------ .../include/image_transport/raw_publisher.hpp | 8 ++++---- .../include/image_transport/raw_subscriber.hpp | 10 +++++----- .../simple_publisher_plugin.hpp | 14 +++++++------- .../simple_subscriber_plugin.hpp | 10 +++++----- .../single_subscriber_publisher.hpp | 6 +++--- .../include/image_transport/subscriber.hpp | 14 +++++++------- .../image_transport/subscriber_filter.hpp | 14 +++++++------- .../image_transport/subscriber_plugin.hpp | 12 ++++++------ .../image_transport/transport_hints.hpp | 8 ++++---- image_transport/src/camera_publisher.cpp | 14 +++++++------- image_transport/src/camera_subscriber.cpp | 12 ++++++------ image_transport/src/image_transport.cpp | 14 +++++++------- image_transport/src/list_transports.cpp | 12 ++++++------ image_transport/src/publisher.cpp | 18 +++++++++--------- image_transport/src/republish.cpp | 14 +++++++------- .../src/single_subscriber_publisher.cpp | 6 +++--- image_transport/src/subscriber.cpp | 16 ++++++++-------- image_transport/test/test_message_passing.cpp | 14 +++++++------- .../test/test_single_subscriber_publisher.cpp | 14 +++++++------- 24 files changed, 152 insertions(+), 152 deletions(-) diff --git a/image_transport/include/image_transport/camera_publisher.hpp b/image_transport/include/image_transport/camera_publisher.hpp index 4a6f2615..9945ea54 100644 --- a/image_transport/include/image_transport/camera_publisher.hpp +++ b/image_transport/include/image_transport/camera_publisher.hpp @@ -29,17 +29,17 @@ #ifndef IMAGE_TRANSPORT__CAMERA_PUBLISHER_HPP_ #define IMAGE_TRANSPORT__CAMERA_PUBLISHER_HPP_ -#include -#include +#include +#include -#include -#include +#include "rclcpp/macros.hpp" +#include "rclcpp/node.hpp" -#include -#include +#include "sensor_msgs/msg/image.hpp" +#include "sensor_msgs/msg/camera_info.hpp" -#include -#include +#include "image_transport/single_subscriber_publisher.hpp" +#include "image_transport/visibility_control.hpp" namespace image_transport { diff --git a/image_transport/include/image_transport/camera_subscriber.hpp b/image_transport/include/image_transport/camera_subscriber.hpp index e661c1f6..5157111d 100644 --- a/image_transport/include/image_transport/camera_subscriber.hpp +++ b/image_transport/include/image_transport/camera_subscriber.hpp @@ -29,15 +29,15 @@ #ifndef IMAGE_TRANSPORT__CAMERA_SUBSCRIBER_HPP_ #define IMAGE_TRANSPORT__CAMERA_SUBSCRIBER_HPP_ -#include - -#include -#include - #include #include #include +#include "rclcpp/node.hpp" + +#include "sensor_msgs/msg/camera_info.hpp" +#include "sensor_msgs/msg/image.hpp" + #include "image_transport/visibility_control.hpp" namespace image_transport diff --git a/image_transport/include/image_transport/image_transport.hpp b/image_transport/include/image_transport/image_transport.hpp index 8fb5ee20..0d019bca 100644 --- a/image_transport/include/image_transport/image_transport.hpp +++ b/image_transport/include/image_transport/image_transport.hpp @@ -29,20 +29,20 @@ #ifndef IMAGE_TRANSPORT__IMAGE_TRANSPORT_HPP_ #define IMAGE_TRANSPORT__IMAGE_TRANSPORT_HPP_ -#include - -#include -#include -#include -#include -#include -#include - #include #include #include #include +#include "rclcpp/node.hpp" + +#include "image_transport/camera_publisher.hpp" +#include "image_transport/camera_subscriber.hpp" +#include "image_transport/publisher.hpp" +#include "image_transport/subscriber.hpp" +#include "image_transport/transport_hints.hpp" +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/include/image_transport/publisher.hpp b/image_transport/include/image_transport/publisher.hpp index 5022b10c..755c5dfd 100644 --- a/image_transport/include/image_transport/publisher.hpp +++ b/image_transport/include/image_transport/publisher.hpp @@ -29,18 +29,18 @@ #ifndef IMAGE_TRANSPORT__PUBLISHER_HPP_ #define IMAGE_TRANSPORT__PUBLISHER_HPP_ -#include -#include +#include +#include -#include +#include "rclcpp/macros.hpp" +#include "rclcpp/node.hpp" -#include -#include -#include -#include +#include "sensor_msgs/msg/image.hpp" -#include -#include +#include "image_transport/exception.hpp" +#include "image_transport/loader_fwds.hpp" +#include "image_transport/single_subscriber_publisher.hpp" +#include "image_transport/visibility_control.hpp" namespace image_transport { diff --git a/image_transport/include/image_transport/publisher_plugin.hpp b/image_transport/include/image_transport/publisher_plugin.hpp index d244b2ef..aa04e9a3 100644 --- a/image_transport/include/image_transport/publisher_plugin.hpp +++ b/image_transport/include/image_transport/publisher_plugin.hpp @@ -29,15 +29,15 @@ #ifndef IMAGE_TRANSPORT__PUBLISHER_PLUGIN_HPP_ #define IMAGE_TRANSPORT__PUBLISHER_PLUGIN_HPP_ -#include -#include - -#include -#include - #include #include +#include "rclcpp/node.hpp" +#include "sensor_msgs/msg/image.hpp" + +#include "image_transport/single_subscriber_publisher.hpp" +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/include/image_transport/raw_publisher.hpp b/image_transport/include/image_transport/raw_publisher.hpp index d00149cf..e52b26b9 100644 --- a/image_transport/include/image_transport/raw_publisher.hpp +++ b/image_transport/include/image_transport/raw_publisher.hpp @@ -29,12 +29,12 @@ #ifndef IMAGE_TRANSPORT__RAW_PUBLISHER_HPP_ #define IMAGE_TRANSPORT__RAW_PUBLISHER_HPP_ -#include +#include -#include -#include +#include "sensor_msgs/msg/image.hpp" -#include +#include "image_transport/simple_publisher_plugin.hpp" +#include "image_transport/visibility_control.hpp" namespace image_transport { diff --git a/image_transport/include/image_transport/raw_subscriber.hpp b/image_transport/include/image_transport/raw_subscriber.hpp index 45b395f4..484db418 100644 --- a/image_transport/include/image_transport/raw_subscriber.hpp +++ b/image_transport/include/image_transport/raw_subscriber.hpp @@ -29,14 +29,14 @@ #ifndef IMAGE_TRANSPORT__RAW_SUBSCRIBER_HPP_ #define IMAGE_TRANSPORT__RAW_SUBSCRIBER_HPP_ -#include - -#include -#include - #include #include +#include "sensor_msgs/msg/image.hpp" + +#include "image_transport/simple_subscriber_plugin.hpp" +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/include/image_transport/simple_publisher_plugin.hpp b/image_transport/include/image_transport/simple_publisher_plugin.hpp index fcfdb687..b1e4fc91 100644 --- a/image_transport/include/image_transport/simple_publisher_plugin.hpp +++ b/image_transport/include/image_transport/simple_publisher_plugin.hpp @@ -29,16 +29,16 @@ #ifndef IMAGE_TRANSPORT__SIMPLE_PUBLISHER_PLUGIN_HPP_ #define IMAGE_TRANSPORT__SIMPLE_PUBLISHER_PLUGIN_HPP_ -#include -#include -#include - -#include -#include - #include #include +#include "rclcpp/node.hpp" +#include "rclcpp/logger.hpp" +#include "rclcpp/logging.hpp" + +#include "image_transport/publisher_plugin.hpp" +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/include/image_transport/simple_subscriber_plugin.hpp b/image_transport/include/image_transport/simple_subscriber_plugin.hpp index a5df05c2..f66b8569 100644 --- a/image_transport/include/image_transport/simple_subscriber_plugin.hpp +++ b/image_transport/include/image_transport/simple_subscriber_plugin.hpp @@ -29,15 +29,15 @@ #ifndef IMAGE_TRANSPORT__SIMPLE_SUBSCRIBER_PLUGIN_HPP_ #define IMAGE_TRANSPORT__SIMPLE_SUBSCRIBER_PLUGIN_HPP_ -#include - -#include -#include - #include #include #include +#include "rclcpp/subscription.hpp" + +#include "image_transport/subscriber_plugin.hpp" +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/include/image_transport/single_subscriber_publisher.hpp b/image_transport/include/image_transport/single_subscriber_publisher.hpp index 11e5e950..e6347db8 100644 --- a/image_transport/include/image_transport/single_subscriber_publisher.hpp +++ b/image_transport/include/image_transport/single_subscriber_publisher.hpp @@ -29,12 +29,12 @@ #ifndef IMAGE_TRANSPORT__SINGLE_SUBSCRIBER_PUBLISHER_HPP_ #define IMAGE_TRANSPORT__SINGLE_SUBSCRIBER_PUBLISHER_HPP_ -#include -#include - #include #include +#include "rclcpp/macros.hpp" +#include "sensor_msgs/msg/image.hpp" + #include "image_transport/visibility_control.hpp" namespace image_transport diff --git a/image_transport/include/image_transport/subscriber.hpp b/image_transport/include/image_transport/subscriber.hpp index 299ebd99..f0b87245 100644 --- a/image_transport/include/image_transport/subscriber.hpp +++ b/image_transport/include/image_transport/subscriber.hpp @@ -29,17 +29,17 @@ #ifndef IMAGE_TRANSPORT__SUBSCRIBER_HPP_ #define IMAGE_TRANSPORT__SUBSCRIBER_HPP_ -#include -#include - -#include -#include -#include - #include #include #include +#include "rclcpp/node.hpp" +#include "sensor_msgs/msg/image.hpp" + +#include "image_transport/exception.hpp" +#include "image_transport/loader_fwds.hpp" +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/include/image_transport/subscriber_filter.hpp b/image_transport/include/image_transport/subscriber_filter.hpp index c7db41f5..37b216ed 100644 --- a/image_transport/include/image_transport/subscriber_filter.hpp +++ b/image_transport/include/image_transport/subscriber_filter.hpp @@ -29,16 +29,16 @@ #ifndef IMAGE_TRANSPORT__SUBSCRIBER_FILTER_HPP_ #define IMAGE_TRANSPORT__SUBSCRIBER_FILTER_HPP_ -#include -#include -#include - -#include -#include - #include #include +#include "rclcpp/rclcpp.hpp" +#include "sensor_msgs/msg/image.hpp" +#include "message_filters/simple_filter.h" + +#include "image_transport/image_transport.hpp" +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/include/image_transport/subscriber_plugin.hpp b/image_transport/include/image_transport/subscriber_plugin.hpp index c814684f..be578847 100644 --- a/image_transport/include/image_transport/subscriber_plugin.hpp +++ b/image_transport/include/image_transport/subscriber_plugin.hpp @@ -29,15 +29,15 @@ #ifndef IMAGE_TRANSPORT__SUBSCRIBER_PLUGIN_HPP_ #define IMAGE_TRANSPORT__SUBSCRIBER_PLUGIN_HPP_ -#include -#include -#include - -#include - #include #include +#include "rclcpp/macros.hpp" +#include "rclcpp/node.hpp" +#include "sensor_msgs/msg/image.hpp" + +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/include/image_transport/transport_hints.hpp b/image_transport/include/image_transport/transport_hints.hpp index 228b6b61..e014d04c 100644 --- a/image_transport/include/image_transport/transport_hints.hpp +++ b/image_transport/include/image_transport/transport_hints.hpp @@ -29,13 +29,13 @@ #ifndef IMAGE_TRANSPORT__TRANSPORT_HINTS_HPP_ #define IMAGE_TRANSPORT__TRANSPORT_HINTS_HPP_ -#include - -#include - #include #include +#include "rclcpp/node.hpp" + +#include "image_transport/visibility_control.hpp" + namespace image_transport { diff --git a/image_transport/src/camera_publisher.cpp b/image_transport/src/camera_publisher.cpp index 89d579a4..422337a4 100644 --- a/image_transport/src/camera_publisher.cpp +++ b/image_transport/src/camera_publisher.cpp @@ -28,16 +28,16 @@ #include "image_transport/camera_publisher.hpp" -#include -#include -#include - -#include -#include - #include #include +#include "rclcpp/expand_topic_or_service_name.hpp" +#include "rclcpp/logging.hpp" +#include "rclcpp/node.hpp" + +#include "image_transport/camera_common.hpp" +#include "image_transport/image_transport.hpp" + namespace image_transport { diff --git a/image_transport/src/camera_subscriber.cpp b/image_transport/src/camera_subscriber.cpp index fee3c85a..f3610ef9 100644 --- a/image_transport/src/camera_subscriber.cpp +++ b/image_transport/src/camera_subscriber.cpp @@ -28,15 +28,15 @@ #include "image_transport/camera_subscriber.hpp" -#include -#include - -#include -#include - #include #include +#include "message_filters/subscriber.h" +#include "message_filters/time_synchronizer.h" + +#include "image_transport/camera_common.hpp" +#include "image_transport/subscriber_filter.hpp" + inline void increment(int * value) { ++(*value); diff --git a/image_transport/src/image_transport.cpp b/image_transport/src/image_transport.cpp index dc952206..7a3b4654 100644 --- a/image_transport/src/image_transport.cpp +++ b/image_transport/src/image_transport.cpp @@ -28,17 +28,17 @@ #include "image_transport/image_transport.hpp" -#include - -#include -#include -#include -#include - #include #include #include +#include "pluginlib/class_loader.hpp" + +#include "image_transport/camera_common.hpp" +#include "image_transport/loader_fwds.hpp" +#include "image_transport/publisher_plugin.hpp" +#include "image_transport/subscriber_plugin.hpp" + namespace image_transport { diff --git a/image_transport/src/list_transports.cpp b/image_transport/src/list_transports.cpp index bac73a91..ac9748ce 100644 --- a/image_transport/src/list_transports.cpp +++ b/image_transport/src/list_transports.cpp @@ -26,15 +26,15 @@ // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE // POSSIBILITY OF SUCH DAMAGE. -#include - -#include -#include -#include - #include #include +#include "pluginlib/class_loader.hpp" + +#include "image_transport/camera_common.hpp" +#include "image_transport/publisher_plugin.hpp" +#include "image_transport/subscriber_plugin.hpp" + enum PluginStatus {SUCCESS, CREATE_FAILURE, LIB_LOAD_FAILURE, DOES_NOT_EXIST}; /// \cond diff --git a/image_transport/src/publisher.cpp b/image_transport/src/publisher.cpp index 414a58db..29782bd0 100644 --- a/image_transport/src/publisher.cpp +++ b/image_transport/src/publisher.cpp @@ -28,21 +28,21 @@ #include "image_transport/publisher.hpp" -#include -#include -#include - -#include - -#include -#include - #include #include #include #include #include +#include "rclcpp/expand_topic_or_service_name.hpp" +#include "rclcpp/logging.hpp" +#include "rclcpp/node.hpp" + +#include "pluginlib/class_loader.hpp" + +#include "image_transport/camera_common.hpp" +#include "image_transport/publisher_plugin.hpp" + namespace image_transport { diff --git a/image_transport/src/republish.cpp b/image_transport/src/republish.cpp index eb7df18a..3913b7ca 100644 --- a/image_transport/src/republish.cpp +++ b/image_transport/src/republish.cpp @@ -26,17 +26,17 @@ // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE // POSSIBILITY OF SUCH DAMAGE. -#include - -#include - -#include -#include - #include #include #include +#include "pluginlib/class_loader.hpp" + +#include "rclcpp/rclcpp.hpp" + +#include "image_transport/image_transport.hpp" +#include "image_transport/publisher_plugin.hpp" + int main(int argc, char ** argv) { auto vargv = rclcpp::init_and_remove_ros_arguments(argc, argv); diff --git a/image_transport/src/single_subscriber_publisher.cpp b/image_transport/src/single_subscriber_publisher.cpp index 9f3d67cf..e6a0f461 100644 --- a/image_transport/src/single_subscriber_publisher.cpp +++ b/image_transport/src/single_subscriber_publisher.cpp @@ -28,11 +28,11 @@ #include "image_transport/single_subscriber_publisher.hpp" -#include +#include -#include +#include "sensor_msgs/msg/image.hpp" -#include +#include "image_transport/publisher.hpp" namespace image_transport { diff --git a/image_transport/src/subscriber.cpp b/image_transport/src/subscriber.cpp index ecd7a1df..85c7927c 100644 --- a/image_transport/src/subscriber.cpp +++ b/image_transport/src/subscriber.cpp @@ -28,18 +28,18 @@ #include "image_transport/subscriber.hpp" -#include -#include +#include +#include +#include -#include +#include "rclcpp/expand_topic_or_service_name.hpp" +#include "rclcpp/logging.hpp" -#include +#include "sensor_msgs/msg/image.hpp" -#include +#include "pluginlib/class_loader.hpp" -#include -#include -#include +#include "image_transport/subscriber_plugin.hpp" namespace image_transport { diff --git a/image_transport/test/test_message_passing.cpp b/image_transport/test/test_message_passing.cpp index c1168de1..0a4372c3 100644 --- a/image_transport/test/test_message_passing.cpp +++ b/image_transport/test/test_message_passing.cpp @@ -26,16 +26,16 @@ // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE // POSSIBILITY OF SUCH DAMAGE. -#include +#include +#include -#include -#include +#include "gtest/gtest.h" -#include -#include +#include "rclcpp/rclcpp.hpp" +#include "rclcpp/node.hpp" -#include -#include +#include "image_transport/image_transport.hpp" +#include "sensor_msgs/msg/image.hpp" #include "utils.hpp" diff --git a/image_transport/test/test_single_subscriber_publisher.cpp b/image_transport/test/test_single_subscriber_publisher.cpp index 0a1af482..f2137d3a 100644 --- a/image_transport/test/test_single_subscriber_publisher.cpp +++ b/image_transport/test/test_single_subscriber_publisher.cpp @@ -26,17 +26,17 @@ // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE // POSSIBILITY OF SUCH DAMAGE. -#include - -#include -#include - -#include - #include #include #include +#include "gtest/gtest.h" + +#include "rclcpp/rclcpp.hpp" +#include "sensor_msgs/msg/image.hpp" + +#include "image_transport/single_subscriber_publisher.hpp" + class TestPublisher : public ::testing::Test { protected: