Struct amethyst::Logger [−][src]
Allows the creation of a custom logger with a set of custom configurations. If no custom
formatting or configuration is required start_logger
can be used instead.
Examples
amethyst::Logger::from_config(Default::default()) .level_for("gfx_device_gl", amethyst::LogLevelFilter::Warn) .level_for("gfx_glyph", amethyst::LogLevelFilter::Error) .start(); amethyst::Logger::from_config_formatter(Default::default(), |out, message, record| { out.finish(format_args!( "[{level}][{target}] {message}", level = record.level(), target = record.target(), message = message, )) }).start();
Implementations
impl Logger
[src]
pub fn from_config(config: LoggerConfig) -> Self
[src]
Create a new Logger from LoggerConfig
pub fn from_config_formatter<F>(config: LoggerConfig, formatter: F) -> Self where
F: Fn(FormatCallback<'_>, &Arguments<'_>, &Record<'_>) + Sync + Send + 'static,
[src]
F: Fn(FormatCallback<'_>, &Arguments<'_>, &Record<'_>) + Sync + Send + 'static,
Create a new Logger from LoggerConfig
and a formatter
pub fn level_for<T: Into<Cow<'static, str>>>(
self,
module: T,
level: LevelFilter
) -> Self
[src]
self,
module: T,
level: LevelFilter
) -> Self
Set individual log levels for modules.
pub fn start(self)
[src]
Starts Logger
by consuming it.
Auto Trait Implementations
impl !RefUnwindSafe for Logger
[src]
impl Send for Logger
[src]
impl !Sync for Logger
[src]
impl Unpin for Logger
[src]
impl !UnwindSafe for Logger
[src]
Blanket Implementations
impl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
T: Component + Float,
D: AdaptFrom<S, Swp, Dwp, T>,
Swp: WhitePoint,
Dwp: WhitePoint,
[src]
T: Component + Float,
D: AdaptFrom<S, Swp, Dwp, T>,
Swp: WhitePoint,
Dwp: WhitePoint,
pub fn adapt_into_using<M>(self, method: M) -> D where
M: TransformMatrix<Swp, Dwp, T>,
[src]
M: TransformMatrix<Swp, Dwp, T>,
pub fn adapt_into(self) -> D
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Any for T where
T: Any,
T: Any,
pub fn get_type_id(&self) -> TypeId
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Pointable for T
pub const ALIGN: usize
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
pub unsafe fn drop(ptr: usize)
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> SetParameter for T
pub fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
T: Parameter<Self>,
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
SS: SubsetOf<SP>,
pub fn to_subset(&self) -> Option<SS>
pub fn is_in_subset(&self) -> bool
pub unsafe fn to_subset_unchecked(&self) -> SS
pub fn from_subset(element: &SS) -> SP
impl<T> Supports<T> for T
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,