pub struct Attributes<'a> { /* private fields */ }Implementations§
Source§impl<'a> Attributes<'a>
impl<'a> Attributes<'a>
pub fn get(&self, name: &str) -> Option<Attribute>
pub fn get_namespaced( &self, namespace: Option<&str>, local_name: &str, ) -> Option<Attribute>
pub fn contains_name(&self, name: &str) -> bool
pub fn contains_name_namespaced( &self, namespace: Option<&str>, local_name: &str, ) -> bool
pub fn names(&self) -> AttributeNames
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn is_not_empty(&self) -> bool
pub fn toggle(&self, name: &str) -> Result<bool, InvalidAttributeName>
pub fn force_toggle(&self, name: &str) -> Result<bool, InvalidAttributeName>
pub fn remove(&self, name: &str) -> Option<Attribute>
pub fn remove_namespaced( &self, namespace: Option<&str>, local_name: &str, ) -> Option<Attribute>
pub fn remove_node<T>(&self, attribute: &Attribute) -> boolwhere
T: Node,
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Attributes<'a>
impl<'a> RefUnwindSafe for Attributes<'a>
impl<'a> !Send for Attributes<'a>
impl<'a> !Sync for Attributes<'a>
impl<'a> Unpin for Attributes<'a>
impl<'a> UnwindSafe for Attributes<'a>
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