Trait cushy::styles::ContextFreeComponent
source · pub trait ContextFreeComponent: ComponentDefinition {
// Required method
fn default(&self) -> Self::ComponentType;
// Provided methods
fn probe(self) -> ComponentProbe<Self> { ... }
fn probe_wrapping(self, child: impl MakeWidget) -> ComponentProbe<Self> { ... }
}
Expand description
A ComponentDefinition
that can provide a default value without access to
a runtime context.
Required Methods§
sourcefn default(&self) -> Self::ComponentType
fn default(&self) -> Self::ComponentType
Returns the default value for this component.
Provided Methods§
sourcefn probe(self) -> ComponentProbe<Self>
fn probe(self) -> ComponentProbe<Self>
Returns a new probe that provides access to the runtime value of this component.
sourcefn probe_wrapping(self, child: impl MakeWidget) -> ComponentProbe<Self>
fn probe_wrapping(self, child: impl MakeWidget) -> ComponentProbe<Self>
Returns a new probe wrapping child
that provides access to the runtime
value of this component.
Object Safety§
This trait is not object safe.