FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    TreeDataGridBindingAccessor

    struct · ferroui-controls-treedatagrid · v0.5.0

    struct TreeDataGridBindingAccessor
    

    The accessor of the value a binding selects from a model (TreeDataGridBindingAccessor).

    View source

    Members

    new

    fn new(binding: &Rc<dyn BindingBase>, sample_model: Option<&BoxedValue>) -> Rc<Self>
    

    The accessor of binding; sample_model is a model of the items, whose value tells whether the value can be null and, for a reflection binding, the type of the value.

    Source

    can_write

    fn can_write(self: &Self) -> bool
    

    Whether the binding writes values back to the model (CanWrite).

    Source

    fn links(self: &Self) -> Vec<ObjectLink>
    

    The objects on the binding's path whose changes the column observes (Links): the model, then the owner of each member read below it.

    Source

    sample_value_was_null

    fn sample_value_was_null(self: &Self) -> bool
    

    Whether the value of the sample model was null (SampleValueWasNull).

    Source

    value_type

    fn value_type(self: &Self) -> Option<ValueType>
    

    The type of the value: the type the binding's path declares, or the type of the first value read (ValueType).

    Source

    try_create_text_selector

    fn try_create_text_selector(binding: Option<&Rc<dyn BindingBase>>) -> Option<Rc<dyn Fn(&BoxedValue) -> Option<String>>>
    

    The selector of the text binding selects from a model, if there is a binding (TryCreateTextSelector).

    Source

    read

    fn read(self: &Self, model: &BoxedValue) -> Option<BoxedValue>
    

    The value the binding selects from model (Read).

    Source

    read_as_string

    fn read_as_string(self: &Self, model: &BoxedValue) -> Option<String>
    

    The text of the value (ReadAsString: ToString() of the value).

    Source

    read_as_boolean

    fn read_as_boolean(self: &Self, model: &BoxedValue) -> bool
    

    The value as a boolean, false for null (ReadAsBoolean).

    Source

    read_as_nullable_boolean

    fn read_as_nullable_boolean(self: &Self, model: &BoxedValue) -> Option<bool>
    

    The value as a nullable boolean (ReadAsNullableBoolean).

    Source

    write

    fn write(self: &Self, model: &BoxedValue, value: Option<BoxedValue>)
    

    Writes value to model through the binding, converted to the type of the value (Write); nothing when the binding does not write back.

    Source

    dispose

    fn dispose(self: &Self)
    

    Ends the binding (Dispose).

    Source

    Trait implementations

    • Send
    • Sync
    • Freeze
    • UnsafeUnpin
    • Unpin
    • UnwindSafe
    • RefUnwindSafe
    • Borrow<T>
    • BorrowMut<T>
    • Into<U>
    • From<T>
    • TryInto<U>
    • TryFrom<U>
    • Any
    • ClassDefaults
    • ErasedDestructor
    • IntoEither
    • Drop

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.