Struct OrdersContainer

Source
pub struct OrdersContainer<Ms, Mdl, INodes>
where Ms: 'static, Mdl: 'static, INodes: IntoNodes<Ms>,
{ /* private fields */ }

Implementations§

Source§

impl<Ms, Mdl, INodes> OrdersContainer<Ms, Mdl, INodes>
where INodes: IntoNodes<Ms> + 'static,

Source

pub fn new(app: App<Ms, Mdl, INodes>) -> Self

Trait Implementations§

Source§

impl<Ms, Mdl, INodes> Orders<Ms> for OrdersContainer<Ms, Mdl, INodes>
where Ms: 'static, INodes: IntoNodes<Ms> + 'static,

Source§

type AppMs = Ms

Source§

type Mdl = Mdl

Source§

type INodes = INodes

Source§

fn proxy<ChildMs: 'static>( &mut self, f: impl FnOnce(ChildMs) -> Ms + 'static + Clone, ) -> OrdersProxy<'_, ChildMs, Ms, Mdl, INodes>

Automatically map message type. It allows you to pass Orders into child module. Read more
Source§

fn render(&mut self) -> &mut Self

Schedule web page rerender after model update. It’s the default behaviour.
Source§

fn force_render_now(&mut self) -> &mut Self

Force web page to rerender immediately after model update.
Source§

fn skip(&mut self) -> &mut Self

Don’t rerender web page after model update.
Source§

fn notify(&mut self, message: impl Any + Clone) -> &mut Self

Notify all subscription handlers that listen for messages with the message’s type. Read more
Source§

fn send_msg(&mut self, msg: Ms) -> &mut Self

Invoke function update with the given msg. Read more
Source§

fn perform_cmd<MsU: 'static>( &mut self, cmd: impl Future<Output = MsU> + 'static, ) -> &mut Self

Execute cmd and send its output (if it’s Msg) to update function. Read more
Source§

fn perform_cmd_with_handle<MsU: 'static>( &mut self, cmd: impl Future<Output = MsU> + 'static, ) -> CmdHandle

Execute given cmd and send its output (if it’s Msg) to update function. Read more
Source§

fn clone_app(&self) -> App<Self::AppMs, Self::Mdl, Self::INodes>

Get app instance. Cloning is cheap because App contains only Rc fields.
Source§

fn msg_mapper(&self) -> Rc<dyn Fn(Ms) -> Self::AppMs>

Get the function that maps module’s Msg to app’s (root’s) one. Read more
Source§

fn after_next_render<MsU: 'static>( &mut self, callback: impl FnOnce(RenderInfo) -> MsU + 'static, ) -> &mut Self

Register the callback that will be executed after the next render. Read more
Source§

fn subscribe<MsU: 'static, SubMs: 'static + Clone>( &mut self, handler: impl FnOnce(SubMs) -> MsU + Clone + 'static, ) -> &mut Self

Subscribe for messages with the handlers input type. Read more
Source§

fn subscribe_with_handle<MsU: 'static, SubMs: 'static + Clone>( &mut self, handler: impl FnOnce(SubMs) -> MsU + Clone + 'static, ) -> SubHandle

Subscribe for messages with the handlers input type. Read more
Source§

fn stream<MsU: 'static>( &mut self, stream: impl Stream<Item = MsU> + 'static, ) -> &mut Self

Stream Msg, Option<Msg> or (). Read more
Source§

fn stream_with_handle<MsU: 'static>( &mut self, stream: impl Stream<Item = MsU> + 'static, ) -> StreamHandle

Stream Msg, Option<Msg> or (). Read more
Source§

fn msg_sender(&self) -> Rc<dyn Fn(Option<Ms>)>

Get the function that invokes your update function. The most common use-case is passing the function into callbacks. Read more
Source§

fn clone_base_path(&self) -> Rc<[String]>

Cheap clone base path loaded from element <base href="/base/path/">. Read more

Auto Trait Implementations§

§

impl<Ms, Mdl, INodes> Freeze for OrdersContainer<Ms, Mdl, INodes>

§

impl<Ms, Mdl, INodes> !RefUnwindSafe for OrdersContainer<Ms, Mdl, INodes>

§

impl<Ms, Mdl, INodes> !Send for OrdersContainer<Ms, Mdl, INodes>

§

impl<Ms, Mdl, INodes> !Sync for OrdersContainer<Ms, Mdl, INodes>

§

impl<Ms, Mdl, INodes> Unpin for OrdersContainer<Ms, Mdl, INodes>
where Ms: Unpin,

§

impl<Ms, Mdl, INodes> !UnwindSafe for OrdersContainer<Ms, Mdl, INodes>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V