Interface DataTreeModification

All Superinterfaces:
DataTreeSnapshot, EffectiveModelContextProvider
All Known Subinterfaces:
CursorAwareDataTreeModification

public interface DataTreeModification extends DataTreeSnapshot
Class encapsulation of set of modifications to a base tree. This tree is backed by a read-only snapshot and tracks modifications on top of that. The modification has the ability to rebase itself to a new snapshot.
  • Method Details

    • delete

      void delete(YangInstanceIdentifier path)
      Delete the node at specified path.
      Parameters:
      path - Node path
    • merge

      void merge(YangInstanceIdentifier path, NormalizedNode data)
      Merge the specified data with the currently-present data at specified path.
      Parameters:
      path - Node path
      data - Data to be merged
    • write

      void write(YangInstanceIdentifier path, NormalizedNode data)
      Replace the data at specified path with supplied data.
      Parameters:
      path - Node path
      data - New node data
    • ready

      void ready()
      Finish creation of a modification, making it ready for application to the data tree. Any calls to this object's methods except applyToCursor(DataTreeModificationCursor) will result in undefined behavior, possibly with an IllegalStateException being thrown.
    • applyToCursor

      void applyToCursor(@NonNull DataTreeModificationCursor cursor)
      Apply the contents of this modification to a cursor. This can be used to replicate this modification onto another one. The cursor's position must match the root of this modification, otherwise performing this operation will result in undefined behavior.
      Parameters:
      cursor - cursor to which this modification