Enum stdweb::web::MutationRecord [] [src]

pub enum MutationRecord {
    Attribute {
        target: Node,
        name: String,
        namespace: Option<String>,
        old_value: Option<String>,
    },
    CharacterData {
        target: Node,
        old_data: Option<String>,
    },
    ChildList {
        target: Node,
        inserted_nodes: NodeList,
        removed_nodes: NodeList,
        previous_sibling: Option<Node>,
        next_sibling: Option<Node>,
    },
}

Contains information about an individual change to the DOM.

It is passed to the MutationObserver's callback.

(JavaScript docs)

Variants

One of the target's attributes was changed.

Fields of Attribute

The Node whose attribute changed.

The name of the changed attribute.

The namespace of the changed attribute.

The value of the changed attribute before the change.

The target's data was changed.

Fields of CharacterData

The CharacterData node whose data changed.

The data of the target before the change.

The children of the target were changed.

Fields of ChildList

The Node whose children changed.

The nodes which were inserted. Will be an empty NodeList if no nodes were inserted.

The nodes which were removed. Will be an empty NodeList if no nodes were removed.

The previous sibling of the inserted or removed nodes, or None.

The next sibling of the inserted or removed nodes, or None.

Trait Implementations

impl Debug for MutationRecord
[src]

[src]

Formats the value using the given formatter. Read more

impl Clone for MutationRecord
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl TryFrom<Value> for MutationRecord
[src]

The type returned in the event of a conversion error.

[src]

Performs the conversion.

Auto Trait Implementations