Expand description
This crate provides logging functions and configuration for Bevy apps, and automatically configures platform specific log handlers (i.e. Wasm or Android).
The macros provided for logging are reexported from tracing
,
and behave identically to it.
By default, the LogPlugin
from this crate is included in Bevy’s DefaultPlugins
and the logging macros can be used out of the box, if used.
For more fine-tuned control over logging behavior, set up the LogPlugin
or
DefaultPlugins
during app initialization.
Modules§
- prelude
- The log prelude.
- tracing_
subscriber - Utilities for implementing and composing
tracing
subscribers.
Macros§
- debug
- Constructs an event at the debug level.
- debug_
once - Call
debug!
once per call site. - debug_
span - Constructs a span at the debug level.
- error
- Constructs an event at the error level.
- error_
once - Call
error!
once per call site. - error_
span - Constructs a span at the error level.
- info
- Constructs an event at the info level.
- info_
once - Call
info!
once per call site. - info_
span - Constructs a span at the info level.
- once
- Call some expression only once per call site.
- trace
- Constructs an event at the trace level.
- trace_
once - Call
trace!
once per call site. - trace_
span - Constructs a span at the trace level.
- warn
- Constructs an event at the warn level.
- warn_
once - Call
warn!
once per call site. - warn_
span - Constructs a span at the warn level.
Structs§
- Level
- Describes the level of verbosity of a span or event.
- LogPlugin
- Adds logging to Apps. This plugin is part of the
DefaultPlugins
. Adding this plugin will setup a collector appropriate to your target platform:
Constants§
- DEFAULT_
FILTER - The default
LogPlugin
EnvFilter
.
Type Aliases§
- Boxed
Layer - A boxed
Layer
that can be used withLogPlugin
.