pub struct StateCell<T> { /* private fields */ }
Expand description

Track change of value and signal to StateContext. This struct has no method and implements Deref, DerefMut. When inner value is mutable dereferenced, it is marked changed and send signal. This will also send signal when the cell is constructed or dropped.

Implementations§

Create new StateCell with StateContext

Invalidate this StateCell. Send signal to context.

Trait Implementations§

Formats the value using the given formatter. Read more
The resulting type after dereferencing.
Dereferences the value.
Mutably dereferences the value.
Executes the destructor for this type. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.