pub struct ReflectionIndexerNode { /* private fields */ }Expand description
A node that reads a value through the indexer the source’s type declared
in its binding metadata or its markup metadata
([2], [key], [1,2]), following the change notifications of the
source.
The arguments are the text of the binding path; they are converted to the declared types of the index parameters each time the source changes.
Implementations§
Trait Implementations§
Source§impl CollectionNode for ReflectionIndexerNode
impl CollectionNode for ReflectionIndexerNode
fn collection_base(&self) -> &CollectionNodeBase
Source§fn should_update(&self, _source: &BoxedValue, property_name: &str) -> bool
fn should_update(&self, _source: &BoxedValue, property_name: &str) -> bool
Whether a property change notification of the source for
property_name affects the value of the node.Source§fn try_get_first_argument_as_int(&self) -> Option<i32>
fn try_get_first_argument_as_int(&self) -> Option<i32>
The first argument of the node as an integer, if it is one.
Source§fn update_value(&self, source: &BoxedValue) -> Result<(), BindingError>
fn update_value(&self, source: &BoxedValue) -> Result<(), BindingError>
Reads the value from the source. An error is what the getter of a
managed indexer throws.
Source§impl Drop for ReflectionIndexerNode
impl Drop for ReflectionIndexerNode
Source§impl ExpressionNode for ReflectionIndexerNode
impl ExpressionNode for ReflectionIndexerNode
fn state(&self) -> &NodeState
Source§fn build_string(&self, builder: &mut String)
fn build_string(&self, builder: &mut String)
Appends a string representation of the node to
builder.Source§fn on_source_changed(
&self,
source: Option<&BoxedValue>,
_data_validation_error: Option<&BindingError>,
)
fn on_source_changed( &self, source: Option<&BoxedValue>, _data_validation_error: Option<&BindingError>, )
Subscribes to the new source and updates the current value.
Source§fn unsubscribe(&self, old_source: &BoxedValue)
fn unsubscribe(&self, old_source: &BoxedValue)
Unsubscribes from the previous source.
fn as_settable(&self) -> Option<&dyn ISettableNode>
Source§fn build_string_with_nodes(
&self,
builder: &mut String,
nodes: &[Rc<dyn ExpressionNode>],
)
fn build_string_with_nodes( &self, builder: &mut String, nodes: &[Rc<dyn ExpressionNode>], )
Builds a string representation of the binding path up to this node.
fn as_property_accessor_node(&self) -> Option<&dyn IPropertyAccessorNode>
fn as_source_node(&self) -> Option<&dyn SourceNode>
Source§fn is_data_context_node(&self) -> bool
fn is_data_context_node(&self) -> bool
Whether the node reads a data context.
Source§impl ISettableNode for ReflectionIndexerNode
impl ISettableNode for ReflectionIndexerNode
Source§fn value_type(&self) -> Option<ValueType>
fn value_type(&self) -> Option<ValueType>
The type of the value accepted by the node, or
None if the node is
not currently settable.Source§fn write_value_to_source(
&self,
value: Option<&BoxedValue>,
_nodes: &[Rc<dyn ExpressionNode>],
) -> Result<bool, BindingError>
fn write_value_to_source( &self, value: Option<&BoxedValue>, _nodes: &[Rc<dyn ExpressionNode>], ) -> Result<bool, BindingError>
Tries to write the specified value to the source.
Auto Trait Implementations§
impl !Freeze for ReflectionIndexerNode
impl !RefUnwindSafe for ReflectionIndexerNode
impl !Send for ReflectionIndexerNode
impl !Sync for ReflectionIndexerNode
impl !UnwindSafe for ReflectionIndexerNode
impl Unpin for ReflectionIndexerNode
impl UnsafeUnpin for ReflectionIndexerNode
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
Source§impl<T> ClassDefaults for Twhere
T: ?Sized,
impl<T> ClassDefaults for Twhere
T: ?Sized,
Source§fn static_constructor()
fn static_constructor()
The static constructor of a type: work done once per thread, after
the properties of the type are registered and before its first
instance exists (class handlers,
affects_render, metadata
overrides). Read more