pub struct NodeAttribute {
pub value: Option<String>,
pub offset: usize,
}Expand description
§Node attribute
The value is the value of the attribute at after ‘=’ sign, including quotes.
The ‘=’ sign must be immediately followed by the attribute name, otherwise it will be ignored.
§Boundary cases
-
The value is
Noneif there is not ‘=’ sign. -
The value is
Some("".to_string())if the ‘=’ sign is followed by a space.
Fields§
§value: Option<String>include quote
offset: usizestart offset of attribute name
Implementations§
Source§impl NodeAttribute
impl NodeAttribute
Trait Implementations§
Source§impl Clone for NodeAttribute
impl Clone for NodeAttribute
Source§fn clone(&self) -> NodeAttribute
fn clone(&self) -> NodeAttribute
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for NodeAttribute
impl Debug for NodeAttribute
Source§impl PartialEq for NodeAttribute
impl PartialEq for NodeAttribute
impl StructuralPartialEq for NodeAttribute
Auto Trait Implementations§
impl Freeze for NodeAttribute
impl RefUnwindSafe for NodeAttribute
impl Send for NodeAttribute
impl Sync for NodeAttribute
impl Unpin for NodeAttribute
impl UnwindSafe for NodeAttribute
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)