pub struct DeriveItem<TMsg, TStore>{
pub store: TStore,
pub fn_input: fn(msg: &Message<TMsg>, store: &mut TStore),
pub fn_output: fn(store: &TStore) -> Option<Vec<Message<TMsg>>>,
}
Expand description
Хранение данных для преобразования
Fields§
§store: TStore
Структура для сохранения промежуточных данных из входящих сообщений
fn_input: fn(msg: &Message<TMsg>, store: &mut TStore)
Обработка входящих сообщений и сохранение в store
fn_output: fn(store: &TStore) -> Option<Vec<Message<TMsg>>>
Формирование исходящих сообщений на основе данных, сохраненных в store
Trait Implementations§
Auto Trait Implementations§
impl<TMsg, TStore> Freeze for DeriveItem<TMsg, TStore>where
TStore: Freeze,
impl<TMsg, TStore> RefUnwindSafe for DeriveItem<TMsg, TStore>where
TStore: RefUnwindSafe,
impl<TMsg, TStore> Send for DeriveItem<TMsg, TStore>
impl<TMsg, TStore> Sync for DeriveItem<TMsg, TStore>
impl<TMsg, TStore> Unpin for DeriveItem<TMsg, TStore>where
TStore: Unpin,
impl<TMsg, TStore> UnwindSafe for DeriveItem<TMsg, TStore>where
TStore: UnwindSafe,
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