[−][src]Struct pakr_fsm::Reactor
Reactor is FSM
handle to interact and monitor
Implementations
impl<F: FSM> Reactor<F>
[src]
pub fn new() -> Self
[src]
Create new Reactor
.
Spawns associated FSM
in separate thread, itializes it by calling its new
and setting
state to default
.
pub fn join(self) -> Result<Option<<F as FSM>::Response>>
[src]
Waits for FSM
to complete.
Returns response of the last transition
pub fn send(
&self,
ev: <F as FSM>::Event
) -> Result<(), SendError<<F as FSM>::Event>>
[src]
&self,
ev: <F as FSM>::Event
) -> Result<(), SendError<<F as FSM>::Event>>
Send event to FSM
pub fn get_sender(&self) -> Sender<F::Event>
[src]
Clone send
endpoint of FSM
channel to be used in other places.
Auto Trait Implementations
impl<F> !RefUnwindSafe for Reactor<F>
impl<F> Send for Reactor<F> where
<F as FSM>::Event: Send,
<F as FSM>::Event: Send,
impl<F> !Sync for Reactor<F>
impl<F> Unpin for Reactor<F>
impl<F> !UnwindSafe for Reactor<F>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,