From cd38f194c3b455ad378f295ebc87a31e36816351 Mon Sep 17 00:00:00 2001 From: ISP akm Date: Tue, 16 Apr 2024 15:22:13 +0900 Subject: [PATCH] Correction by review. Signed-off-by: ISP akm --- .../caret_trace/tracing_controller.hpp | 20 +++++++++---------- CARET_trace/src/tracing_controller.cpp | 20 +++++++++---------- 2 files changed, 20 insertions(+), 20 deletions(-) diff --git a/CARET_trace/include/caret_trace/tracing_controller.hpp b/CARET_trace/include/caret_trace/tracing_controller.hpp index fee6a686..d9df666e 100644 --- a/CARET_trace/include/caret_trace/tracing_controller.hpp +++ b/CARET_trace/include/caret_trace/tracing_controller.hpp @@ -144,33 +144,33 @@ class TracingController /// @return True if the process is enabled, false otherwise. bool is_allowed_process(); - /// @brief Check if trace point is a enabled node + /// @brief Check if trace point is a enabled timer handle /// @param timer_handle Address of the timer handle. /// @return True if the timer_handle is enabled, false otherwise. bool is_allowed_timer_handle(const void * timer_handle); - /// @brief Check if trace point is a enabled node + /// @brief Check if trace point is a enabled state machine /// @param state_machine Address of the lifecycle state machine. /// @return True if the state_machine is enabled, false otherwise. bool is_allowed_state_machine(const void * state_machine); - /// @brief Check if trace point is a enabled subscription + /// @brief Check if trace point is a enabled ipb /// @param buffer Address of the intra-process buffer. - /// @return True if the buffer is enabled, false otherwise. + /// @return True if the ipb is enabled, false otherwise. bool is_allowed_ipb(const void * ipb); - /// @brief Check if trace point is a enabled callback + /// @brief Check if trace point is a enabled service handle /// @param service_handle Address of the service handle. - /// @return True if the buffer is enabled, false otherwise. + /// @return True if the service_handle is enabled, false otherwise. bool is_allowed_service_handle(const void * service_handle); - /// @brief Check if trace point is a enabled callback + /// @brief Check if trace point is a enabled client handle /// @param client_handle Address of the client handle. - /// @return True if the buffer is enabled, false otherwise. + /// @return True if the client_handle is enabled, false otherwise. bool is_allowed_client_handle(const void * client_handle); - /// @brief Check if trace point is a enabled message - /// @param publisher_handle Address of the publisher handle. + /// @brief Check if trace point is a enabled publisher + /// @param message Address of the message. /// @return True if the message is enabled, false otherwise. bool is_allowed_message(const void * message); diff --git a/CARET_trace/src/tracing_controller.cpp b/CARET_trace/src/tracing_controller.cpp index caa640b6..45ebc1dc 100644 --- a/CARET_trace/src/tracing_controller.cpp +++ b/CARET_trace/src/tracing_controller.cpp @@ -628,8 +628,8 @@ bool TracingController::is_allowed_service_handle(const void * service_handle) std::unordered_map::iterator is_allowed_it; { std::shared_lock lock(mutex_); - is_allowed_it = allowed_service_handle_.find(service_handle); - if (is_allowed_it != allowed_service_handle_.end()) { + is_allowed_it = allowed_service_handles_.find(service_handle); + if (is_allowed_it != allowed_service_handles_.end()) { return is_allowed_it->second; } } @@ -640,7 +640,7 @@ bool TracingController::is_allowed_service_handle(const void * service_handle) auto node_name = node_handle_to_node_names_[node_handle]; if (node_name.size() == 0) { - allowed_service_handle_[service_handle] = true; + allowed_service_handles_[service_handle] = true; return true; } @@ -648,22 +648,22 @@ bool TracingController::is_allowed_service_handle(const void * service_handle) auto is_selected_node = partial_match(selected_node_names_, node_name); if (is_selected_node && selected_node_names_.size() > 0) { - allowed_service_handle_[service_handle] = true; + allowed_service_handles_[service_handle] = true; return true; } - allowed_service_handle_[service_handle] = false; + allowed_service_handles_[service_handle] = false; return false; } else if (ignore_enabled_) { auto is_ignored_node = partial_match(ignored_node_names_, node_name); if (is_ignored_node && ignored_node_names_.size() > 0) { - allowed_service_handle_[service_handle] = false; + allowed_service_handles_[service_handle] = false; return false; } - allowed_service_handle_[service_handle] = true; + allowed_service_handles_[service_handle] = true; return true; } - allowed_service_handle_[service_handle] = true; + allowed_service_handles_[service_handle] = true; return true; } } @@ -855,7 +855,7 @@ void TracingController::add_node(const void * node_handle, std::string node_name allowed_timer_handles_.clear(); allowed_state_machines_.clear(); allowed_ipbs_.clear(); - allowed_service_handle_.clear(); + allowed_service_handles_.clear(); allowed_client_handles_.clear(); allowed_callbacks_.clear(); } @@ -958,7 +958,7 @@ void TracingController::add_service_handle(const void * service_handle, const vo { std::lock_guard lock(mutex_); service_handle_to_node_handles_[service_handle] = node_handle; - allowed_service_handle_.erase(service_handle); + allowed_service_handles_.erase(service_handle); } void TracingController::add_client_handle(const void * client_handle, const void * node_handle)