Simple-Log
alpha-v0.7
|
Sink interface class. More...
#include <ISink.hpp>
Public Types | |
using | Record_t = std::remove_cvref_t< TRecord > |
Used Record type. More... | |
Public Member Functions | |
ISink (const ISink &)=delete | |
Deleted copy-constructor. More... | |
ISink & | operator= (const ISink &)=delete |
Deleted copy-assign operator. More... | |
virtual | ~ISink () noexcept=default |
virtual default destructor More... | |
virtual void | log (const Record_t &record)=0 |
virtual log function More... | |
virtual void | setEnabled (bool enable=true) noexcept=0 |
Enables or disables the Sink object. More... | |
virtual bool | isEnabled () const noexcept=0 |
Checks if the Sink object is enabled. More... | |
Protected Member Functions | |
ISink ()=default | |
Default constructor. More... | |
ISink (ISink &&)=default | |
Default move-constructor. More... | |
ISink & | operator= (ISink &&)=default |
Default move-assign operator. More... | |
Sink interface class.
TRecord | Used Record type. |
The interface class for each derived Sink type. If you want to implement your custom Sink type, have a look at BasicSink first. This might be a better starting point for customizations.
using sl::log::ISink< TRecord >::Record_t = std::remove_cvref_t<TRecord> |
Used Record type.
|
delete |
Deleted copy-constructor.
|
virtualdefaultnoexcept |
virtual default destructor
|
protecteddefault |
Default constructor.
|
protecteddefault |
Default move-constructor.
|
pure virtualnoexcept |
Checks if the Sink object is enabled.
Implemented in sl::log::BasicSink< TRecord >.
|
pure virtual |
virtual log function
Will be called from the Worker thread.
record | The record about to be processed by the sink |
Implemented in sl::log::BasicSink< TRecord >.
|
delete |
Deleted copy-assign operator.
|
protecteddefault |
Default move-assign operator.
|
pure virtualnoexcept |
Enables or disables the Sink object.
Disabled Sinks will not handle any incoming Record s
enable | True will enable the Sink object. |
Implemented in sl::log::BasicSink< TRecord >.