pub struct Program<S, M> {
pub init: fn() -> (S, Cmd<M>),
pub update: fn(&mut S, M) -> Cmd<M>,
pub subscriptions: fn(&S) -> Sub<M>,
}Expand description
Elm Program — init, update, subscriptions (fn-pointer path).
Fields§
§init: fn() -> (S, Cmd<M>)§update: fn(&mut S, M) -> Cmd<M>§subscriptions: fn(&S) -> Sub<M>Implementations§
Auto Trait Implementations§
impl<S, M> Freeze for Program<S, M>
impl<S, M> RefUnwindSafe for Program<S, M>
impl<S, M> Send for Program<S, M>
impl<S, M> Sync for Program<S, M>
impl<S, M> Unpin for Program<S, M>
impl<S, M> UnsafeUnpin for Program<S, M>
impl<S, M> UnwindSafe for Program<S, M>
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