From 3e1ff3cde692f216ddfb89f6e6ceddd340175f7b Mon Sep 17 00:00:00 2001 From: Alejandro Hernandez Cordero Date: Wed, 5 Mar 2025 14:42:05 +0100 Subject: [PATCH 1/6] Added rmw_event_check_compatible Signed-off-by: Alejandro Hernandez Cordero --- rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp index 13163579d..e0fbf0dbe 100644 --- a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp @@ -61,4 +61,10 @@ rmw_event_set_callback( callback, user_data); } + +bool rmw_event_check_compatible(rmw_event_type_t rmw_event_type) +{ + return rmw_fastrtps_shared_cpp::internal::is_event_supported(rmw_event_type); +} + } // extern "C" From e8c79a6549828781528803dc3b2db0b88695b01b Mon Sep 17 00:00:00 2001 From: Alejandro Hernandez Cordero Date: Wed, 5 Mar 2025 15:59:21 +0100 Subject: [PATCH 2/6] Fixed build Signed-off-by: Alejandro Hernandez Cordero --- rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp | 6 ------ rmw_fastrtps_shared_cpp/src/rmw_event.cpp | 5 +++++ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp index e0fbf0dbe..13163579d 100644 --- a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp @@ -61,10 +61,4 @@ rmw_event_set_callback( callback, user_data); } - -bool rmw_event_check_compatible(rmw_event_type_t rmw_event_type) -{ - return rmw_fastrtps_shared_cpp::internal::is_event_supported(rmw_event_type); -} - } // extern "C" diff --git a/rmw_fastrtps_shared_cpp/src/rmw_event.cpp b/rmw_fastrtps_shared_cpp/src/rmw_event.cpp index 0aa43a473..33270ec49 100644 --- a/rmw_fastrtps_shared_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_shared_cpp/src/rmw_event.cpp @@ -164,4 +164,9 @@ __rmw_event_set_callback( return RMW_RET_OK; } +bool rmw_event_check_compatible(rmw_event_type_t rmw_event_type) +{ + return rmw_fastrtps_shared_cpp::internal::is_event_supported(rmw_event_type); +} + } // namespace rmw_fastrtps_shared_cpp From 62495018352fc045c28548aab25903131db11500 Mon Sep 17 00:00:00 2001 From: Alejandro Hernandez Cordero Date: Wed, 5 Mar 2025 16:29:42 +0100 Subject: [PATCH 3/6] included review feedback Signed-off-by: Alejandro Hernandez Cordero --- rmw_fastrtps_cpp/src/rmw_event.cpp | 6 ++++++ rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp | 7 +++++++ .../include/rmw_fastrtps_shared_cpp/rmw_common.hpp | 4 ++++ rmw_fastrtps_shared_cpp/src/rmw_event.cpp | 3 ++- 4 files changed, 19 insertions(+), 1 deletion(-) diff --git a/rmw_fastrtps_cpp/src/rmw_event.cpp b/rmw_fastrtps_cpp/src/rmw_event.cpp index 56d8779e2..1a82620eb 100644 --- a/rmw_fastrtps_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_cpp/src/rmw_event.cpp @@ -61,4 +61,10 @@ rmw_event_set_callback( callback, user_data); } + +bool +rmw_event_check_compatible(rmw_event_type_t rmw_event_type) +{ + return rmw_fastrtps_shared_cpp::__rmw_event_check_compatible(rmw_event_type); +} } // extern "C" diff --git a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp index 13163579d..b08714e87 100644 --- a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp @@ -61,4 +61,11 @@ rmw_event_set_callback( callback, user_data); } + +bool +rmw_event_check_compatible(rmw_event_type_t rmw_event_type) +{ + return rmw_fastrtps_shared_cpp::__rmw_event_check_compatible(rmw_event_type); +} + } // extern "C" diff --git a/rmw_fastrtps_shared_cpp/include/rmw_fastrtps_shared_cpp/rmw_common.hpp b/rmw_fastrtps_shared_cpp/include/rmw_fastrtps_shared_cpp/rmw_common.hpp index 1b4f73bc3..433333eb4 100644 --- a/rmw_fastrtps_shared_cpp/include/rmw_fastrtps_shared_cpp/rmw_common.hpp +++ b/rmw_fastrtps_shared_cpp/include/rmw_fastrtps_shared_cpp/rmw_common.hpp @@ -578,6 +578,10 @@ RMW_FASTRTPS_SHARED_CPP_PUBLIC bool __rmw_feature_supported(rmw_feature_t feature); +RMW_FASTRTPS_SHARED_CPP_PUBLIC +bool +__rmw_event_check_compatible(rmw_event_type_t rmw_event_type); + } // namespace rmw_fastrtps_shared_cpp #endif // RMW_FASTRTPS_SHARED_CPP__RMW_COMMON_HPP_ diff --git a/rmw_fastrtps_shared_cpp/src/rmw_event.cpp b/rmw_fastrtps_shared_cpp/src/rmw_event.cpp index 33270ec49..5183bba02 100644 --- a/rmw_fastrtps_shared_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_shared_cpp/src/rmw_event.cpp @@ -164,7 +164,8 @@ __rmw_event_set_callback( return RMW_RET_OK; } -bool rmw_event_check_compatible(rmw_event_type_t rmw_event_type) +bool +__rmw_event_check_compatible(rmw_event_type_t rmw_event_type) { return rmw_fastrtps_shared_cpp::internal::is_event_supported(rmw_event_type); } From 037d718f4cff53e87c045c72c2e50fbce031cef4 Mon Sep 17 00:00:00 2001 From: Alejandro Hernandez Cordero Date: Thu, 6 Mar 2025 10:20:47 +0100 Subject: [PATCH 4/6] review feedback Signed-off-by: Alejandro Hernandez Cordero --- rmw_fastrtps_cpp/src/rmw_event.cpp | 4 ++-- rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp | 4 ++-- .../include/rmw_fastrtps_shared_cpp/rmw_common.hpp | 2 +- rmw_fastrtps_shared_cpp/src/rmw_event.cpp | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/rmw_fastrtps_cpp/src/rmw_event.cpp b/rmw_fastrtps_cpp/src/rmw_event.cpp index 1a82620eb..dc8ced7be 100644 --- a/rmw_fastrtps_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_cpp/src/rmw_event.cpp @@ -63,8 +63,8 @@ rmw_event_set_callback( } bool -rmw_event_check_compatible(rmw_event_type_t rmw_event_type) +rmw_event_type_is_supported(rmw_event_type_t rmw_event_type) { - return rmw_fastrtps_shared_cpp::__rmw_event_check_compatible(rmw_event_type); + return rmw_fastrtps_shared_cpp::__rmw_event_type_is_supported(rmw_event_type); } } // extern "C" diff --git a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp index b08714e87..dcf374c32 100644 --- a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp @@ -63,9 +63,9 @@ rmw_event_set_callback( } bool -rmw_event_check_compatible(rmw_event_type_t rmw_event_type) +rmw_event_type_is_supported(rmw_event_type_t rmw_event_type) { - return rmw_fastrtps_shared_cpp::__rmw_event_check_compatible(rmw_event_type); + return rmw_fastrtps_shared_cpp::__rmw_event_type_is_supported(rmw_event_type); } } // extern "C" diff --git a/rmw_fastrtps_shared_cpp/include/rmw_fastrtps_shared_cpp/rmw_common.hpp b/rmw_fastrtps_shared_cpp/include/rmw_fastrtps_shared_cpp/rmw_common.hpp index 433333eb4..98ebf7d3d 100644 --- a/rmw_fastrtps_shared_cpp/include/rmw_fastrtps_shared_cpp/rmw_common.hpp +++ b/rmw_fastrtps_shared_cpp/include/rmw_fastrtps_shared_cpp/rmw_common.hpp @@ -580,7 +580,7 @@ __rmw_feature_supported(rmw_feature_t feature); RMW_FASTRTPS_SHARED_CPP_PUBLIC bool -__rmw_event_check_compatible(rmw_event_type_t rmw_event_type); +__rmw_event_type_is_supported(rmw_event_type_t rmw_event_type); } // namespace rmw_fastrtps_shared_cpp diff --git a/rmw_fastrtps_shared_cpp/src/rmw_event.cpp b/rmw_fastrtps_shared_cpp/src/rmw_event.cpp index 5183bba02..2985d1359 100644 --- a/rmw_fastrtps_shared_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_shared_cpp/src/rmw_event.cpp @@ -165,7 +165,7 @@ __rmw_event_set_callback( } bool -__rmw_event_check_compatible(rmw_event_type_t rmw_event_type) +__rmw_event_type_is_supported(rmw_event_type_t rmw_event_type) { return rmw_fastrtps_shared_cpp::internal::is_event_supported(rmw_event_type); } From 94658905af69d2808fb8db2ed11760adc3cdba21 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alejandro=20Hern=C3=A1ndez=20Cordero?= Date: Thu, 6 Mar 2025 10:27:40 +0100 Subject: [PATCH 5/6] Update rmw_fastrtps_cpp/src/rmw_event.cpp MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Miguel Company Signed-off-by: Alejandro Hernández Cordero --- rmw_fastrtps_cpp/src/rmw_event.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/rmw_fastrtps_cpp/src/rmw_event.cpp b/rmw_fastrtps_cpp/src/rmw_event.cpp index dc8ced7be..c38b9dc44 100644 --- a/rmw_fastrtps_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_cpp/src/rmw_event.cpp @@ -67,4 +67,5 @@ rmw_event_type_is_supported(rmw_event_type_t rmw_event_type) { return rmw_fastrtps_shared_cpp::__rmw_event_type_is_supported(rmw_event_type); } + } // extern "C" From af087595adcc35a14a6e1859cb5ab2f3555d7dbe Mon Sep 17 00:00:00 2001 From: Alejandro Hernandez Cordero Date: Fri, 7 Mar 2025 22:25:36 +0100 Subject: [PATCH 6/6] make linters happy Signed-off-by: Alejandro Hernandez Cordero --- rmw_fastrtps_cpp/src/rmw_event.cpp | 1 - rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp | 1 - 2 files changed, 2 deletions(-) diff --git a/rmw_fastrtps_cpp/src/rmw_event.cpp b/rmw_fastrtps_cpp/src/rmw_event.cpp index c38b9dc44..dc8ced7be 100644 --- a/rmw_fastrtps_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_cpp/src/rmw_event.cpp @@ -67,5 +67,4 @@ rmw_event_type_is_supported(rmw_event_type_t rmw_event_type) { return rmw_fastrtps_shared_cpp::__rmw_event_type_is_supported(rmw_event_type); } - } // extern "C" diff --git a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp index dcf374c32..cdb61ea8b 100644 --- a/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp +++ b/rmw_fastrtps_dynamic_cpp/src/rmw_event.cpp @@ -67,5 +67,4 @@ rmw_event_type_is_supported(rmw_event_type_t rmw_event_type) { return rmw_fastrtps_shared_cpp::__rmw_event_type_is_supported(rmw_event_type); } - } // extern "C"