summaryrefslogtreecommitdiffstats
path: root/src/plugins/utilities/logging/Logger.cpp
diff options
context:
space:
mode:
authorJan-Simon Moeller <jsmoeller@linuxfoundation.org>2019-10-15 17:45:19 +0000
committerGerrit Code Review <gerrit@automotivelinux.org>2019-10-15 17:45:19 +0000
commit66b1e2269eba8d48b1d463054af95b290912f2b6 (patch)
tree67f71f11097c103451533f4f63b5eff682f47e7b /src/plugins/utilities/logging/Logger.cpp
parent3c7fdce635ea4fcb37fbee33765c1f2a9a32f6b3 (diff)
parent54be328d031b3d8be799a2563d944e06c41c66ec (diff)
Merge "Switch to appcontroller library" into halibut
Diffstat (limited to 'src/plugins/utilities/logging/Logger.cpp')
-rw-r--r--src/plugins/utilities/logging/Logger.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/plugins/utilities/logging/Logger.cpp b/src/plugins/utilities/logging/Logger.cpp
index b310695..e09ba9a 100644
--- a/src/plugins/utilities/logging/Logger.cpp
+++ b/src/plugins/utilities/logging/Logger.cpp
@@ -1,5 +1,6 @@
/*
* Copyright 2018-2019 Amazon.com, Inc. or its affiliates. All Rights Reserved.
+ * Copyright 2019 Konsulko Group
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
@@ -18,11 +19,11 @@ namespace utilities {
namespace logging {
// Constructor
-Logger::Logger(AFB_ApiT api) {
+Logger::Logger(afb_api_t api) {
mApi = api;
}
-unique_ptr<Logger> Logger::create(AFB_ApiT api) {
+unique_ptr<Logger> Logger::create(afb_api_t api) {
auto logger = std::unique_ptr<Logger>(new Logger(api));
return logger;
}
@@ -31,19 +32,19 @@ void Logger::log(Level level, const std::string& tag, const std::string& message
string format_msg = "Tag: " + tag + ", message: " + message;
switch (level) {
case Level::NOTICE:
- AFB_ApiNotice(mApi, format_msg.c_str());
+ AFB_API_NOTICE(mApi, format_msg.c_str());
break;
case Level::WARNING:
- AFB_ApiWarning(mApi, format_msg.c_str());
+ AFB_API_WARNING(mApi, format_msg.c_str());
break;
case Level::DEBUG:
- AFB_ApiDebug(mApi, format_msg.c_str());
+ AFB_API_DEBUG(mApi, format_msg.c_str());
break;
case Level::ERROR:
- AFB_ApiError(mApi, format_msg.c_str());
+ AFB_API_ERROR(mApi, format_msg.c_str());
break;
case Level::INFO:
- AFB_ApiInfo(mApi, format_msg.c_str());
+ AFB_API_INFO(mApi, format_msg.c_str());
break;
default:
break;