Class Node
- java.lang.Object
-
- de.inetsoftware.jwebassembly.web.JSObject
-
- de.inetsoftware.jwebassembly.web.dom.EventTarget
-
- de.inetsoftware.jwebassembly.web.dom.Node
-
- Direct Known Subclasses:
CharacterData
,Document
,Element
public class Node extends EventTarget
https://developer.mozilla.org/en-US/docs/Web/API/Node
-
-
Field Summary
Fields Modifier and Type Field Description static int
ATTRIBUTE_NODE
An Attribute of an Element.static int
CDATA_SECTION_NODE
A CDATASection, such as <!CDATA[[ … ]]<.static int
COMMENT_NODE
A Comment node, such as <!-- … --<.static int
DOCUMENT_FRAGMENT_NODE
A DocumentFragment node.static int
DOCUMENT_NODE
A Document node.static int
DOCUMENT_TYPE_NODE
A DocumentType node, such as <!DOCTYPE html<.static int
ELEMENT_NODE
An Element node like <p> or <div>static int
PROCESSING_INSTRUCTION_NODE
A ProcessingInstruction of an XML document, such as <?xml-stylesheet … ?<.static int
TEXT_NODE
The actual Text inside an Element or Attr.
-
Constructor Summary
Constructors Constructor Description Node(java.lang.Object peer)
Create a Java instance as wrapper of the JavaScript object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
appendChild(Node child)
https://developer.mozilla.org/en-US/docs/Web/API/Node/appendChildNodeList
childNodes()
https://developer.mozilla.org/en-US/docs/Web/API/Node/childNodesint
nodeType()
https://developer.mozilla.org/en-US/docs/Web/API/Node/nodeType
-
-
-
Field Detail
-
ELEMENT_NODE
public static final int ELEMENT_NODE
An Element node like <p> or <div>- See Also:
- Constant Field Values
-
ATTRIBUTE_NODE
public static final int ATTRIBUTE_NODE
An Attribute of an Element.- See Also:
- Constant Field Values
-
TEXT_NODE
public static final int TEXT_NODE
The actual Text inside an Element or Attr.- See Also:
- Constant Field Values
-
CDATA_SECTION_NODE
public static final int CDATA_SECTION_NODE
A CDATASection, such as <!CDATA[[ … ]]<.- See Also:
- Constant Field Values
-
PROCESSING_INSTRUCTION_NODE
public static final int PROCESSING_INSTRUCTION_NODE
A ProcessingInstruction of an XML document, such as <?xml-stylesheet … ?<.- See Also:
- Constant Field Values
-
COMMENT_NODE
public static final int COMMENT_NODE
A Comment node, such as <!-- … --<.- See Also:
- Constant Field Values
-
DOCUMENT_NODE
public static final int DOCUMENT_NODE
A Document node.- See Also:
- Constant Field Values
-
DOCUMENT_TYPE_NODE
public static final int DOCUMENT_TYPE_NODE
A DocumentType node, such as <!DOCTYPE html<.- See Also:
- Constant Field Values
-
DOCUMENT_FRAGMENT_NODE
public static final int DOCUMENT_FRAGMENT_NODE
A DocumentFragment node.- See Also:
- Constant Field Values
-
-
Method Detail
-
nodeType
public int nodeType()
https://developer.mozilla.org/en-US/docs/Web/API/Node/nodeType- Returns:
- the node type
-
childNodes
public NodeList childNodes()
https://developer.mozilla.org/en-US/docs/Web/API/Node/childNodes- Returns:
- list of chield nodes
-
appendChild
public void appendChild(Node child)
https://developer.mozilla.org/en-US/docs/Web/API/Node/appendChild- Parameters:
child
- the child
-
-