pub trait Element {
type Context;
type Node: Node<Element = Self>;
type Attribute: Attribute<Node = Self::Node>;
// Required methods
fn as_node(&self) -> Self::Node;
fn prefix(&self) -> Option<Prefix>;
fn namespace(&self) -> Namespace;
fn local_name(&self) -> LocalName;
fn attributes(
&self,
cx: &mut Self::Context,
) -> impl Iterator<Item = Self::Attribute>;
fn is_html_element_in_html_document(&self) -> bool;
}Required Associated Types§
type Context
type Node: Node<Element = Self>
type Attribute: Attribute<Node = Self::Node>
Required Methods§
fn as_node(&self) -> Self::Node
fn prefix(&self) -> Option<Prefix>
fn namespace(&self) -> Namespace
fn local_name(&self) -> LocalName
fn attributes( &self, cx: &mut Self::Context, ) -> impl Iterator<Item = Self::Attribute>
fn is_html_element_in_html_document(&self) -> bool
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.