pub enum InternalEvent {
RegisterTask(JoinHandle<()>),
LogTweet(String),
LogError(Error),
}Expand description
NB: not totally comfortable with this event bus architecture; the loose coupling is convenient but it introduces non-deterministic delay, and feels overly general (over time I guess there will end up being too many enum variants.
Try to keep the scope limited to actually global events; for component-to-component events, consider directly coupling those pieces together.
Variants§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for InternalEvent
impl RefUnwindSafe for InternalEvent
impl Send for InternalEvent
impl Sync for InternalEvent
impl Unpin for InternalEvent
impl UnwindSafe for InternalEvent
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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