Loading...
Searching...
No Matches
by::fileLogStream Class Reference

File output stream for logging to disk files. More...

#include <fileLogStream.hpp>

Inheritance diagram for by::fileLogStream:
by::stream

Public Member Functions

 fileLogStream (const std::string &new_path)
 
nbool setPath (const std::string &new_path)
 Sets the path for the log file and attempts to open it.
 
const std::string & getPath () const
 
const std::string & getName () const override
 
nbool logBypass (const nchar *message) override
 Log message directly without formatting.
 
- Public Member Functions inherited from by::stream
 stream (nbool isEnable=true)
 
nbool logBypass (const std::string &message)
 
nbool isNull () const
 Checks if this stream is a null object.
 
virtual nbool isEnable () const
 
virtual void setEnable (nbool isEnable)
 
virtual nbool init ()
 Initializes the stream, transitioning its state from RELEASED to INITIALIZED.
 
virtual nbool isInit () const
 
virtual nbool rel ()
 Releases the stream's resources, transitioning its state from INITIALIZED to RELEASED.
 

Detailed Description

File output stream for logging to disk files.

Implements stream interface to write log messages to files with configurable file paths and automatic file management.

Member Function Documentation

◆ getName()

const std::string & by::fileLogStream::getName ( ) const
overridevirtual

Implements by::stream.

◆ logBypass()

nbool by::fileLogStream::logBypass ( const nchar * message)
overridevirtual

Log message directly without formatting.

Returns
true on success, false on error

Reimplemented from by::stream.

◆ setPath()

nbool by::fileLogStream::setPath ( const std::string & new_path)

Sets the path for the log file and attempts to open it.

Parameters
new_pathThe new path for the log file.
Returns
true if the file was successfully opened or the path was set, false otherwise.

The documentation for this class was generated from the following file: