pub struct AppStateCpt<CS>where
CS: EzState,{ /* private fields */ }Expand description
Trait Implementations§
Source§impl<CID, CA, CS, CM> Component<CID, CA, CS, CM> for AppStateCpt<CS>
impl<CID, CA, CS, CM> Component<CID, CA, CS, CM> for AppStateCpt<CS>
Source§fn tick(&mut self, state: &mut State<CS>) -> Vec<EzEvent<CID, CM>>
fn tick(&mut self, state: &mut State<CS>) -> Vec<EzEvent<CID, CM>>
Method called on every tick. You should implement it only if you need to save a reference to the state or if your business logic needs to execute some code on a regular basis.
Source§fn on_event(
&mut self,
_event: EzEvent<CID, CM>,
state: &mut State<CS>,
) -> Vec<EzEvent<CID, CM>>
fn on_event( &mut self, _event: EzEvent<CID, CM>, state: &mut State<CS>, ) -> Vec<EzEvent<CID, CM>>
Method to implement to handle events.
The component will receive any event if it is focused; but only events it is subscribed to otherwise.
Source§impl<CS> Debug for AppStateCpt<CS>
impl<CS> Debug for AppStateCpt<CS>
Source§impl<CS> Default for AppStateCpt<CS>where
CS: EzState,
impl<CS> Default for AppStateCpt<CS>where
CS: EzState,
Source§impl<CS> MockComponent for AppStateCpt<CS>where
CS: EzState,
impl<CS> MockComponent for AppStateCpt<CS>where
CS: EzState,
Auto Trait Implementations§
impl<CS> Freeze for AppStateCpt<CS>
impl<CS> RefUnwindSafe for AppStateCpt<CS>
impl<CS> Send for AppStateCpt<CS>
impl<CS> Sync for AppStateCpt<CS>
impl<CS> Unpin for AppStateCpt<CS>
impl<CS> UnsafeUnpin for AppStateCpt<CS>
impl<CS> UnwindSafe for AppStateCpt<CS>
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