|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.tapestry5.dom.Node
public abstract class Node
A node within the DOM.
| Constructor Summary | |
|---|---|
protected |
Node(Element container)
Creates a new node, setting its container to the provided value. |
| Method Summary | |
|---|---|
Element |
getContainer()
Returns the containing Element for this node, or null if this node is the root
element of the document. |
Document |
getDocument()
|
protected Map<String,String> |
getNamespaceURIToPrefix()
|
Node |
moveAfter(Element element)
Moves this node so that it becomes a sibling of the element, ordered just after the element. |
Node |
moveBefore(Element element)
Moves this node so that it becomes a sibling of the element, ordered just before the element. |
Node |
moveToBottom(Element element)
Moves this node so that it the last child of the element. |
Node |
moveToTop(Element element)
Moves this node so that it becomes this first child of the element, shifting existing elements forward. |
void |
remove()
Removes a node from its container, setting its container property to null, and removing it from its container's list of children. |
void |
toMarkup(PrintWriter writer)
Writes the markup for this node to the writer. |
String |
toString()
Invokes toMarkup(PrintWriter), collecting output in a string, which is returned. |
Element |
wrap(String elementName,
String... namesAndValues)
Wraps a node inside a new element. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected Node(Element container)
container - element containing this node| Method Detail |
|---|
public Element getContainer()
Element for this node, or null if this node is the root
element of the document.
public Document getDocument()
public String toString()
toMarkup(PrintWriter), collecting output in a string, which is returned.
toString in class Objectpublic void toMarkup(PrintWriter writer)
protected Map<String,String> getNamespaceURIToPrefix()
public Node moveBefore(Element element)
element - to move the node before
public Node moveAfter(Element element)
element - to move the node after
public Node moveToTop(Element element)
element - to move the node inside
public Node moveToBottom(Element element)
element - to move the node inside
public void remove()
public Element wrap(String elementName,
String... namesAndValues)
elementName - name of new element to createnamesAndValues - to set attributes of new element
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||