pub struct State<T, N>where
N: ComposeNode,{
pub id: StateId,
/* private fields */
}Fields§
§id: StateIdImplementations§
Source§impl<T, N> State<T, N>where
T: 'static,
N: ComposeNode,
impl<T, N> State<T, N>where
T: 'static,
N: ComposeNode,
pub fn with<F, U>(&self, func: F) -> U
pub fn with_untracked<F, U>(&self, func: F) -> U
pub fn with_mut<F, U>(&self, func: F) -> U
pub fn with_mut_untracked<F, U>(&self, func: F) -> U
pub fn get(&self) -> Twhere
T: Clone,
pub fn get_untracked(&self) -> Twhere
T: Clone,
pub fn set(&self, value: T)
Trait Implementations§
Source§impl<T, N> Clone for State<T, N>where
N: ComposeNode,
impl<T, N> Clone for State<T, N>where
N: ComposeNode,
Source§impl<T, N> Debug for State<T, N>where
N: ComposeNode,
impl<T, N> Debug for State<T, N>where
N: ComposeNode,
impl<T, N> Copy for State<T, N>where
N: ComposeNode,
Auto Trait Implementations§
impl<T, N> Freeze for State<T, N>
impl<T, N> !RefUnwindSafe for State<T, N>
impl<T, N> !Send for State<T, N>
impl<T, N> !Sync for State<T, N>
impl<T, N> Unpin for State<T, N>
impl<T, N> !UnwindSafe for State<T, N>
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