Struct spdlog::LoggerBuilder

source ·
pub struct LoggerBuilder { /* private fields */ }
Expand description

The builder of Logger.

Implementations§

👎Deprecated since 0.3.0: it may be removed in the future, use Logger::builder() instead

Constructs a LoggerBuilder.

Sets the name of the logger.

This parameter is optional, and defaults to None.

Requirements

A logger name should not contain any of these characters: , = * ? $ { } " ' ;, and cannot start or end with a whitespace.

Otherwise, LoggerBuilder::build will return an error.

Sets the log filter level.

This parameter is optional, and defaults to LevelFilter::MoreSevereEqual(Level::Info).

Add a Sink.

Add multiple Sinks.

Sets the flush level filter.

This paramter is optional, and defaults to LevelFilter::Off.

See the documentation of Logger::set_flush_level_filter for the description of this parameter.

Sets the error handler.

This parameter is optional, and defaults to None.

See the documentation of Logger::set_error_handler for the description of this parameter.

Builds a Logger.

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The alignment of pointer.
The type for initializers.
Initializes a with the given initializer. Read more
Dereferences the given pointer. Read more
Mutably dereferences the given pointer. Read more
Drops the object pointed to by the given pointer. Read more
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.