/** * Executes the given compound update command. * * @param command * The given compound update command */ public void performCompoundUpdateCommand(UndoableCommand command) { historyBrowser.addCommand(command); }
/** * Executes the given compound update command. * * @param command * The given compound update command */ public void performCompoundUpdateCommand(UndoableCommand command) { historyBrowser.addCommand(command); }
/** * Adds and executes the RemoveChild command to the History Browser. * * @param parent * The given parent * @param child * The given child */ public void removeChild(Node parent, Node child) { historyBrowser.addCommand(createRemoveChildCommand(parent, child)); }
/** * Adds and executes the AppendChildCommand to historyBrowser. * * @param parent * The given parent * @param child * The node to be appended */ public void appendChild(Node parent, Node child) { historyBrowser.addCommand(createAppendChildCommand(parent, child)); }
/** * Adds and executes the ChangeNodeValueCommand to historyBrowser. * * @param contextNode * The node whose nodeValue changed * @param newValue * The new node value */ public void setNodeValue(Node contextNode, String newValue) { historyBrowser.addCommand (createChangeNodeValueCommand(contextNode, newValue)); }
/** * Adds and executes the AppendChildCommand to historyBrowser. * * @param parent * The given parent * @param child * The node to be appended */ public void appendChild(Node parent, Node child) { historyBrowser.addCommand(createAppendChildCommand(parent, child)); }
/** * Adds and executes the RemoveChild command to the History Browser. * * @param parent * The given parent * @param child * The given child */ public void removeChild(Node parent, Node child) { historyBrowser.addCommand(createRemoveChildCommand(parent, child)); }
/** * Adds and executes the ChangeNodeValueCommand to historyBrowser. * * @param contextNode * The node whose nodeValue changed * @param newValue * The new node value */ public void setNodeValue(Node contextNode, String newValue) { historyBrowser.addCommand (createChangeNodeValueCommand(contextNode, newValue)); }
/** * Adds the NodeInsertedCommand to historyBrowser. * * @param newParent * New parent node * @param newSibling * New (next) sibling node * @param contextNode * The node to be appended */ public void nodeInserted(Node newParent, Node newSibling, Node contextNode) { historyBrowser.addCommand(createNodeInsertedCommand(newParent, newSibling, contextNode)); }
/** * Adds the NodeRemovedCommand to historyBrowser. * * @param oldParent * The node's old parent * @param oldSibling * The node's old next sibling * @param contextNode * The node to be removed */ public void nodeRemoved(Node oldParent, Node oldSibling, Node contextNode) { historyBrowser.addCommand (createNodeRemovedCommand(oldParent, oldSibling, contextNode)); }
/** * Adds the NodeRemovedCommand to historyBrowser. * * @param oldParent * The node's old parent * @param oldSibling * The node's old next sibling * @param contextNode * The node to be removed */ public void nodeRemoved(Node oldParent, Node oldSibling, Node contextNode) { historyBrowser.addCommand (createNodeRemovedCommand(oldParent, oldSibling, contextNode)); }
/** * Adds the NodeInsertedCommand to historyBrowser. * * @param newParent * New parent node * @param newSibling * New (next) sibling node * @param contextNode * The node to be appended */ public void nodeInserted(Node newParent, Node newSibling, Node contextNode) { historyBrowser.addCommand(createNodeInsertedCommand(newParent, newSibling, contextNode)); }
/** * Adds CharDataModifiedCommand to historyBrowser. * * @param contextNode * The node whose nodeValue changed * @param oldValue * The old node value * @param newValue * The new node value */ public void charDataModified(Node contextNode, String oldValue, String newValue) { historyBrowser.addCommand (createCharDataModifiedCommand(contextNode, oldValue, newValue)); }
/** * Adds CharDataModifiedCommand to historyBrowser. * * @param contextNode * The node whose nodeValue changed * @param oldValue * The old node value * @param newValue * The new node value */ public void charDataModified(Node contextNode, String oldValue, String newValue) { historyBrowser.addCommand (createCharDataModifiedCommand(contextNode, oldValue, newValue)); }
/** * Adds and executes the InsertNodeBeforeCommand to historyBrowser. * * @param parent * The given parent * @param sibling * Points where to be inserted * @param child * The node to insert */ public void insertChildBefore(Node parent, Node sibling, Node child) { if (sibling == null) { historyBrowser.addCommand(createAppendChildCommand(parent, child)); } else { historyBrowser.addCommand (createInsertNodeBeforeCommand(parent, sibling, child)); } }
/** * Adds and executes the InsertNodeBeforeCommand to historyBrowser. * * @param parent * The given parent * @param sibling * Points where to be inserted * @param child * The node to insert */ public void insertChildBefore(Node parent, Node sibling, Node child) { if (sibling == null) { historyBrowser.addCommand(createAppendChildCommand(parent, child)); } else { historyBrowser.addCommand (createInsertNodeBeforeCommand(parent, sibling, child)); } }
/** * Adds the AttributeAddedCommand to historyBrowser. * * @param contextElement * The context element * @param attributeName * The attribute name * @param newAttributeValue * The attribute value * @param namespaceURI * The namespaceURI */ public void attributeAdded(Element contextElement, String attributeName, String newAttributeValue, String namespaceURI) { historyBrowser.addCommand (createAttributeAddedCommand(contextElement, attributeName, newAttributeValue, namespaceURI)); }
/** * Adds the AttributeAddedCommand to historyBrowser. * * @param contextElement * The context element * @param attributeName * The attribute name * @param newAttributeValue * The attribute value * @param namespaceURI * The namespaceURI */ public void attributeAdded(Element contextElement, String attributeName, String newAttributeValue, String namespaceURI) { historyBrowser.addCommand (createAttributeAddedCommand(contextElement, attributeName, newAttributeValue, namespaceURI)); }
/** * Adds and executes the current compound command to history browser. */ public void performCurrentCompoundCommand() { if (getCurrentCompoundCommand().getCommandNumber() > 0) { historyBrowser.addCommand(getCurrentCompoundCommand()); // Fire the 'compoundEditPerformed' event historyBrowser.fireCompoundEditPerformed (new HistoryBrowserEvent(currentCompoundCommand)); // Reset the current compound command currentCompoundCommand = null; } }
/** * Adds and executes the current compound command to history browser. */ public void performCurrentCompoundCommand() { if (getCurrentCompoundCommand().getCommandNumber() > 0) { historyBrowser.addCommand(getCurrentCompoundCommand()); // Fire the 'compoundEditPerformed' event historyBrowser.fireCompoundEditPerformed (new HistoryBrowserEvent(currentCompoundCommand)); // Reset the current compound command currentCompoundCommand = null; } }