Struct log4rs::append::rolling_file::policy::compound::roll::fixed_window::FixedWindowRollerBuilder
source · [−]pub struct FixedWindowRollerBuilder { /* private fields */ }
Expand description
A builder for the FixedWindowRoller
.
Implementations
sourceimpl FixedWindowRollerBuilder
impl FixedWindowRollerBuilder
sourcepub fn base(self, base: u32) -> FixedWindowRollerBuilder
pub fn base(self, base: u32) -> FixedWindowRollerBuilder
Sets the base index for archived log files.
Defaults to 0.
sourcepub fn build(
self,
pattern: &str,
count: u32
) -> Result<FixedWindowRoller, Box<dyn Error + Sync + Send>>
pub fn build(
self,
pattern: &str,
count: u32
) -> Result<FixedWindowRoller, Box<dyn Error + Sync + Send>>
Constructs a new FixedWindowRoller
.
pattern
must contain at least one instance of {}
, all of which will
be replaced with an archived log file’s index.
If the file extension of the pattern is .gz
and the gzip
Cargo
feature is enabled, the archive files will be gzip-compressed.
Auto Trait Implementations
impl RefUnwindSafe for FixedWindowRollerBuilder
impl Send for FixedWindowRollerBuilder
impl Sync for FixedWindowRollerBuilder
impl Unpin for FixedWindowRollerBuilder
impl UnwindSafe for FixedWindowRollerBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more