Interface DataTreeModification
- All Superinterfaces:
DataTreeSnapshot
- All Known Subinterfaces:
CursorAwareDataTreeModification
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 Summary
Modifier and TypeMethodDescriptionvoidapplyToCursor(@NonNull DataTreeModificationCursor cursor) Apply the contents of this modification to a cursor.voiddelete(YangInstanceIdentifier path) Delete the node at specified path.voidmerge(YangInstanceIdentifier path, NormalizedNode data) Merge the specified data with the currently-present data at specified path.voidready()Finish creation of a modification, making it ready for application to the data tree.voidwrite(YangInstanceIdentifier path, NormalizedNode data) Replace the data at specified path with supplied data.Methods inherited from interface org.opendaylight.yangtools.yang.data.tree.api.DataTreeSnapshot
modelContext, newModification, readNode, readVersionInfo
-
Method Details
-
delete
Delete the node at specified path.- Parameters:
path- Node path
-
merge
Merge the specified data with the currently-present data at specified path.- Parameters:
path- Node pathdata- Data to be merged
-
write
Replace the data at specified path with supplied data.- Parameters:
path- Node pathdata- 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 exceptapplyToCursor(DataTreeModificationCursor)will result in undefined behavior, possibly with anIllegalStateExceptionbeing thrown. -
applyToCursor
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
-