From dcdb139d2ec6c7d9f3c5e0f75296f7727befe78c Mon Sep 17 00:00:00 2001 From: Esteve Fernandez <33620+esteve@users.noreply.github.com> Date: Thu, 31 Oct 2024 02:27:07 +0100 Subject: [PATCH] refactor(time_utils): prefix package and namespace with autoware (#9173) * refactor(time_utils): prefix package and namespace with autoware Signed-off-by: Esteve Fernandez * refactor(time_utils): prefix package and namespace with autoware Signed-off-by: Esteve Fernandez * style(pre-commit): autofix --------- Signed-off-by: Esteve Fernandez Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- .github/CODEOWNERS | 2 +- .../CMakeLists.txt | 2 +- .../include/autoware}/time_utils/stopwatch.hpp | 12 ++++++------ .../include/autoware}/time_utils/time_utils.hpp | 12 ++++++------ .../autoware}/time_utils/visibility_control.hpp | 6 +++--- .../{time_utils => autoware_time_utils}/package.xml | 2 +- .../src/time_utils/time_utils.cpp | 6 +++--- 7 files changed, 21 insertions(+), 21 deletions(-) rename common/{time_utils => autoware_time_utils}/CMakeLists.txt (87%) rename common/{time_utils/include => autoware_time_utils/include/autoware}/time_utils/stopwatch.hpp (89%) rename common/{time_utils/include => autoware_time_utils/include/autoware}/time_utils/time_utils.hpp (77%) rename common/{time_utils/include => autoware_time_utils/include/autoware}/time_utils/visibility_control.hpp (89%) rename common/{time_utils => autoware_time_utils}/package.xml (96%) rename common/{time_utils => autoware_time_utils}/src/time_utils/time_utils.cpp (91%) diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 929cad046c7a1..1359ca6569056 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -20,6 +20,7 @@ common/autoware_polar_grid/** yukihiro.saito@tier4.jp common/autoware_signal_processing/** ali.boyali@tier4.jp fumiya.watanabe@tier4.jp kyoichi.sugahara@tier4.jp takamasa.horibe@tier4.jp takayuki.murooka@tier4.jp common/autoware_test_utils/** kyoichi.sugahara@tier4.jp mamoru.sobue@tier4.jp takamasa.horibe@tier4.jp zulfaqar.azmi@tier4.jp common/autoware_testing/** adam.dabrowski@robotec.ai satoshi.ota@tier4.jp shumpei.wakabayashi@tier4.jp tomoya.kimura@tier4.jp +common/autoware_time_utils/** christopherj.ho@gmail.com shumpei.wakabayashi@tier4.jp tomoya.kimura@tier4.jp common/autoware_universe_utils/** mamoru.sobue@tier4.jp takamasa.horibe@tier4.jp takayuki.murooka@tier4.jp common/autoware_vehicle_info_utils/** mamoru.sobue@tier4.jp shumpei.wakabayashi@tier4.jp taiki.tanaka@tier4.jp tomoya.kimura@tier4.jp common/bag_time_manager_rviz_plugin/** taiki.tanaka@tier4.jp @@ -38,7 +39,6 @@ common/tier4_state_rviz_plugin/** hiroki.ota@tier4.jp isamu.takagi@tier4.jp khal common/tier4_system_rviz_plugin/** koji.minoda@tier4.jp common/tier4_traffic_light_rviz_plugin/** satoshi.ota@tier4.jp common/tier4_vehicle_rviz_plugin/** yukihiro.saito@tier4.jp -common/time_utils/** christopherj.ho@gmail.com shumpei.wakabayashi@tier4.jp tomoya.kimura@tier4.jp common/traffic_light_recognition_marker_publisher/** shumpei.wakabayashi@tier4.jp takeshi.miura@tier4.jp tomoya.kimura@tier4.jp common/traffic_light_utils/** kotaro.uetake@tier4.jp satoshi.ota@tier4.jp shunsuke.miura@tier4.jp common/tvm_utility/** ambroise.vincent@arm.com xinyu.wang@tier4.jp diff --git a/common/time_utils/CMakeLists.txt b/common/autoware_time_utils/CMakeLists.txt similarity index 87% rename from common/time_utils/CMakeLists.txt rename to common/autoware_time_utils/CMakeLists.txt index 2fc03843a643f..97c6dce02c4a2 100644 --- a/common/time_utils/CMakeLists.txt +++ b/common/autoware_time_utils/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.14) -project(time_utils) +project(autoware_time_utils) find_package(autoware_cmake REQUIRED) autoware_package() diff --git a/common/time_utils/include/time_utils/stopwatch.hpp b/common/autoware_time_utils/include/autoware/time_utils/stopwatch.hpp similarity index 89% rename from common/time_utils/include/time_utils/stopwatch.hpp rename to common/autoware_time_utils/include/autoware/time_utils/stopwatch.hpp index 223e7ab700ac4..b2e5942434411 100644 --- a/common/time_utils/include/time_utils/stopwatch.hpp +++ b/common/autoware_time_utils/include/autoware/time_utils/stopwatch.hpp @@ -14,10 +14,10 @@ // // Co-developed by Tier IV, Inc. and Apex.AI, Inc. -#ifndef TIME_UTILS__STOPWATCH_HPP_ -#define TIME_UTILS__STOPWATCH_HPP_ +#ifndef AUTOWARE__TIME_UTILS__STOPWATCH_HPP_ +#define AUTOWARE__TIME_UTILS__STOPWATCH_HPP_ -#include +#include #include #include @@ -26,7 +26,7 @@ namespace autoware { namespace common { -namespace time_utils +namespace autoware::time_utils { namespace detail @@ -81,8 +81,8 @@ class TIME_UTILS_PUBLIC Stopwatch TimePoint m_start{Clock::now()}; }; -} // namespace time_utils +} // namespace autoware::time_utils } // namespace common } // namespace autoware -#endif // TIME_UTILS__STOPWATCH_HPP_ +#endif // AUTOWARE__TIME_UTILS__STOPWATCH_HPP_ diff --git a/common/time_utils/include/time_utils/time_utils.hpp b/common/autoware_time_utils/include/autoware/time_utils/time_utils.hpp similarity index 77% rename from common/time_utils/include/time_utils/time_utils.hpp rename to common/autoware_time_utils/include/autoware/time_utils/time_utils.hpp index cb369b4874872..450380680e202 100644 --- a/common/time_utils/include/time_utils/time_utils.hpp +++ b/common/autoware_time_utils/include/autoware/time_utils/time_utils.hpp @@ -13,20 +13,20 @@ // limitations under the License. // // Co-developed by Tier IV, Inc. and Apex.AI, Inc. -#ifndef TIME_UTILS__TIME_UTILS_HPP_ -#define TIME_UTILS__TIME_UTILS_HPP_ +#ifndef AUTOWARE__TIME_UTILS__TIME_UTILS_HPP_ +#define AUTOWARE__TIME_UTILS__TIME_UTILS_HPP_ +#include #include #include -#include #include -namespace time_utils +namespace autoware::time_utils { /// Standard interpolation TIME_UTILS_PUBLIC std::chrono::nanoseconds interpolate( std::chrono::nanoseconds a, std::chrono::nanoseconds b, float t) noexcept; -} // namespace time_utils +} // namespace autoware::time_utils -#endif // TIME_UTILS__TIME_UTILS_HPP_ +#endif // AUTOWARE__TIME_UTILS__TIME_UTILS_HPP_ diff --git a/common/time_utils/include/time_utils/visibility_control.hpp b/common/autoware_time_utils/include/autoware/time_utils/visibility_control.hpp similarity index 89% rename from common/time_utils/include/time_utils/visibility_control.hpp rename to common/autoware_time_utils/include/autoware/time_utils/visibility_control.hpp index ca9423d8df9ab..ebf444422ba91 100644 --- a/common/time_utils/include/time_utils/visibility_control.hpp +++ b/common/autoware_time_utils/include/autoware/time_utils/visibility_control.hpp @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -#ifndef TIME_UTILS__VISIBILITY_CONTROL_HPP_ -#define TIME_UTILS__VISIBILITY_CONTROL_HPP_ +#ifndef AUTOWARE__TIME_UTILS__VISIBILITY_CONTROL_HPP_ +#define AUTOWARE__TIME_UTILS__VISIBILITY_CONTROL_HPP_ #if defined(__WIN32) #if defined(TIME_UTILS_BUILDING_DLL) || defined(TIME_UTILS_EXPORTS) @@ -33,4 +33,4 @@ #error "Unsupported Build Configuration" #endif // defined(_WINDOWS) -#endif // TIME_UTILS__VISIBILITY_CONTROL_HPP_ +#endif // AUTOWARE__TIME_UTILS__VISIBILITY_CONTROL_HPP_ diff --git a/common/time_utils/package.xml b/common/autoware_time_utils/package.xml similarity index 96% rename from common/time_utils/package.xml rename to common/autoware_time_utils/package.xml index c4ad8f098a0e0..15a8699d6d65b 100644 --- a/common/time_utils/package.xml +++ b/common/autoware_time_utils/package.xml @@ -1,7 +1,7 @@ - time_utils + autoware_time_utils 1.0.0 Simple conversion methods to/from std::chrono to simplify algorithm development Christopher Ho diff --git a/common/time_utils/src/time_utils/time_utils.cpp b/common/autoware_time_utils/src/time_utils/time_utils.cpp similarity index 91% rename from common/time_utils/src/time_utils/time_utils.cpp rename to common/autoware_time_utils/src/time_utils/time_utils.cpp index fa1516c4bfef0..9801dbb762ab7 100644 --- a/common/time_utils/src/time_utils/time_utils.cpp +++ b/common/autoware_time_utils/src/time_utils/time_utils.cpp @@ -11,13 +11,13 @@ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -#include "time_utils/time_utils.hpp" +#include "autoware/time_utils/time_utils.hpp" #include #include #include -namespace time_utils +namespace autoware::time_utils { //////////////////////////////////////////////////////////////////////////////// std::chrono::nanoseconds interpolate( @@ -30,4 +30,4 @@ std::chrono::nanoseconds interpolate( return a + del_; } -} // namespace time_utils +} // namespace autoware::time_utils