pub struct Attribute<'a> {
pub name: Cow<'a, str>,
pub value: Option<Cow<'a, str>>,
}Expand description
A single HTML attribute (name-value pair).
Fields§
§name: Cow<'a, str>Attribute name, borrowed from input.
value: Option<Cow<'a, str>>Attribute value, entity-decoded if needed.
None for boolean attributes (e.g. disabled).
Trait Implementations§
impl<'a> StructuralPartialEq for Attribute<'a>
Auto Trait Implementations§
impl<'a> Freeze for Attribute<'a>
impl<'a> RefUnwindSafe for Attribute<'a>
impl<'a> Send for Attribute<'a>
impl<'a> Sync for Attribute<'a>
impl<'a> Unpin for Attribute<'a>
impl<'a> UnsafeUnpin for Attribute<'a>
impl<'a> UnwindSafe for Attribute<'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