src/base/logger.hpp¶
Namespaces¶
| Name |
|---|
| sgns |
| sgns::base |
Types¶
| Name | |
|---|---|
| using std::shared_ptr< spdlog::logger > | Logger |
Functions¶
| Name | |
|---|---|
| Logger | createLogger(const std::string & tag, const std::string & basepath ="") Create a logger instance. |
Types Documentation¶
using Logger¶
Functions Documentation¶
function createLogger¶
Create a logger instance.
Parameters:
- tag Tagging name for identifying logger.
- basepath Optional base path for log output (platform dependent).
Return: Logger object.
Source code¶
#ifndef SUPERGENIUS_LOGGER_HPP
#define SUPERGENIUS_LOGGER_HPP
#include <spdlog/fmt/ostr.h>
#include <spdlog/spdlog.h>
#if defined( ANDROID )
#include <spdlog/sinks/android_sink.h>
#endif
namespace sgns::base
{
using Logger = std::shared_ptr<spdlog::logger>;
Logger createLogger( const std::string &tag, const std::string &basepath = "" );
} // namespace sgns::base
#endif // SUPERGENIUS_LOGGER_HPP
Updated on 2026-03-04 at 13:10:44 -0800