pub trait NodeInfo {
// Required methods
fn is_element(&self) -> bool;
fn is_text_node(&self) -> bool;
}
Expand description
Simple trait to provide basic information about the type of an element.
We avoid exposing the full type id, since computing it in the general case would be difficult for Gecko nodes.
Required Methods§
sourcefn is_element(&self) -> bool
fn is_element(&self) -> bool
Whether this node is an element.
sourcefn is_text_node(&self) -> bool
fn is_text_node(&self) -> bool
Whether this node is a text node.