[PROJECT] Refactoring entering logs into ScopeLogger 31/159031/2
authorSzymon Jastrzebski <s.jastrzebsk@partner.samsung.com>
Mon, 6 Nov 2017 13:02:09 +0000 (14:02 +0100)
committerSzymon Jastrzebski <s.jastrzebsk@partner.samsung.com>
Mon, 6 Nov 2017 13:02:09 +0000 (14:02 +0100)
[Verification] Code compiles

Change-Id: I2733b7a7bcafa50f5a6a87195ec9efbcec97c574
Signed-off-by: Szymon Jastrzebski <s.jastrzebsk@partner.samsung.com>
13 files changed:
src/alarm/alarm_manager.cc
src/alarm/alarm_utils.cc
src/application/application_instance.cc
src/application/application_manager.cc
src/datacontrol/datacontrol_instance.cc
src/humanactivitymonitor/humanactivitymonitor_instance.cc
src/nfc/nfc_adapter.cc
src/nfc/nfc_instance.cc
src/notification/common_notification.cc
src/notification/notification_instance.cc
src/notification/notification_manager.cc
src/notification/status_notification.cc
src/notification/user_notification.cc

index 09a5b2a0dab6fd3e52b2248e024d076824bfd7dd..8ca564bc37dfd973595837f02230f6a4628d380d 100644 (file)
@@ -247,7 +247,7 @@ void AlarmManager::Add(const picojson::value& args, picojson::object& out) {
 
 void AlarmManager::AddAlarmNotification(const picojson::value& args, picojson::object& out) {
   using namespace extension::notification;
-  LoggerD("Entered");
+  ScopeLogger();
   CHECK_PRIVILEGE_ACCESS(kPrivilegeAlarm, &out);
   CHECK_PRIVILEGE_ACCESS(kPrivilegeNotification, &out);
 
@@ -666,7 +666,7 @@ void AlarmManager::Get(const picojson::value& args, picojson::object& out) {
 
 void AlarmManager::GetAlarmNotification(const picojson::value& args, picojson::object& out) {
   using namespace extension::notification;
-  LoggerD("Entered");
+  ScopeLogger();
 
   int alarm_id = 0;
   int ret = ALARM_ERROR_NONE;
index b51fa6339b1445ed1f63d09a12e5950554bd5146..31e1862e1fe3a46bd3a346f4d670b358b0d83995 100644 (file)
@@ -153,7 +153,7 @@ PlatformResult AppControlToServiceExtraData(const picojson::object& app_obj,
 }
 
 PlatformResult ArrayDaysToMask(const picojson::array& days_of_the_week, int* repeat_value) {
-  LoggerD("Entered");
+  ScopeLogger();
   for (auto iter = days_of_the_week.begin(); iter != days_of_the_week.end(); ++iter) {
     auto day = (*iter).get<std::string>();
     if (kSundayShort == day) {
index ec77dc85ce70b0598d8daec4e0ac44e2a27d1a44..00d98d6e4ad914337d4ae0d4a85641d15ed29a8c 100644 (file)
@@ -164,14 +164,14 @@ void ApplicationInstance::GetAppMetaData(const picojson::value& args, picojson::
 }
 
 void ApplicationInstance::GetBatteryUsageInfo(const picojson::value& args, picojson::object& out) {
-  LoggerD("Entered");
+  ScopeLogger();
   CHECK_PRIVILEGE_ACCESS(kPrivilegeAppHistoryRead, &out);
 
   manager_.GetBatteryUsageInfo(args, &out);
 }
 
 void ApplicationInstance::GetAppsUsageInfo(const picojson::value& args, picojson::object& out) {
-  LoggerD("Entered");
+  ScopeLogger();
   CHECK_PRIVILEGE_ACCESS(kPrivilegeAppHistoryRead, &out);
 
   manager_.GetAppsUsageInfo(args, &out);
@@ -316,7 +316,7 @@ void ApplicationInstance::RemoveEventListener(const picojson::value& args, picoj
 }
 
 void ApplicationInstance::AddStatusListener(const picojson::value& args, picojson::object& out) {
-  LoggerD("Entered");
+  ScopeLogger();
 
   JsonCallback cb = [this](picojson::value* event) -> void {
     Instance::PostMessage(this, event->serialize().c_str());
@@ -331,7 +331,7 @@ void ApplicationInstance::AddStatusListener(const picojson::value& args, picojso
 }
 
 void ApplicationInstance::RemoveStatusListener(const picojson::value& args, picojson::object& out) {
-  LoggerD("Entered");
+  ScopeLogger();
 
   PlatformResult result = manager_.StopStatusChangeListener();
   if (result) {
index df798f100c487767a9ed377d5e2a80e231802da5..9d67ef786b80fe0fff1d8b57575d84af31f4ee37 100644 (file)
@@ -1190,7 +1190,7 @@ void ApplicationManager::GetAppSharedUri(const std::string& app_id, picojson::ob
 PlatformResult ApplicationManager::BatteryUsageFilter(const picojson::value& args,
                                                       const context_history_filter_h filter,
                                                       context_history_data_e* data_type_out) {
-  LoggerD("Entered");
+  ScopeLogger();
   int ret = CONTEXT_HISTORY_ERROR_NONE;
   int limit = kMaximumBatteryRetrievedObjects;
   if (args.contains("limit")) {
@@ -1226,7 +1226,7 @@ PlatformResult ApplicationManager::BatteryUsageFilter(const picojson::value& arg
 
 PlatformResult ApplicationManager::BatteryUsageAttributes(const context_history_record_h record,
                                                           picojson::object* object) {
-  LoggerD("Entered");
+  ScopeLogger();
 
   int ret = CONTEXT_HISTORY_ERROR_NONE;
   double amount = 0.0;
@@ -1256,7 +1256,7 @@ PlatformResult ApplicationManager::BatteryUsageAttributes(const context_history_
 PlatformResult ApplicationManager::AppsUsageFilter(const picojson::value& args,
                                                    const context_history_filter_h filter,
                                                    context_history_data_e* data_type_out) {
-  LoggerD("Entered");
+  ScopeLogger();
   int ret = CONTEXT_HISTORY_ERROR_NONE;
   int limit = kMaximumAppsRetrievedObjects;
   if (args.contains("limit")) {
@@ -1325,7 +1325,7 @@ PlatformResult ApplicationManager::AppsUsageFilter(const picojson::value& args,
 
 PlatformResult ApplicationManager::AppsUsageAttributes(const context_history_record_h record,
                                                        picojson::object* object) {
-  LoggerD("Entered");
+  ScopeLogger();
 
   int ret = CONTEXT_HISTORY_ERROR_NONE;
   int total_count = 0;
@@ -1372,7 +1372,7 @@ PlatformResult ApplicationManager::AppsUsageAttributes(const context_history_rec
 #endif
 
 void ApplicationManager::GetBatteryUsageInfo(const picojson::value& args, picojson::object* out) {
-  LoggerD("Entered");
+  ScopeLogger();
 
 #if defined(TIZEN_MOBILE) || defined(TIZEN_WEARABLE)
   int callback_id = -1;
@@ -1382,7 +1382,7 @@ void ApplicationManager::GetBatteryUsageInfo(const picojson::value& args, picojs
   }
 
   auto get_battery_usage = [args](const std::shared_ptr<picojson::value>& response) -> void {
-    LoggerD("Entered");
+    ScopeLogger();
     PlatformResult result = ApplicationManager::GetContextHistory(
         args, &response.get()->get<picojson::object>(), &ApplicationManager::BatteryUsageFilter,
         &ApplicationManager::BatteryUsageAttributes);
@@ -1393,7 +1393,7 @@ void ApplicationManager::GetBatteryUsageInfo(const picojson::value& args, picojs
 
   auto get_battery_usage_response =
       [this, callback_id](const std::shared_ptr<picojson::value>& response) -> void {
-    LoggerD("Entered");
+    ScopeLogger();
     picojson::object& obj = response->get<picojson::object>();
     obj.insert(std::make_pair(kCallbackId, picojson::value(static_cast<double>(callback_id))));
     Instance::PostMessage(&this->instance_, response->serialize().c_str());
@@ -1413,13 +1413,13 @@ void ApplicationManager::GetBatteryUsageInfo(const picojson::value& args, picojs
 }
 
 void ApplicationManager::GetAppsUsageInfo(const picojson::value& args, picojson::object* out) {
-  LoggerD("Entered");
+  ScopeLogger();
 
 #if defined(TIZEN_MOBILE) || defined(TIZEN_WEARABLE)
   int callback_id = static_cast<int>(args.get(kCallbackId).get<double>());
 
   auto get_apps_usage = [args](const std::shared_ptr<picojson::value>& response) -> void {
-    LoggerD("Entered");
+    ScopeLogger();
     PlatformResult result = ApplicationManager::GetContextHistory(
         args, &response.get()->get<picojson::object>(), &ApplicationManager::AppsUsageFilter,
         &ApplicationManager::AppsUsageAttributes);
@@ -1430,7 +1430,7 @@ void ApplicationManager::GetAppsUsageInfo(const picojson::value& args, picojson:
 
   auto get_apps_usage_response =
       [this, callback_id](const std::shared_ptr<picojson::value>& response) -> void {
-    LoggerD("Entered");
+    ScopeLogger();
     picojson::object& obj = response->get<picojson::object>();
     obj.insert(std::make_pair(kCallbackId, picojson::value(static_cast<double>(callback_id))));
     Instance::PostMessage(&this->instance_, response->serialize().c_str());
@@ -1929,7 +1929,7 @@ void ApplicationManager::OnStatusEvent(const char* type, const char* app_id,
                                        app_manager_event_type_e event_type,
                                        app_manager_event_state_e event_state,
                                        app_manager_event_h handle, void* user_data) {
-  LoggerD("Entered");
+  ScopeLogger();
 
   if (APP_MANAGER_EVENT_STATE_COMPLETED != event_state) {
     LoggerD("State different from completed");
@@ -1974,7 +1974,7 @@ PlatformResult ApplicationManager::GetContextHistory(
                                                context_history_data_e* data_type),
     common::PlatformResult (*add_attributes_to_object)(const context_history_record_h,
                                                        picojson::object*)) {
-  LoggerD("Entered");
+  ScopeLogger();
   context_history_list_h list = nullptr;
   context_history_h handle = nullptr;
   context_history_filter_h filter = nullptr;
@@ -2058,7 +2058,7 @@ PlatformResult ApplicationManager::GetContextHistory(
 #endif
 
 PlatformResult ApplicationManager::StartStatusListener(const JsonCallback& callback) {
-  LoggerD("Entered");
+  ScopeLogger();
 
   int ret = APP_MANAGER_ERROR_NONE;
 
@@ -2087,7 +2087,7 @@ PlatformResult ApplicationManager::StartStatusListener(const JsonCallback& callb
 }
 
 PlatformResult ApplicationManager::StopStatusChangeListener() {
-  LoggerD("Entered");
+  ScopeLogger();
 
   if (app_status_handle_) {
     int ret = app_manager_unset_event_cb(app_status_handle_);
index c0cd6a81ad2695237c5d3e99704138c44b24a1a1..0c6ff0ab59d5339e0c1e031ec7773aaa8d5b3759 100644 (file)
@@ -900,7 +900,7 @@ void DatacontrolInstance::MappedDataControlConsumerUpdatevalue(const picojson::v
 
 int DatacontrolInstance::CreateMAPHandle(const std::string& providerId, const std::string& dataId,
                                          data_control_h* handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   int result = DATA_CONTROL_ERROR_NONE;
 
   result = ::data_control_map_create(handle);
@@ -917,7 +917,7 @@ int DatacontrolInstance::CreateMAPHandle(const std::string& providerId, const st
 
 int DatacontrolInstance::CreateSQLHandle(const std::string& providerId, const std::string& dataId,
                                          data_control_h* handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   int result = DATA_CONTROL_ERROR_NONE;
 
   result = ::data_control_sql_create(handle);
@@ -934,7 +934,7 @@ int DatacontrolInstance::CreateSQLHandle(const std::string& providerId, const st
 
 PlatformResult DatacontrolInstance::ChangeTypeToString(data_control_data_change_type_e type_e,
                                                        std::string* type) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   switch (type_e) {
     case DATA_CONTROL_DATA_CHANGE_SQL_UPDATE:
@@ -964,7 +964,7 @@ PlatformResult DatacontrolInstance::ChangeTypeToString(data_control_data_change_
 
 void DatacontrolInstance::callback(data_control_h provider, data_control_data_change_type_e type,
                                    bundle* bundle_data, void* user_data) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   auto data = static_cast<ReplyCallbackData*>(user_data);
 
@@ -1030,7 +1030,7 @@ void DatacontrolInstance::callback(data_control_h provider, data_control_data_ch
   bundle_foreach(
       bundle_data,
       [](const char* key, const int type, const bundle_keyval_t* kv, void* user_data) {
-        LoggerD("Enter");
+        ScopeLogger();
 
         picojson::object& row_data = *(static_cast<picojson::object*>(user_data));
 
@@ -1055,7 +1055,7 @@ void DatacontrolInstance::callback(data_control_h provider, data_control_data_ch
 // occur while adding listener
 void DatacontrolInstance::result_callback(data_control_h provider, data_control_error_e result,
                                           int callback_id, void* user_data) {
-  LoggerD("Enter");
+  ScopeLogger();
   if (DATA_CONTROL_ERROR_NONE != result) {
     auto data = static_cast<ReplyCallbackData*>(user_data);
     picojson::value event = picojson::value(picojson::object());
@@ -1072,7 +1072,7 @@ void DatacontrolInstance::result_callback(data_control_h provider, data_control_
 }
 
 void DatacontrolInstance::AddChangeListener(const picojson::value& args, picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   CHECK_PRIVILEGE_ACCESS(kPrivilegeDatasharing, &out);
   CHECK_PRIVILEGE_ACCESS(kPrivilegeAppmanagerLaunch, &out);
@@ -1138,7 +1138,7 @@ void DatacontrolInstance::AddChangeListener(const picojson::value& args, picojso
 }
 
 void DatacontrolInstance::RemoveChangeListener(const picojson::value& args, picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   CHECK_PRIVILEGE_ACCESS(kPrivilegeDatasharing, &out);
   CHECK_PRIVILEGE_ACCESS(kPrivilegeAppmanagerLaunch, &out);
index 3799126a7fe48aa54913c1b07334c3577fff7760..50d6ba82f9e9e6fc88c542ac4399498d31763569 100644 (file)
@@ -388,7 +388,7 @@ void HumanActivityMonitorInstance::HumanActivityMonitorManagerReadRecorderData(
 
 void HumanActivityMonitorInstance::GestureManagerIsGestureSupported(const picojson::value& args,
                                                                     picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   CHECK_EXIST(args, "type", out)
   const auto& type = args.get("type").get<std::string>();
@@ -404,7 +404,7 @@ void HumanActivityMonitorInstance::GestureManagerIsGestureSupported(const picojs
 
 void HumanActivityMonitorInstance::GestureManagerAddGestureRecognitionListener(
     const picojson::value& args, picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   CHECK_EXIST(args, "type", out)
   CHECK_EXIST(args, "alwaysOn", out)
@@ -430,7 +430,7 @@ void HumanActivityMonitorInstance::GestureManagerAddGestureRecognitionListener(
 
 void HumanActivityMonitorInstance::GestureManagerRemoveGestureRecognitionListener(
     const picojson::value& args, picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   CHECK_EXIST(args, "type", out)
   CHECK_EXIST(args, "alwaysOn", out)
index 58b3f4696ac97f76fed1ca6246b40cf3878e6826..66ecbb4a72bfdc3539e097477ab94817ee6e7411 100644 (file)
@@ -1494,7 +1494,7 @@ void NFCAdapter::GetAIDsForCategory(const std::string& type,
 }
 
 PlatformResult NFCAdapter::SetPreferredApp() {
-  LoggerD("Entered");
+  ScopeLogger();
 
   if (m_is_preferred_app_set) {
     return PlatformResult(ErrorCode::NO_ERROR);
@@ -1511,7 +1511,7 @@ PlatformResult NFCAdapter::SetPreferredApp() {
 }
 
 PlatformResult NFCAdapter::UnsetPreferredApp() {
-  LoggerD("Entered");
+  ScopeLogger();
 
   if (!m_is_preferred_app_set) {
     return PlatformResult(ErrorCode::NO_ERROR);
index 37274071e3f4aaabcff6c48a37dfdf3dc8ca1b33..a64c42db01568b19b519ab814d5aed564b49097d 100644 (file)
@@ -994,7 +994,7 @@ void NFCInstance::GetAIDsForCategory(const picojson::value& args, picojson::obje
 }
 
 void NFCInstance::SetPreferredApp(const picojson::value& args, picojson::object& out) {
-  LoggerD("Entered");
+  ScopeLogger();
   CHECK_PRIVILEGE_ACCESS(kPrivilegeNfcCardEmulation, &out);
 
   PlatformResult result = NFCAdapter::GetInstance()->SetPreferredApp();
@@ -1006,7 +1006,7 @@ void NFCInstance::SetPreferredApp(const picojson::value& args, picojson::object&
 }
 
 void NFCInstance::UnsetPreferredApp(const picojson::value& args, picojson::object& out) {
-  LoggerD("Entered");
+  ScopeLogger();
   CHECK_PRIVILEGE_ACCESS(kPrivilegeNfcCardEmulation, &out);
 
   PlatformResult result = NFCAdapter::GetInstance()->UnsetPreferredApp();
index eafe7813c3b9c0966fbc9e3313526c5a571412c5..52cc10be644e3995b71a4dc9d5c2e2b3ca7405cd 100644 (file)
@@ -60,7 +60,7 @@ CommonNotification::~CommonNotification() {
 }
 
 bool CommonNotification::IsColorFormatNumeric(const std::string& color) {
-  LoggerD("Enter");
+  ScopeLogger();
   std::string hexCode = "0123456789abcdef";
   if (7 != color.length() || '#' != color[0]) {
     return false;
@@ -77,7 +77,7 @@ bool CommonNotification::IsColorFormatNumeric(const std::string& color) {
 
 PlatformResult CommonNotification::SetLayout(notification_h noti_handle,
                                              const std::string& noti_type) {
-  LoggerD("Enter");
+  ScopeLogger();
   notification_ly_type_e noti_layout = NOTIFICATION_LY_NONE;
 
   if ("SIMPLE" == noti_type) {
@@ -109,7 +109,7 @@ PlatformResult CommonNotification::SetLayout(notification_h noti_handle,
 }
 
 static bool ServiceExtraDataCb(app_control_h service, const char* key, void* user_data) {
-  LoggerD("Enter");
+  ScopeLogger();
   if (nullptr == user_data || nullptr == key) {
     LoggerE("User data or key not exist");
     return true;
@@ -150,7 +150,7 @@ static bool ServiceExtraDataCb(app_control_h service, const char* key, void* use
 
 PlatformResult CommonNotification::Create(notification_type_e noti_type,
                                           notification_h* noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   *noti_handle = notification_create(noti_type);
   if (!*noti_handle) {
     return LogAndCreateResult(ErrorCode::UNKNOWN_ERR, "Cannot make new notification object");
@@ -172,7 +172,7 @@ PlatformResult CommonNotification::Create(notification_type_e noti_type,
 PlatformResult CommonNotification::StatusTypeFromPlatform(notification_type_e noti_type,
                                                           notification_ly_type_e noti_layout,
                                                           std::string* type) {
-  LoggerD("Enter");
+  ScopeLogger();
   if (NOTIFICATION_TYPE_NOTI == noti_type) {
     if (NOTIFICATION_LY_NOTI_EVENT_SINGLE == noti_layout ||
         NOTIFICATION_LY_NOTI_EVENT_MULTIPLE == noti_layout) {
@@ -195,7 +195,7 @@ PlatformResult CommonNotification::StatusTypeFromPlatform(notification_type_e no
 
 PlatformResult CommonNotification::StatusTypeToPlatform(const std::string& type,
                                                         notification_type_e* noti_type) {
-  LoggerD("Enter");
+  ScopeLogger();
   if ("SIMPLE" == type || "THUMBNAIL" == type) {
     *noti_type = NOTIFICATION_TYPE_NOTI;
   } else if ("ONGOING" == type || "PROGRESS" == type) {
@@ -211,7 +211,7 @@ PlatformResult CommonNotification::StatusTypeToPlatform(const std::string& type,
 PlatformResult CommonNotification::GetImage(notification_h noti_handle,
                                             notification_image_type_e image_type,
                                             std::string* image_path) {
-  LoggerD("Enter");
+  ScopeLogger();
   char* path = nullptr;
 
   *image_path = "";
@@ -230,7 +230,7 @@ PlatformResult CommonNotification::GetImage(notification_h noti_handle,
 PlatformResult CommonNotification::SetImage(notification_h noti_handle,
                                             notification_image_type_e image_type,
                                             const std::string& image_path) {
-  LoggerD("Enter");
+  ScopeLogger();
   int ret = notification_set_image(noti_handle, image_type, image_path.c_str());
   if (NOTIFICATION_ERROR_NONE != ret) {
     return LogAndCreateResult(
@@ -244,7 +244,7 @@ PlatformResult CommonNotification::SetImage(notification_h noti_handle,
 PlatformResult CommonNotification::GetText(notification_h noti_handle,
                                            notification_text_type_e text_type,
                                            std::string* noti_text) {
-  LoggerD("Enter");
+  ScopeLogger();
   char* text = nullptr;
 
   *noti_text = "";
@@ -262,7 +262,7 @@ PlatformResult CommonNotification::GetText(notification_h noti_handle,
 PlatformResult CommonNotification::SetText(notification_h noti_handle,
                                            notification_text_type_e text_type,
                                            const std::string& noti_text) {
-  LoggerD("Enter");
+  ScopeLogger();
   int ret = notification_set_text(noti_handle, text_type, noti_text.c_str(), nullptr,
                                   NOTIFICATION_VARIABLE_TYPE_NONE);
   if (NOTIFICATION_ERROR_NONE != ret) {
@@ -276,7 +276,7 @@ PlatformResult CommonNotification::SetText(notification_h noti_handle,
 
 PlatformResult CommonNotification::GetNumber(notification_h noti_handle,
                                              notification_text_type_e text_type, long* number) {
-  LoggerD("Enter");
+  ScopeLogger();
   std::string text;
   PlatformResult status = GetText(noti_handle, text_type, &text);
   CHECK_ERROR(status);
@@ -290,7 +290,7 @@ PlatformResult CommonNotification::GetNumber(notification_h noti_handle,
 }
 
 PlatformResult CommonNotification::GetLedColor(notification_h noti_handle, std::string* led_color) {
-  LoggerD("Enter");
+  ScopeLogger();
   unsigned int color = 0;
   notification_led_op_e type = NOTIFICATION_LED_OP_ON;
 
@@ -322,7 +322,7 @@ PlatformResult CommonNotification::GetLedColor(notification_h noti_handle, std::
 PlatformResult CommonNotification::GetLedPeriod(notification_h noti_handle,
                                                 unsigned long* on_period,
                                                 unsigned long* off_period) {
-  LoggerD("Enter");
+  ScopeLogger();
   int on_time = 0;
   int off_time = 0;
 
@@ -339,7 +339,7 @@ PlatformResult CommonNotification::GetLedPeriod(notification_h noti_handle,
 
 PlatformResult CommonNotification::GetSoundPath(notification_h noti_handle,
                                                 std::string* sound_path) {
-  LoggerD("Enter");
+  ScopeLogger();
   *sound_path = "";
 
   const char* path = nullptr;
@@ -362,7 +362,7 @@ PlatformResult CommonNotification::GetSoundPath(notification_h noti_handle,
 
 PlatformResult CommonNotification::SetSoundPath(notification_h noti_handle,
                                                 const std::string& sound_path) {
-  LoggerD("Enter");
+  ScopeLogger();
   int ret =
       notification_set_sound(noti_handle, NOTIFICATION_SOUND_TYPE_USER_DATA, sound_path.c_str());
   if (NOTIFICATION_ERROR_NONE != ret) {
@@ -376,7 +376,7 @@ PlatformResult CommonNotification::SetSoundPath(notification_h noti_handle,
 }
 
 PlatformResult CommonNotification::GetVibration(notification_h noti_handle, bool* vibration) {
-  LoggerD("Enter");
+  ScopeLogger();
   notification_vibration_type_e vib_type = NOTIFICATION_VIBRATION_TYPE_NONE;
 
   if (NOTIFICATION_ERROR_NONE != notification_get_vibration(noti_handle, &vib_type, nullptr)) {
@@ -395,7 +395,7 @@ PlatformResult CommonNotification::GetVibration(notification_h noti_handle, bool
 
 PlatformResult CommonNotification::GetApplicationControl(app_control_h app_handle,
                                                          picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   char* operation = nullptr;
@@ -455,7 +455,7 @@ PlatformResult CommonNotification::GetApplicationControl(app_control_h app_handl
 
 PlatformResult CommonNotification::SetApplicationControl(app_control_h app_handle,
                                                          const picojson::object& app_ctrl) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::value val(app_ctrl);
   const std::string& operation = FromJson<std::string>(app_ctrl, "operation");
 
@@ -529,7 +529,7 @@ PlatformResult CommonNotification::SetApplicationControl(app_control_h app_handl
 }
 
 PlatformResult CommonNotification::GetApplicationId(app_control_h app_handle, std::string* app_id) {
-  LoggerD("Enter");
+  ScopeLogger();
   char* app_id_str = nullptr;
   SCOPE_EXIT {
     free(app_id_str);
@@ -552,7 +552,7 @@ PlatformResult CommonNotification::GetApplicationId(app_control_h app_handle, st
 
 PlatformResult CommonNotification::SetApplicationId(app_control_h app_handle,
                                                     const std::string& app_id) {
-  LoggerD("Enter");
+  ScopeLogger();
   int ret = app_control_set_app_id(app_handle, app_id.c_str());
   if (APP_CONTROL_ERROR_NONE != ret) {
     return LogAndCreateResult(ErrorCode::UNKNOWN_ERR, "Set applicaiton ID error",
@@ -567,7 +567,7 @@ PlatformResult CommonNotification::SetApplicationId(app_control_h app_handle,
 PlatformResult CommonNotification::GetProgressValue(notification_h noti_handle,
                                                     const std::string& progress_type,
                                                     double* progress_value) {
-  LoggerD("Enter");
+  ScopeLogger();
   double tmp_progress_value = 0.0;
 
   if (kProgressTypeByte == progress_type) {
@@ -594,7 +594,7 @@ PlatformResult CommonNotification::GetProgressValue(notification_h noti_handle,
 PlatformResult CommonNotification::SetProgressValue(notification_h noti_handle,
                                                     const std::string& progress_type,
                                                     double progress_value, bool is_update) {
-  LoggerD("Enter");
+  ScopeLogger();
   int ret;
 
   if (kProgressTypeByte == progress_type) {
@@ -624,7 +624,7 @@ PlatformResult CommonNotification::SetProgressValue(notification_h noti_handle,
 }
 
 PlatformResult CommonNotification::GetPostedTime(notification_h noti_handle, time_t* posted_time) {
-  LoggerD("Enter");
+  ScopeLogger();
   *posted_time = 0;
 
   if (NOTIFICATION_ERROR_NONE != notification_get_insert_time(noti_handle, posted_time)) {
@@ -635,7 +635,7 @@ PlatformResult CommonNotification::GetPostedTime(notification_h noti_handle, tim
 }
 
 PlatformResult CommonNotification::GetNotiHandle(int id, notification_h* noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   *noti_handle = notification_load(nullptr, id);
   if (nullptr == *noti_handle) {
     return LogAndCreateResult(ErrorCode::NOT_FOUND_ERR, "Not found or removed notification id");
@@ -646,7 +646,7 @@ PlatformResult CommonNotification::GetNotiHandle(int id, notification_h* noti_ha
 
 PlatformResult CommonNotification::GetAppControl(notification_h noti_handle,
                                                  app_control_h* app_control) {
-  LoggerD("Enter");
+  ScopeLogger();
   int ret = notification_get_launch_option(noti_handle, NOTIFICATION_LAUNCH_OPTION_APP_CONTROL,
                                            static_cast<void*>(app_control));
   if (NOTIFICATION_ERROR_NONE != ret) {
@@ -658,7 +658,7 @@ PlatformResult CommonNotification::GetAppControl(notification_h noti_handle,
 }
 
 PlatformResult CommonNotification::CreateAppControl(app_control_h* app_control) {
-  LoggerD("Enter");
+  ScopeLogger();
   int ret = app_control_create(app_control);
   if (APP_CONTROL_ERROR_NONE != ret) {
     return LogAndCreateResult(ErrorCode::INVALID_VALUES_ERR, "Application create error",
@@ -670,7 +670,7 @@ PlatformResult CommonNotification::CreateAppControl(app_control_h* app_control)
 
 PlatformResult CommonNotification::SetAppControl(notification_h noti_handle,
                                                  app_control_h app_control) {
-  LoggerD("Enter");
+  ScopeLogger();
   int ret = notification_set_launch_option(noti_handle, NOTIFICATION_LAUNCH_OPTION_APP_CONTROL,
                                            static_cast<void*>(app_control));
   if (APP_CONTROL_ERROR_NONE != ret) {
@@ -698,7 +698,7 @@ PlatformResult CommonNotification::UpdateNotificationAfterPost(notification_h no
 PlatformResult CommonNotification::PostNotification(const picojson::object& args, bool is_update,
                                                     picojson::object* out_ptr,
                                                     GetHandleFromJsonFun getHandle) {
-  LoggerD("Enter");
+  ScopeLogger();
   notification_h noti_handle = nullptr;
   int ret = NOTIFICATION_ERROR_NONE;
   int id = NOTIFICATION_PRIV_ID_NONE;
@@ -734,7 +734,7 @@ PlatformResult CommonNotification::PostNotification(const picojson::object& args
 
 PlatformResult CommonNotification::AddCommonMembersToJson(int id, notification_h noti_handle,
                                                           picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   out["id"] = picojson::value(std::to_string(id));
@@ -762,7 +762,7 @@ PlatformResult CommonNotification::AddCommonMembersToJson(int id, notification_h
 PlatformResult CommonNotification::AddTypeToJson(notification_h noti_handle, const std::string& key,
                                                  picojson::object* out_ptr,
                                                  std::string* noti_type_str) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
   // Notification type
   notification_type_e noti_type = NOTIFICATION_TYPE_NONE;
@@ -789,7 +789,7 @@ PlatformResult CommonNotification::AddTypeToJson(notification_h noti_handle, con
 PlatformResult CommonNotification::AddProgressTypeAndValueToJson(notification_h noti_handle,
                                                                  const std::string& noti_type_str,
                                                                  picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   picojson::object& out = *out_ptr;
   std::string progress_type;
@@ -816,7 +816,7 @@ PlatformResult CommonNotification::AddProgressTypeAndValueToJson(notification_h
 PlatformResult CommonNotification::AddEventsNumberToJson(notification_h noti_handle,
                                                          const std::string& key,
                                                          picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   long number = 0;
@@ -830,7 +830,7 @@ PlatformResult CommonNotification::AddEventsNumberToJson(notification_h noti_han
 
 PlatformResult CommonNotification::AddDetailInfosToJson(notification_h noti_handle,
                                                         picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   picojson::value result_json = picojson::value(picojson::array());
@@ -895,7 +895,7 @@ PlatformResult CommonNotification::AddTextToJson(notification_h noti_handle,
 
 PlatformResult CommonNotification::AddLedOnOffPeriodToJson(notification_h noti_handle,
                                                            picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   unsigned long on_period = 0;
@@ -911,7 +911,7 @@ PlatformResult CommonNotification::AddLedOnOffPeriodToJson(notification_h noti_h
 PlatformResult CommonNotification::AddPathsArrayToJson(notification_h noti_handle, ImageEnumMap map,
                                                        const std::string& key,
                                                        picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   picojson::value result_json = picojson::value(picojson::array());
@@ -937,7 +937,7 @@ PlatformResult CommonNotification::AddTextsArrayToJson(notification_h noti_handl
                                                        InformationEnumMap map,
                                                        const std::string& key,
                                                        picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   picojson::value result_json = picojson::value(picojson::array());
@@ -961,7 +961,7 @@ PlatformResult CommonNotification::AddTextsArrayToJson(notification_h noti_handl
 
 PlatformResult CommonNotification::AddLedColorToJson(notification_h noti_handle,
                                                      picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   std::string color;
@@ -976,7 +976,7 @@ PlatformResult CommonNotification::AddLedColorToJson(notification_h noti_handle,
 
 PlatformResult CommonNotification::AddSoundPathToJson(notification_h noti_handle,
                                                       picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   std::string sound_path;
@@ -991,7 +991,7 @@ PlatformResult CommonNotification::AddSoundPathToJson(notification_h noti_handle
 
 PlatformResult CommonNotification::AddVibrationToJson(notification_h noti_handle,
                                                       picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   bool vibration;
@@ -1005,7 +1005,7 @@ PlatformResult CommonNotification::AddVibrationToJson(notification_h noti_handle
 PlatformResult CommonNotification::AddAppControlInfoToJson(notification_h noti_handle,
                                                            app_control_h app_handle,
                                                            picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object& out = *out_ptr;
 
   if (app_handle) {
@@ -1029,7 +1029,7 @@ PlatformResult CommonNotification::AddAppControlInfoToJson(notification_h noti_h
 PlatformResult CommonNotification::InitNotiFromJson(const picojson::object& noti_obj,
                                                     const std::string& type_key, bool is_update,
                                                     notification_h* noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   notification_h tmp_noti = nullptr;
 
   const std::string& status_type = FromJson<std::string>(noti_obj, type_key.c_str());
@@ -1059,7 +1059,7 @@ PlatformResult CommonNotification::InitNotiFromJson(const picojson::object& noti
 
 PlatformResult CommonNotification::SetCommonMembersFromJson(const picojson::value& noti_value,
                                                             notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
   PlatformResult status =
       SetText(noti_handle, NOTIFICATION_TEXT_TYPE_TITLE, FromJson<std::string>(noti_obj, "title"));
@@ -1074,7 +1074,7 @@ PlatformResult CommonNotification::SetPathFromJson(const picojson::value& noti_v
                                                    notification_image_type_e type,
                                                    const std::string& key,
                                                    notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
   if (noti_value.contains(key) && !IsNull(noti_obj, key.c_str())) {
     const std::string& value_str = FromJson<std::string>(noti_obj, key.c_str());
@@ -1088,7 +1088,7 @@ PlatformResult CommonNotification::SetPathFromJson(const picojson::value& noti_v
 
 PlatformResult CommonNotification::SetLedColorFromJson(const picojson::value& noti_value,
                                                        notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
   if (noti_value.contains("ledColor") && !IsNull(noti_obj, "ledColor")) {
     std::string color_str = FromJson<std::string>(noti_obj, "ledColor");
@@ -1124,7 +1124,7 @@ PlatformResult CommonNotification::SetLedColorFromJson(const picojson::value& no
 
 PlatformResult CommonNotification::SetLedOnPeriodFromJson(const picojson::value& noti_value,
                                                           notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
   unsigned long on_period = static_cast<unsigned long>(FromJson<double>(noti_obj, "ledOnPeriod"));
 
@@ -1143,7 +1143,7 @@ PlatformResult CommonNotification::SetLedOnPeriodFromJson(const picojson::value&
 
 PlatformResult CommonNotification::SetLedOffPeriodFromJson(const picojson::value& noti_value,
                                                            notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
   unsigned long off_period = static_cast<unsigned long>(FromJson<double>(noti_obj, "ledOffPeriod"));
   unsigned long on_period = 0;
@@ -1161,7 +1161,7 @@ PlatformResult CommonNotification::SetLedOffPeriodFromJson(const picojson::value
 
 PlatformResult CommonNotification::SetProgressTypeAndValueFromJson(
     const picojson::value& noti_value, bool is_update, notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
 
   // progressType
@@ -1183,7 +1183,7 @@ PlatformResult CommonNotification::SetProgressTypeAndValueFromJson(
 
 PlatformResult CommonNotification::SetAppControlInfoFromJson(const picojson::value& noti_value,
                                                              notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
 
   app_control_h app_control = nullptr;
@@ -1215,7 +1215,7 @@ PlatformResult CommonNotification::SetAppControlInfoFromJson(const picojson::val
 PlatformResult CommonNotification::SetEventsNumberFromJson(const picojson::value& noti_value,
                                                            const std::string& key,
                                                            notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
 
   if (noti_value.contains(key) && !IsNull(noti_obj, key.c_str())) {
@@ -1229,7 +1229,7 @@ PlatformResult CommonNotification::SetEventsNumberFromJson(const picojson::value
 
 PlatformResult CommonNotification::SetDetailInfosFromJson(const picojson::value& noti_value,
                                                           notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
   if (noti_value.contains("detailInfo") && !IsNull(noti_obj, "detailInfo")) {
     const picojson::array& array = FromJson<picojson::array>(noti_obj, "detailInfo");
@@ -1257,7 +1257,7 @@ PlatformResult CommonNotification::SetDetailInfosFromJson(const picojson::value&
 
 PlatformResult CommonNotification::SetVibrationFromJson(const picojson::value& noti_value,
                                                         notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
   bool vibration = FromJson<bool>(noti_obj, "vibration");
 
@@ -1284,7 +1284,7 @@ PlatformResult CommonNotification::SetVibrationFromJson(const picojson::value& n
 
 PlatformResult CommonNotification::SetSoundPathFromJson(const picojson::value& noti_value,
                                                         notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
 
   if (noti_value.contains("soundPath") && !IsNull(noti_obj, "soundPath")) {
@@ -1301,7 +1301,7 @@ PlatformResult CommonNotification::SetSoundPathFromJson(const picojson::value& n
 PlatformResult CommonNotification::SetPathsArrayFromJson(const picojson::value& noti_value,
                                                          ImageEnumMap map, const std::string& key,
                                                          notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
 
   if (noti_value.contains(key) && !IsNull(noti_obj, key.c_str())) {
@@ -1328,7 +1328,7 @@ PlatformResult CommonNotification::SetTextsArrayFromJson(const picojson::value&
                                                          InformationEnumMap map,
                                                          const std::string& key,
                                                          notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
 
   if (noti_value.contains(key) && !IsNull(noti_obj, key.c_str())) {
@@ -1354,7 +1354,7 @@ PlatformResult CommonNotification::SetTextFromJson(const picojson::value& noti_v
                                                    notification_text_type_e type,
                                                    const std::string& key,
                                                    notification_h noti_handle) {
-  LoggerD("Entered");
+  ScopeLogger();
   const picojson::object& noti_obj = noti_value.get<picojson::object>();
 
   if (noti_value.contains(key) && !IsNull(noti_obj, key.c_str())) {
index 05851dd5a2c508e066c06ba4849b9dd26d495368..433830a344a127e557c9dd0af2f0f9bf72eb1b34 100644 (file)
@@ -205,7 +205,7 @@ void NotificationInstance::NotificationManagerStopLEDCustomEffect(const picojson
 
 void NotificationInstance::NotificationManagerSaveTemplate(const picojson::value& args,
                                                            picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
   CHECK_PRIVILEGE_ACCESS(kPrivilegeNotification, &out);
 
   PlatformResult status = manager_->SaveTemplate(args.get<picojson::object>());
@@ -219,7 +219,7 @@ void NotificationInstance::NotificationManagerSaveTemplate(const picojson::value
 
 void NotificationInstance::NotificationManagerCreateFromTemplate(const picojson::value& args,
                                                                  picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
   CHECK_PRIVILEGE_ACCESS(kPrivilegeNotification, &out);
   picojson::value val{picojson::object{}};
 
index a0b260762078b743cef4eb89d6effd95d253fde9..a7b3418d253920851673ce10c563bb08c19b2cf7 100644 (file)
@@ -59,7 +59,7 @@ PlatformResult NotificationManager::Post(const picojson::object& args, picojson:
 
 PlatformResult NotificationManager::PostUserNoti(const picojson::object& args,
                                                  picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
   return UserNotification::PostUserNotification(args, false, &out);
 }
 
@@ -69,7 +69,7 @@ PlatformResult NotificationManager::Update(const picojson::object& args) {
 }
 
 PlatformResult NotificationManager::UpdateUserNoti(const picojson::object& args) {
-  LoggerD("Enter");
+  ScopeLogger();
   return UserNotification::PostUserNotification(args, true, nullptr);
 }
 
@@ -255,7 +255,7 @@ PlatformResult NotificationManager::StopLEDCustomEffect() {
 }
 
 common::PlatformResult NotificationManager::SaveTemplate(const picojson::object& args) {
-  LoggerD("Enter");
+  ScopeLogger();
   std::string name = FromJson<std::string>(args, "name");
   notification_h noti_handle = nullptr;
   int ret;
@@ -294,7 +294,7 @@ common::PlatformResult NotificationManager::SaveTemplate(const picojson::object&
 
 common::PlatformResult NotificationManager::CreateFromTemplate(const picojson::object& args,
                                                                picojson::object& out) {
-  LoggerD("Enter");
+  ScopeLogger();
   std::string name = FromJson<std::string>(args, "name");
 
   notification_h noti_handle = nullptr;
index c8bbea5c47c6e7c1e7f611135671f085f39d85df..f4b002dfbdf89973b6d3c28e4a3941a304d814df 100644 (file)
@@ -176,7 +176,7 @@ PlatformResult StatusNotification::GetNotiHandleFromJson(const picojson::value&
 PlatformResult StatusNotification::PostStatusNotification(const picojson::object& args,
                                                           bool is_update,
                                                           picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   return PostNotification(args, is_update, out_ptr, GetNotiHandleFromJson);
 }
 
index 1a73a2f4ec33d51abfed38d2eddc05fdc7b2dfb4..d7960decba0cac55d1ea43d83528a20703a19e8d 100644 (file)
@@ -33,7 +33,7 @@ UserNotification::~UserNotification() {
 
 PlatformResult UserNotification::ToJson(int id, notification_h noti_handle,
                                         app_control_h app_handle, picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   PlatformResult ret = AddCommonMembersToJson(id, noti_handle, out_ptr);
   CHECK_ERROR(ret);
 
@@ -65,7 +65,7 @@ PlatformResult UserNotification::ToJson(int id, notification_h noti_handle,
 PlatformResult UserNotification::GetNotiHandleFromJson(const picojson::value& noti_val,
                                                        bool is_update,
                                                        notification_h* noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   picojson::object noti_obj = noti_val.get<picojson::object>();
 
   notification_h tmp_noti = nullptr;
@@ -102,14 +102,14 @@ PlatformResult UserNotification::GetNotiHandleFromJson(const picojson::value& no
 
 PlatformResult UserNotification::PostUserNotification(const picojson::object& args, bool is_update,
                                                       picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
   return PostNotification(args, is_update, out_ptr, GetNotiHandleFromJson);
 }
 
 PlatformResult UserNotification::AddTextContentsToJson(notification_h noti_handle,
                                                        std::string noti_type_str,
                                                        picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   picojson::value text_contents = picojson::value(picojson::object());
   picojson::object& text_contents_obj = text_contents.get<picojson::object>();
@@ -142,7 +142,7 @@ PlatformResult UserNotification::AddTextContentsToJson(notification_h noti_handl
 
 PlatformResult UserNotification::AddImagesToJson(notification_h noti_handle,
                                                  picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   picojson::value images_contents = picojson::value(picojson::object());
   picojson::object& images_contents_obj = images_contents.get<picojson::object>();
@@ -183,7 +183,7 @@ PlatformResult UserNotification::AddImagesToJson(notification_h noti_handle,
 
 PlatformResult UserNotification::AddThumbnailsToJson(notification_h noti_handle,
                                                      picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   picojson::value thumbnails_contents = picojson::value(picojson::object());
   picojson::object& thumbnails_contents_obj = thumbnails_contents.get<picojson::object>();
@@ -210,7 +210,7 @@ PlatformResult UserNotification::AddThumbnailsToJson(notification_h noti_handle,
 PlatformResult UserNotification::AddActionsToJson(notification_h noti_handle,
                                                   app_control_h app_handle,
                                                   picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   picojson::value actions_contents = picojson::value(picojson::object());
   picojson::object& actions_contents_obj = actions_contents.get<picojson::object>();
@@ -233,7 +233,7 @@ PlatformResult UserNotification::AddActionsToJson(notification_h noti_handle,
 
 PlatformResult UserNotification::AddGroupContentsToJson(notification_h noti_handle,
                                                         picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   picojson::value group_contents = picojson::value(picojson::object());
   picojson::object& group_contents_obj = group_contents.get<picojson::object>();
@@ -260,7 +260,7 @@ PlatformResult UserNotification::AddGroupContentsToJson(notification_h noti_hand
 
 PlatformResult UserNotification::AddLedsToJson(notification_h noti_handle,
                                                picojson::object* out_ptr) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   picojson::value leds_contents = picojson::value(picojson::object());
   picojson::object& leds_contents_obj = leds_contents.get<picojson::object>();
@@ -280,7 +280,7 @@ PlatformResult UserNotification::AddLedsToJson(notification_h noti_handle,
 PlatformResult UserNotification::SetTextContentsFromJson(const picojson::value& noti_value,
                                                          bool is_update,
                                                          notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   if (noti_value.contains("textContents") &&
       noti_value.get("textContents").is<picojson::object>()) {
     LoggerD("nullable member textContents is present - parsing it");
@@ -315,7 +315,7 @@ PlatformResult UserNotification::SetTextContentsFromJson(const picojson::value&
 
 PlatformResult UserNotification::SetImagesFromJson(const picojson::value& noti_value,
                                                    notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
   if (noti_value.contains("images") && noti_value.get("images").is<picojson::object>()) {
     LoggerD("nullable member images is present - parsing it");
     const picojson::value& images_value = noti_value.get("images");
@@ -355,7 +355,7 @@ PlatformResult UserNotification::SetImagesFromJson(const picojson::value& noti_v
 
 PlatformResult UserNotification::SetThumbnailsFromJson(const picojson::value& noti_value,
                                                        notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   if (noti_value.contains("thumbnails") && noti_value.get("thumbnails").is<picojson::object>()) {
     LoggerD("nullable member thumbnails is present - parsing it");
@@ -381,7 +381,7 @@ PlatformResult UserNotification::SetThumbnailsFromJson(const picojson::value& no
 
 PlatformResult UserNotification::SetActionsFromJson(const picojson::value& noti_value,
                                                     notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   if (noti_value.contains("actions") && noti_value.get("actions").is<picojson::object>()) {
     LoggerD("nullable member actions is present - parsing it");
@@ -404,7 +404,7 @@ PlatformResult UserNotification::SetActionsFromJson(const picojson::value& noti_
 
 PlatformResult UserNotification::SetGroupContentsFromJson(const picojson::value& noti_value,
                                                           notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   if (noti_value.contains("groupContents") &&
       noti_value.get("groupContents").is<picojson::object>()) {
@@ -432,7 +432,7 @@ PlatformResult UserNotification::SetGroupContentsFromJson(const picojson::value&
 
 PlatformResult UserNotification::SetLedsFromJson(const picojson::value& noti_value,
                                                  notification_h noti_handle) {
-  LoggerD("Enter");
+  ScopeLogger();
 
   if (noti_value.contains("leds") && noti_value.get("leds").is<picojson::object>()) {
     LoggerD("nullable member leds is present - parsing it");