pub struct NodeView<'a, V: FromAnyValue = ()> { /* private fields */ }
Expand description
A view into a NodeType with a mask that determines what is visible.
Implementations§
Source§impl<'a, V: FromAnyValue> NodeView<'a, V>
impl<'a, V: FromAnyValue> NodeView<'a, V>
Sourcepub fn new(id: NodeId, node: &'a NodeType<V>, view: &'a NodeMask) -> Self
pub fn new(id: NodeId, node: &'a NodeType<V>, view: &'a NodeMask) -> Self
Create a new NodeView from a VNode, and mask.
Sourcepub fn namespace(&self) -> Option<&'a str>
pub fn namespace(&self) -> Option<&'a str>
Get the tag of the node if the namespace is enabled in the mask
Sourcepub fn attributes<'b>(
&'b self,
) -> Option<impl Iterator<Item = OwnedAttributeView<'a, V>> + 'b>
pub fn attributes<'b>( &'b self, ) -> Option<impl Iterator<Item = OwnedAttributeView<'a, V>> + 'b>
Get any attributes that are enabled in the mask
Trait Implementations§
Auto Trait Implementations§
impl<'a, V> Freeze for NodeView<'a, V>
impl<'a, V> RefUnwindSafe for NodeView<'a, V>where
V: RefUnwindSafe,
impl<'a, V> Send for NodeView<'a, V>where
V: Sync,
impl<'a, V> Sync for NodeView<'a, V>where
V: Sync,
impl<'a, V> Unpin for NodeView<'a, V>
impl<'a, V> UnwindSafe for NodeView<'a, V>where
V: RefUnwindSafe,
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