#[non_exhaustive]pub enum Sink {
Auto,
Stdout,
Stderr,
Journald,
}Expand description
Where to write log events.
Auto (default) emits to the console when stdout is a TTY and to journald
otherwise. Set KAMU_LOG_SINK (auto, stdout, stderr, journald) to
override without code changes. Journald is rejected on targets without
the systemd feature. On wasm32, Auto, Stdout, and Stderr all map to
the JavaScript console.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Auto
TTY → console, non-TTY → journald (on systemd) or stderr (otherwise).
Stdout
Write to stdout.
Stderr
Write to stderr.
Journald
Write to the systemd journal. Requires the systemd feature.
Implementations§
Trait Implementations§
impl Copy for Sink
impl Eq for Sink
impl StructuralPartialEq for Sink
Auto Trait Implementations§
impl Freeze for Sink
impl RefUnwindSafe for Sink
impl Send for Sink
impl Sync for Sink
impl Unpin for Sink
impl UnsafeUnpin for Sink
impl UnwindSafe for Sink
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more