public abstract class ReplaceNodeCommand<T extends Node> extends AbstractCommand
| Modifier and Type | Field and Description |
|---|---|
Object |
_new |
NodePath |
_nodePath |
Object |
_old |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
addNode(Document doc,
T node)
Adds the given node to the data model.
|
void |
execute(Document document)
Called to execute the command against the given document.
|
protected abstract T |
readNode(Document doc,
Object node)
Unmarshalls a node into the appropriate type.
|
protected abstract void |
removeNode(Document doc,
T node)
Removes the given node from the data model.
|
void |
undo(Document document)
Called to undo the command (restore the document to a previous state).
|
isNullOrUndefined, typepublic void execute(Document document)
ICommandpublic void undo(Document document)
ICommandprotected abstract void removeNode(Document doc, T node)
protected abstract void addNode(Document doc, T node)
Copyright © 2019 Red Hat. All rights reserved.