pub enum Edit {
    Insert(InsertPositionInsertContent),
    Delete(usize),
    TextUpdate(usizeVec<TextChange>),
    AttributeUpdate(usizeVec<AttributeChange>),
}
Expand description

An edit describes a change to an XML document. Nodes are addressed with usize, which is an index into the complete descendants in the tree (including the root node 0) in document order (pre-order). The indexing includes non-element nodes.

Variants§

§

Insert(InsertPositionInsertContent)

Insert content at a given positionf

§

Delete(usize)

Delete content at a given position. The usize is the index of the node to delete.

§

TextUpdate(usizeVec<TextChange>)

Update text content of a node. The precise changes are described by the vector.

§

AttributeUpdate(usizeVec<AttributeChange>)

Update attributes of a node. The precise changes are described by the vector.

Trait Implementations§

Formats the value using the given formatter. Read more
This method tests for self and other values to be equal, and is used by ==.
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.