pub struct Service { /* private fields */ }Expand description
Represents a service on the system
Implementations§
Source§impl Service
impl Service
Sourcepub fn systemd_path(&self) -> PathBuf
pub fn systemd_path(&self) -> PathBuf
The systemd path for linux
Sourcepub fn stop(&mut self) -> Result<(), StartStopError>
pub fn stop(&mut self) -> Result<(), StartStopError>
Stop the service
Sourcepub fn start(&mut self) -> Result<(), StartStopError>
pub fn start(&mut self) -> Result<(), StartStopError>
Start the service
Sourcepub fn create(&mut self, config: ServiceConfig) -> Result<(), CreateError>
pub fn create(&mut self, config: ServiceConfig) -> Result<(), CreateError>
Create the service
Auto Trait Implementations§
impl Freeze for Service
impl RefUnwindSafe for Service
impl Send for Service
impl Sync for Service
impl Unpin for Service
impl UnwindSafe for Service
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