public static class HistoryBrowserInterface.InsertNodeBeforeCommand extends AbstractUndoableCommand
Modifier and Type | Field and Description |
---|---|
protected Node |
child
The node to be appended.
|
protected Node |
newNextSibling
The node's new next sibling.
|
protected Node |
oldNextSibling
The node's previous next sibling.
|
protected Node |
oldParent
The node's previous parent.
|
protected Node |
parent
The node's new parent.
|
name
Constructor and Description |
---|
InsertNodeBeforeCommand(java.lang.String commandName,
Node parent,
Node sibling,
Node child)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
execute()
Executes this command.
|
void |
redo()
Performs redo for this command.
|
boolean |
shouldExecute()
Tests if the command can be executed.
|
void |
undo()
Performs undo for this command.
|
getName, setName
protected Node oldParent
protected Node oldNextSibling
protected Node newNextSibling
protected Node parent
protected Node child
public void execute()
UndoableCommand
execute
in interface UndoableCommand
execute
in class AbstractUndoableCommand
public void undo()
UndoableCommand
undo
in interface UndoableCommand
undo
in class AbstractUndoableCommand
public void redo()
UndoableCommand
redo
in interface UndoableCommand
redo
in class AbstractUndoableCommand
public boolean shouldExecute()
UndoableCommand
shouldExecute
in interface UndoableCommand
shouldExecute
in class AbstractUndoableCommand
Copyright © 2022 Apache Software Foundation. All Rights Reserved.