pub struct Florestad { /* private fields */ }Implementations§
Source§impl Florestad
impl Florestad
Sourcepub async fn stop(&self)
pub async fn stop(&self)
Kills a running florestad, this will return as soon as the main node stops.
It’s not safe to stop your program before this thread returns because some information may not be fully flushed to disk yet, and killing the process before flushing everything is equivalent to an unclean shutdown.
pub async fn should_stop(&self) -> bool
pub fn get_stop_signal(&self) -> Arc<RwLock<bool>>
pub async fn wait_shutdown(&self)
Sourcepub async fn start(&self)
pub async fn start(&self)
Actually runs florestad, spawning all modules and waiting until someone asks to stop.
pub fn from_config(config: Config) -> Self
pub fn new() -> Self
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for Florestad
impl !RefUnwindSafe for Florestad
impl Send for Florestad
impl Sync for Florestad
impl Unpin for Florestad
impl !UnwindSafe for Florestad
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more