use std::fmt;
use crate::append::rolling_file::LogFile;
#[cfg(feature = "config_parsing")]
use crate::config::Deserializable;
#[cfg(feature = "compound_policy")]
pub mod compound;
pub trait Policy: Sync + Send + 'static + fmt::Debug {
fn process(&self, log: &mut LogFile) -> anyhow::Result<()>;
fn is_pre_process(&self) -> bool;
}
#[cfg(feature = "config_parsing")]
impl Deserializable for dyn Policy {
fn name() -> &'static str {
"policy"
}
}