Struct html5ever_ext::RcDom []

pub struct RcDom {
    pub document: Rc<Node>,
    pub errors: Vec<Cow<'static, str>>,
    pub quirks_mode: QuirksMode,
}

The DOM itself; the result of parsing.

Fields

The Document itself.

Errors that occurred during parsing.

The document's quirks mode.

Trait Implementations

impl Default for RcDom

Returns the "default value" for a type. Read more

impl TreeSink for RcDom

The overall result of parsing. Read more

Consume this sink and return the overall result of parsing. Read more

Handle is a reference to a DOM node. The tree builder requires that a Handle implements Clone to get another reference to the same node. Read more

Signal a parse error.

Get a handle to the Document node.

Get a handle to a template's template contents. The tree builder promises this will never be called with something else than a template element. Read more

Set the document's quirks mode.

Do two handles refer to the same node?

What is the name of this element? Read more

Create an element. Read more

Create a comment node.

Create a Processing Instruction node.

Append a node as the last child of the given node. If this would produce adjacent sibling text nodes, it should concatenate the text instead. Read more

Append a node as the sibling immediately before the given node. Read more

When the insertion point is decided by the existence of a parent node of the element, we consider both possibilities and send the element which will be used if a parent node exists, along with the element to be used if there isn't one. Read more

Append a DOCTYPE element to the Document node.

Add each attribute to the given element, if no attribute with that name already exists. The tree builder promises this will never be called with something else than an element. Read more

Detach the given node from its parent.

Remove all the children from node and append them to new_parent.

Returns true if the adjusted current node is an HTML integration point and the token is a start tag. Read more

Mark a HTML <script> as "already started".

Indicate that a node was popped off the stack of open elements.

Associate the given form-associatable element with the form element

Called whenever the line number changes.

Indicate that a script element is complete.

impl Selectable for RcDom
[src]

[src]

Recursively find element nodes that match this selector. Return true from MatchUser to abort early. The result of this function is true if MatchUser aborted early, or false otherwise. Read more

[src]

Recursively find element nodes that match this selector. Return true from MatchUser to abort early. The result of this function is true if MatchUser aborted early, or false otherwise. Read more

[src]

Returns whether this element matches this selector. For the RcDom and &'a RcDom, is currently always false. Read more

impl Minify for RcDom
[src]

[src]

Identical to impl Debug's fmt() method, except we can't impl Debug for a trait and struct we don't own in this crate.

[src]

Minifies and serializes an instance of an HTML DOM to a writer. If creating AMP pages, set html_head_and_body_tags_are_optional to false. If you need to serialize multiple RcDom or Node objects to the same writer, or need more control, consider using UltraMinifyingHtmlSerializer. Read more

[src]

A debug string representing this node and any children.

[src]

Minifies and serializes an instance of an HTML DOM to file. If creating AMP pages, set html_head_and_body_tags_are_optional to false. If you need to serialize multiple RcDom or Node objects to the same writer, or need more control, consider using UltraMinifyingHtmlSerializer. Read more

[src]

Minifies and serializes an instance of an HTML DOM to String. If creating AMP pages, set html_head_and_body_tags_are_optional to false. If you need to serialize multiple RcDom or Node objects to the same writer, or need more control, consider using UltraMinifyingHtmlSerializer. Read more

Important traits for Vec<u8>
[src]

Minifies and serializes an instance of an HTML DOM to a vector of bytes. If creating AMP pages, set html_head_and_body_tags_are_optional to false. If you need to serialize multiple RcDom or Node objects to the same writer, or need more control, consider using UltraMinifyingHtmlSerializer. Read more

impl QualNameExt for RcDom
[src]

[src]

Is this name effectively local?

[src]

Is this qualified name this local-only name (no prefix, no namespace)

[src]

Is this qualified name on these local-only names (no prefix, no namespace)

[src]

Can this element have children?

[src]

Should an immediate child text node have <, > and & characters escaped? In modern HTML 5, the only common nodes which don't need this are <script> and <style>. In this case, the immediate child text node's content should not contain, say, </script> as this will cause a parse error. Read more

[src]

Can this element's descendant text nodes have leading, trailing and interstitial whitespace collapsed?

impl RcDomExt for RcDom
[src]

[src]

Creates an instance of an HTML DOM from a file path which is verified, stripped and with a sane DocType.

[src]

Creates an instance of an HTML DOM from a file path

[src]

Creates an instance of an HTML DOM from bytes which is verified, stripped and with a sane DocType.

[src]

Creates an instance of an HTML DOM from bytes

[src]

Verify that this HTML DOM is valid.

[src]

Remove all comments and processing instructions and make the DOCTYPE a simple 'html' (for HTML 5).

[src]

Adds this node preceded by a HTML5 DOCTYPE. Panics if the unattached_node is not called 'html'. Read more

[src]

Attaches this node as a child of the document, ie as a root element node

[src]

Moves a node's children to the document node

[src]

Appends a new element node to the document node

[src]

Appends a new element node to the document node

[src]

Appends a new comment node to the document node

[src]

Appends a new processing instruction node to the document node

[src]

Appends a text node to the document node

[src]

Moves a node's children to another parent node

[src]

Moves an existing element node to a parent node

[src]

Moves an existing element before a sibling node

[src]

Appends a new element node to a parent node

[src]

Appends a new element before a sibling node

[src]

Appends a new comment node to a parent node

[src]

Appends a new comment before a sibling node

[src]

Appends a new processing instruction node to a parent node

[src]

Appends a new processing instruction before a sibling node

[src]

Appends a text node to a parent node

[src]

Appends a text node before a sibling node

Auto Trait Implementations

impl !Send for RcDom

impl !Sync for RcDom