oracle.xml.diff

## Class InsertDiffOp

- java.lang.Object
- - oracle.xml.diff.DiffOp
  - - oracle.xml.diff.InsertDiffOp

All Implemented Interfaces:
  java.lang.Comparable<DiffOp>

    public class InsertDiffOp
    extends DiffOp

InsertDiffOp. Models an insert-before-node diff operation.

### Nested Class Summary

### Nested classes/interfaces inherited from class oracle.xml.diff.DiffOp

`DiffOp.Name`

### Method Summary

All Methods Instance Methods Concrete Methods
`Node` `getCurrent()` Returns the node to be deleted, for a delete `DiffOp`.
`java.lang.String` `getCurrentXPath()` Returns the XPath to the node to be deleted, for a delete `DiffOp`.
`Node` `getNew()` Returns the node to be inserted or appended, for an insert or append `DiffOp`.
`DiffOp.Name` `getOpName()` Returns the name of the diff operation, one of: append-node, insert-before-node, or delete-node.
`Node` `getParent()` Returns the parent node, for an append `DiffOp`.
`java.lang.String` `getParentXPath()` Returns the parent node XPath, for an append `DiffOp`.
`Node` `getSibling()` Returns the node to be inserted before, for an insert `DiffOp`
`java.lang.String` `getSiblingXPath()` Returns the XPath to the node to be inserted before, for an insert `DiffOp`.

### Methods inherited from class oracle.xml.diff.DiffOp

`compareTo, getPrefixToNamespace`

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Method Detail

#### getOpName

    public DiffOp.Name getOpName()

Description copied from class: `DiffOp`
Returns the name of the diff operation, one of: append-node, insert-before-node, or delete-node.

Specified by:
  `getOpName` in class `DiffOp`
Returns:
  `Name` containing the name of the diff operation, one of: `Name.INSERT_BY_APPENDING, Name.INSERT_BEFORE_NODE, Name.DELETE`

#### getCurrent

    public Node getCurrent()
                    throws java.lang.Exception

Description copied from class: `DiffOp`
Returns the node to be deleted, for a delete `DiffOp`.

Specified by:
  `getCurrent` in class `DiffOp`
Returns:
  `Node` to be deleted
Throws:
  `java.lang.Exception`

#### getNew

    public Node getNew()
                throws java.lang.Exception

Description copied from class: `DiffOp`
Returns the node to be inserted or appended, for an insert or append `DiffOp`.

Specified by:
  `getNew` in class `DiffOp`
Returns:
  `Node` to be appended or inserted
Throws:
  `java.lang.Exception`

#### getSibling

    public Node getSibling()
                    throws java.lang.Exception

Description copied from class: `DiffOp`
Returns the node to be inserted before, for an insert `DiffOp`

Specified by:
  `getSibling` in class `DiffOp`
Returns:
  `Node` to be inserted before
Throws:
  `java.lang.Exception`

#### getParent

    public Node getParent()
                   throws java.lang.Exception

Description copied from class: `DiffOp`
Returns the parent node, for an append `DiffOp`.

Specified by:
  `getParent` in class `DiffOp`
Returns:
  parent `Node` that the new child will be appended to
Throws:
  `java.lang.Exception`

#### getParentXPath

    public java.lang.String getParentXPath()
                                    throws java.lang.Exception

Description copied from class: `DiffOp`
Returns the parent node XPath, for an append `DiffOp`. Whether or not the XPath info is available is controlled by `Options`. The `includeXPaths(...)` methods of `Options` control the current setting of this option, and allow setting it to a new value. Including XPath info adds to the memory use and the computational cost. For maxiumum performance, this option should be turned off.

Specified by:
  `getParentXPath` in class `DiffOp`
Returns:
  `String` representing the XPath to the parent node, `null` if it is not available
Throws:
  `java.lang.Exception`

#### getSiblingXPath

    public java.lang.String getSiblingXPath()
                                     throws java.lang.Exception

Description copied from class: `DiffOp`
Returns the XPath to the node to be inserted before, for an insert `DiffOp`. Whether or not the XPath info is available is controlled by `Options`. The `includeXPaths(...)` methods of `Options` control the current setting of this option, and allow setting it to a new value. Including XPath info adds to the memory use and computational cost. For maxiumum performance, this option should be turned off.

Specified by:
  `getSiblingXPath` in class `DiffOp`
Returns:
  `String` representing the XPath to the node to be inserted before, `null` if it is not available
Throws:
  `java.lang.Exception`

#### getCurrentXPath

    public java.lang.String getCurrentXPath()
                                     throws java.lang.Exception

Description copied from class: `DiffOp`
Returns the XPath to the node to be deleted, for a delete `DiffOp`. Whether or not the XPath info is available is controlled by `Options`. The `includeXPaths(...)` methods of `Options` control the current setting of this option, and allow setting it to a new value. Including XPath info adds to the memory use and computational cost. For maxiumum performance, this option should be turned off.

Specified by:
  `getCurrentXPath` in class `DiffOp`
Returns:
  `String` representing the XPath to the node to be deleted, `null` if it's not available
Throws:
  `java.lang.Exception`

Copyright © 2003, 2019, Oracle and/or its affiliates. All rights reserved.
Use is subject to license terms. Also see the documentation redistribution policy.
ORACLE CONFIDENTIAL
For authorized use only.
Do not distribute to third parties.