From 11d32517c2f6f538209c893c6b0b24572fba1a36 Mon Sep 17 00:00:00 2001 From: Saturneric Date: Fri, 3 Feb 2023 21:43:55 +0800 Subject: feat: change the log style in source files --- src/core/GpgFunctionObject.cpp | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'src/core/GpgFunctionObject.cpp') diff --git a/src/core/GpgFunctionObject.cpp b/src/core/GpgFunctionObject.cpp index 6ff83d72..3956e31e 100644 --- a/src/core/GpgFunctionObject.cpp +++ b/src/core/GpgFunctionObject.cpp @@ -34,8 +34,6 @@ #include #include -#include "easylogging++.h" - void GpgFrontend::ChannelObject::SetChannel(int channel) { this->channel_ = channel; } @@ -79,8 +77,8 @@ std::vector GpgFrontend::SingletonStorage::GetAllChannelId() { GpgFrontend::ChannelObject* GpgFrontend::SingletonStorage::SetObjectInChannel( int channel, std::unique_ptr p_obj) { { - LOG(TRACE) << "set channel:" << channel - << "instance address:" << &instances_map_; + SPDLOG_TRACE("set channel: {} instance address: {}", channel, + static_cast(&instances_map_)); assert(p_obj != nullptr); if (p_obj == nullptr) return nullptr; @@ -111,9 +109,8 @@ GpgFrontend::SingletonStorageCollection::GetSingletonStorage( std::unique_lock lock(storages_mutex_); storages_map_.insert({hash, std::make_unique()}); } - LOG(TRACE) << "hash:" << hash << "created" - << "storage address:" << &storages_map_ - << "type_name : " << type_id.name(); + SPDLOG_TRACE("hash: {} created, storage address: {} type_name: {}", hash, + static_cast(&storages_map_), type_id.name()); continue; } else { return _it->second.get(); @@ -128,7 +125,8 @@ GpgFrontend::SingletonStorageCollection::GetInstance( if (force_refresh || instance == nullptr) { instance = new SingletonStorageCollection(); - LOG(INFO) << "new single storage collection created: " << instance; + SPDLOG_INFO("new single storage collection created: {}", + static_cast(instance)); } return instance; -- cgit v1.2.3