diff --git a/urdf/src/model.cpp b/urdf/src/model.cpp index 0edf2564..0817ea15 100644 --- a/urdf/src/model.cpp +++ b/urdf/src/model.cpp @@ -35,8 +35,6 @@ /* Author: Wim Meeussen */ #include "urdf/model.h" -#include -#include #include #include @@ -46,6 +44,9 @@ #include #include +#include "urdf_parser_plugin/parser.h" +#include "pluginlib/class_loader.hpp" + // Windows has preprocessor defines for "max", which conflicts with // several things (one of them being std::numeric_limits::max()). Since // we know we aren't going to use that macros, and this is a cpp (not header diff --git a/urdf_parser_plugin/CMakeLists.txt b/urdf_parser_plugin/CMakeLists.txt index a4400e37..06a956af 100644 --- a/urdf_parser_plugin/CMakeLists.txt +++ b/urdf_parser_plugin/CMakeLists.txt @@ -12,6 +12,14 @@ target_include_directories(urdf_parser_plugin INTERFACE ament_target_dependencies(urdf_parser_plugin INTERFACE "urdfdom_headers" ) + +if(BUILD_TESTING) + find_package(ament_lint_auto REQUIRED) + set(ament_cmake_cppcheck_LANGUAGE "c++") + set(ament_cmake_uncrustify_ADDITIONAL_ARGS LANGUAGE "C++") + ament_lint_auto_find_test_dependencies() +endif() + install(TARGETS urdf_parser_plugin EXPORT urdf_parser_plugin-export) ament_export_targets(urdf_parser_plugin-export) ament_export_dependencies(urdfdom_headers) diff --git a/urdf_parser_plugin/include/urdf_parser_plugin/parser.h b/urdf_parser_plugin/include/urdf_parser_plugin/parser.h index abde3c42..f7b8d2db 100644 --- a/urdf_parser_plugin/include/urdf_parser_plugin/parser.h +++ b/urdf_parser_plugin/include/urdf_parser_plugin/parser.h @@ -1,46 +1,40 @@ -/********************************************************************* -* Software License Agreement (BSD License) -* -* Copyright (c) 2013, Willow Garage, Inc. -* All rights reserved. -* -* Redistribution and use in source and binary forms, with or without -* modification, are permitted provided that the following conditions -* are met: -* -* * Redistributions of source code must retain the above copyright -* notice, this list of conditions and the following disclaimer. -* * Redistributions in binary form must reproduce the above -* copyright notice, this list of conditions and the following -* disclaimer in the documentation and/or other materials provided -* with the distribution. -* * Neither the name of the Willow Garage nor the names of its -* contributors may be used to endorse or promote products derived -* from this software without specific prior written permission. -* -* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS -* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE -* COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, -* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN -* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -* POSSIBILITY OF SUCH DAMAGE. -*********************************************************************/ +// Copyright (c) 2013, Willow Garage, Inc. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// +// * Redistributions in binary form must reproduce the above copyright +// notice, this list of conditions and the following disclaimer in the +// documentation and/or other materials provided with the distribution. +// +// * Neither the name of the Willow Garage nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +// ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE +// LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +// POSSIBILITY OF SUCH DAMAGE. /* Author: Ioan Sucan */ -#ifndef URDF_PARSER_PLUGIN_H -#define URDF_PARSER_PLUGIN_H - -#include +#ifndef URDF_PARSER_PLUGIN__PARSER_H_ +#define URDF_PARSER_PLUGIN__PARSER_H_ #include +#include "urdf_world/types.h" + namespace urdf { @@ -70,7 +64,7 @@ class URDFParser /// return a value greater than or equal to data.size(). virtual size_t might_handle(const std::string & data) = 0; }; - -} -#endif +} // namespace urdf + +#endif // URDF_PARSER_PLUGIN__PARSER_H_ diff --git a/urdf_parser_plugin/package.xml b/urdf_parser_plugin/package.xml index cc6a5571..8db2d91e 100644 --- a/urdf_parser_plugin/package.xml +++ b/urdf_parser_plugin/package.xml @@ -21,6 +21,9 @@ urdfdom_headers urdfdom_headers + ament_lint_auto + ament_lint_common + ament_cmake