pub struct SystemLog { /* private fields */ }Expand description
An opened system log.
Implementations§
Source§impl SystemLog
impl SystemLog
Sourcepub fn from_config_dir(
config_dir: &Path,
lookup: impl Fn(&str) -> Option<String>,
) -> Result<Option<Self>, Error>
pub fn from_config_dir( config_dir: &Path, lookup: impl Fn(&str) -> Option<String>, ) -> Result<Option<Self>, Error>
The system log logging.yaml in config_dir declares, opened for
appending; None when there is no file or it declares none.
Sourcepub fn from_config_dir_for_startup(
config_dir: &Path,
lookup: impl Fn(&str) -> Option<String>,
run_mode: RunMode,
) -> Result<Option<Self>, Error>
pub fn from_config_dir_for_startup( config_dir: &Path, lookup: impl Fn(&str) -> Option<String>, run_mode: RunMode, ) -> Result<Option<Self>, Error>
Open at process startup. An opted-in reset belongs only to the master or standalone process; workers always append, including replacements.
Sourcepub fn from_configuration(
config: SystemLogConfig,
run_mode: RunMode,
) -> Result<Self, Error>
pub fn from_configuration( config: SystemLogConfig, run_mode: RunMode, ) -> Result<Self, Error>
Open an explicitly configured system log without reading another file.
Sourcepub fn check_config_dir(
config_dir: &Path,
lookup: impl Fn(&str) -> Option<String>,
) -> Result<(), Error>
pub fn check_config_dir( config_dir: &Path, lookup: impl Fn(&str) -> Option<String>, ) -> Result<(), Error>
What Self::from_config_dir reads, checked and nothing opened: for
a configuration check, which may run as another user than the
service and must not create, or depend on writing, the service’s
files.
Auto Trait Implementations§
impl Forget for SystemLog
impl Freeze for SystemLog
impl Move for SystemLog
impl RefUnwindSafe for SystemLog
impl Send for SystemLog
impl Sync for SystemLog
impl Unpin for SystemLog
impl UnsafeUnpin for SystemLog
impl UnwindSafe for SystemLog
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