Enum Node

Source
pub enum Node {
    Element(Element),
    Text(String),
    Fragment(Vec<Node>),
}

Variants§

§

Element(Element)

§

Text(String)

§

Fragment(Vec<Node>)

Implementations§

Source§

impl Node

Source

pub fn as_element_mut(&mut self) -> Option<&mut Element>

Source

pub fn append_child(&mut self, node: Node)

Trait Implementations§

Source§

impl Display for Node

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl From<&&str> for Node

Source§

fn from(value: &&str) -> Self

Converts to this type from the input type.
Source§

impl From<&String> for Node

Source§

fn from(value: &String) -> Self

Converts to this type from the input type.
Source§

impl From<&str> for Node

Source§

fn from(value: &str) -> Self

Converts to this type from the input type.
Source§

impl<I, F, R> From<Map<I, F>> for Node
where I: Iterator, F: FnMut(I::Item) -> R, R: Into<Node>, Vec<Node>: FromIterator<R>,

Source§

fn from(iter: Map<I, F>) -> Self

Converts to this type from the input type.
Source§

impl From<String> for Node

Source§

fn from(value: String) -> Self

Converts to this type from the input type.
Source§

impl<T: ToString> From<Vec<T>> for Node

Source§

fn from(value: Vec<T>) -> Self

Converts to this type from the input type.
Source§

impl From<bool> for Node

Source§

fn from(value: bool) -> Self

Converts to this type from the input type.
Source§

impl From<f32> for Node

Source§

fn from(value: f32) -> Self

Converts to this type from the input type.
Source§

impl From<i32> for Node

Source§

fn from(value: i32) -> Self

Converts to this type from the input type.
Source§

impl From<u32> for Node

Source§

fn from(value: u32) -> Self

Converts to this type from the input type.
Source§

impl FromIterator<i32> for Node

Source§

fn from_iter<T: IntoIterator<Item = i32>>(iter: T) -> Self

Creates a value from an iterator. Read more
Source§

impl FromIterator<u32> for Node

Source§

fn from_iter<T: IntoIterator<Item = u32>>(iter: T) -> Self

Creates a value from an iterator. Read more
Source§

impl FromIterator<u64> for Node

Source§

fn from_iter<T: IntoIterator<Item = u64>>(iter: T) -> Self

Creates a value from an iterator. Read more

Auto Trait Implementations§

§

impl Freeze for Node

§

impl RefUnwindSafe for Node

§

impl Send for Node

§

impl Sync for Node

§

impl Unpin for Node

§

impl UnwindSafe for Node

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Attribute for T
where T: ToString,

Source§

fn value(&self) -> String

Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.