Trait ViewState

Source
pub trait ViewState:
    Send
    + Sync
    + 'static {
    // Required method
    fn new() -> Self;
}
Expand description

A trait for view state.

This trait is implemented by types that represent the state of a view. It provides a method for creating a new instance of the state.

Required Methods§

Source

fn new() -> Self

Create a new instance of the view state.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§