pub struct Hive { /* private fields */ }
Expand description
The place where all of your commands are living
Implementations§
Source§impl Hive
impl Hive
Sourcepub async fn halt(&mut self, id: &str) -> Result<()>
pub async fn halt(&mut self, id: &str) -> Result<()>
Stop, kill, murder… Just when you want to stop a command
Sourcepub async fn spawn(&mut self, id: &str, cmd: Command) -> Result<()>
pub async fn spawn(&mut self, id: &str, cmd: Command) -> Result<()>
Create a new command that will live in the hive and work for you until his death
Sourcepub async fn processes_info(&self) -> HashMap<String, ProcInfo>
pub async fn processes_info(&self) -> HashMap<String, ProcInfo>
Information of all processes. The returned data is cloned from the internal registry so don’t call it so often if your process list is huge
Auto Trait Implementations§
impl Freeze for Hive
impl !RefUnwindSafe for Hive
impl Send for Hive
impl Sync for Hive
impl Unpin for Hive
impl !UnwindSafe for Hive
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