![]() |
AlexaClientSDK
1.26.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
|
#include <ConsolePrinter.h>


Public Member Functions | |
| ConsolePrinter () | |
Logger methods | |
| void | emit (avsCommon::utils::logger::Level level, std::chrono::system_clock::time_point time, const char *threadMoniker, const char *text) override |
Public Member Functions inherited from alexaClientSDK::avsCommon::utils::logger::Logger | |
| Logger (Level level) | |
| virtual | ~Logger ()=default |
| Destructor. More... | |
| virtual void | setLevel (Level level) |
| bool | shouldLog (Level level) const |
| void | log (Level level, const LogEntry &entry) |
| void | logAtExit (Level level, const LogEntry &entry) |
| void | addLogLevelObserver (LogLevelObserverInterface *observer) |
| void | removeLogLevelObserver (LogLevelObserverInterface *observer) |
Static Public Member Functions | |
| static void | simplePrint (const std::string &stringToPrint) |
| static void | prettyPrint (const std::string &stringToPrint) |
| static void | prettyPrint (std::initializer_list< std::string > lines) |
| static void | captionsPrint (const std::vector< std::string > &lines) |
Additional Inherited Members | |
Protected Member Functions inherited from alexaClientSDK::avsCommon::utils::logger::Logger | |
| void | init (const configuration::ConfigurationNode configuration) |
Protected Attributes inherited from alexaClientSDK::avsCommon::utils::logger::Logger | |
| std::atomic< Level > | m_level |
| The lowest severity level of logs to be output by this Logger. More... | |
A simple class that prints to the screen.
| alexaClientSDK::sampleApp::ConsolePrinter::ConsolePrinter | ( | ) |
Constructor.
|
static |
Prints a decorated multi-line message with a pretty format with a newline after, along with an "Alexa Says" header, used for outputting captions.
| lines | The strings representing captions from Alexa's voice. |
|
overridevirtual |
Emit a log entry. Default implementation is no-op. NOTE: This method must be thread-safe. NOTE: Delays in returning from this method may hold up calls to Logger::log().
| level | The severity Level of this log line. |
| time | The time that the event to log occurred. |
| threadMoniker | Moniker of the thread that generated the event. |
| text | The text of the entry to log. |
Reimplemented from alexaClientSDK::avsCommon::utils::logger::Logger.
|
static |
Prints a message with a pretty format with a
after.
| stringToPrint | The string to print. |
|
static |
Prints a multi-line message with a pretty format with a
after.
| lines | The strings to print. |
|
static |
Prints a simple message along with an
.
| stringToPrint | The string to print. |
AlexaClientSDK 1.26.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0