oa::Log

Log class in the OA Core public surface.

Public Methods

oa::Status oa::Log::close()
oa::Status oa::Log::flush()
LogLevel oa::Log::getLevel()
oa::String oa::Log::getLogPath()
oa::Bool oa::Log::isOpen()
void oa::Log::setLevel(LogLevel inLevel)
oa::Status oa::Log::write(LogLevel inLevel, LogComponent inComponent, const char (&)[N] inFormat, Args &&... inArgs)
oa::Status oa::Log::write(LogLevel inLevel, LogComponent inComponent, oa::StringView inText)
oa::Status oa::Log::writeText(LogLevel inLevel, LogComponent inComponent, oa::StringView inText)

Static Public Methods

static oa::Result<oa::UniquePtr<Log>> oa::Log::create(const LogOptions & inOptions = {})

Constructor & Destructor Documentation

void oa::Log::~Log()
No public source comment is attached to this declaration.

Public Method Documentation

oa::Status oa::Log::close()
No public source comment is attached to this declaration.

Returns

oa::Status

The declared return value.

oa::Status oa::Log::flush()
No public source comment is attached to this declaration.

Returns

oa::Status

The declared return value.

LogLevel oa::Log::getLevel()
No public source comment is attached to this declaration.

Returns

LogLevel

The declared return value.

oa::String oa::Log::getLogPath()
No public source comment is attached to this declaration.

Returns

oa::String

The declared return value.

oa::Bool oa::Log::isOpen()
No public source comment is attached to this declaration.

Returns

oa::Bool

The declared return value.

void oa::Log::setLevel( LogLevel inLevel )
No public source comment is attached to this declaration.

Parameters

inLevel
LogLevel

Returns

void

The declared return value.

oa::Status oa::Log::write( LogLevel inLevel, LogComponent inComponent, const char (&)[N] inFormat, Args &&... inArgs )
No public source comment is attached to this declaration.

Parameters

inLevel
LogLevel

inComponent
LogComponent

inFormat
const char (&)[N]

inArgs
Args &&...

Returns

oa::Status

The declared return value.

oa::Status oa::Log::write( LogLevel inLevel, LogComponent inComponent, oa::StringView inText )
No public source comment is attached to this declaration.

Parameters

inLevel
LogLevel

inComponent
LogComponent

inText
oa::StringView

Returns

oa::Status

The declared return value.

oa::Status oa::Log::writeText( LogLevel inLevel, LogComponent inComponent, oa::StringView inText )
writes are serialized and safe from any thread. Write never throws; an I/O failure is returned to explicit callers and retained for flush/Close.

Parameters

inLevel
LogLevel

inComponent
LogComponent

inText
oa::StringView

Returns

oa::Status

The declared return value.

static oa::Result<oa::UniquePtr<Log>> oa::Log::create( const LogOptions & inOptions = {} )
No public source comment is attached to this declaration.

Parameters

inOptions
const LogOptions &

Default: {}

Returns

oa::Result<oa::UniquePtr<Log>>

The declared return value.