LoggerNull {SCDB} | R Documentation |
LoggerNull: The no-logging Logger
Description
The LoggerNull
class overwrites the functions of the Logger
so no logging is produced.
Errors and warnings are still produced.
Value
A new instance of the LoggerNull
R6 class.
Super class
SCDB::Logger
-> LoggerNull
Methods
Public methods
Inherited methods
Method new()
Create a new LoggerNull
object
Usage
LoggerNull$new(...)
Arguments
...
Captures arguments given, but does nothing
Method log_to_db()
Matches the signature of Logger$log_to_db()
, but does nothing.
Usage
LoggerNull$log_to_db(...)
Arguments
...
Captures arguments given, but does nothing
Method finalize_db_entry()
Matches the signature of Logger$finalize_db_entry()
, but does nothing.
Usage
LoggerNull$finalize_db_entry(...)
Arguments
...
Captures arguments given, but does nothing
Method clone()
The objects of this class are cloneable with this method.
Usage
LoggerNull$clone(deep = FALSE)
Arguments
deep
Whether to make a deep clone.
Examples
logger <- LoggerNull$new()
logger$log_info("This message will not print!")
logger$log_to_db(message = "This message will no be written in database!")
try(logger$log_warn("This is a warning!"))
try(logger$log_error("This is an error!"))
[Package SCDB version 0.4.0 Index]