org.w3c.dom
Interface Element

All Superinterfaces:
Node sample code for org.w3c.dom.Node definition code for org.w3c.dom.Node
All Known Subinterfaces:
HTMLAnchorElement sample code for org.w3c.dom.html.HTMLAnchorElement definition code for org.w3c.dom.html.HTMLAnchorElement , HTMLAppletElement sample code for org.w3c.dom.html.HTMLAppletElement definition code for org.w3c.dom.html.HTMLAppletElement , HTMLAreaElement sample code for org.w3c.dom.html.HTMLAreaElement definition code for org.w3c.dom.html.HTMLAreaElement , HTMLBaseElement sample code for org.w3c.dom.html.HTMLBaseElement definition code for org.w3c.dom.html.HTMLBaseElement , HTMLBaseFontElement sample code for org.w3c.dom.html.HTMLBaseFontElement definition code for org.w3c.dom.html.HTMLBaseFontElement , HTMLBodyElement sample code for org.w3c.dom.html.HTMLBodyElement definition code for org.w3c.dom.html.HTMLBodyElement , HTMLBRElement sample code for org.w3c.dom.html.HTMLBRElement definition code for org.w3c.dom.html.HTMLBRElement , HTMLButtonElement sample code for org.w3c.dom.html.HTMLButtonElement definition code for org.w3c.dom.html.HTMLButtonElement , HTMLDirectoryElement sample code for org.w3c.dom.html.HTMLDirectoryElement definition code for org.w3c.dom.html.HTMLDirectoryElement , HTMLDivElement sample code for org.w3c.dom.html.HTMLDivElement definition code for org.w3c.dom.html.HTMLDivElement , HTMLDListElement sample code for org.w3c.dom.html.HTMLDListElement definition code for org.w3c.dom.html.HTMLDListElement , HTMLElement sample code for org.w3c.dom.html.HTMLElement definition code for org.w3c.dom.html.HTMLElement , HTMLFieldSetElement sample code for org.w3c.dom.html.HTMLFieldSetElement definition code for org.w3c.dom.html.HTMLFieldSetElement , HTMLFontElement sample code for org.w3c.dom.html.HTMLFontElement definition code for org.w3c.dom.html.HTMLFontElement , HTMLFormElement sample code for org.w3c.dom.html.HTMLFormElement definition code for org.w3c.dom.html.HTMLFormElement , HTMLFrameElement sample code for org.w3c.dom.html.HTMLFrameElement definition code for org.w3c.dom.html.HTMLFrameElement , HTMLFrameSetElement sample code for org.w3c.dom.html.HTMLFrameSetElement definition code for org.w3c.dom.html.HTMLFrameSetElement , HTMLHeadElement sample code for org.w3c.dom.html.HTMLHeadElement definition code for org.w3c.dom.html.HTMLHeadElement , HTMLHeadingElement sample code for org.w3c.dom.html.HTMLHeadingElement definition code for org.w3c.dom.html.HTMLHeadingElement , HTMLHRElement sample code for org.w3c.dom.html.HTMLHRElement definition code for org.w3c.dom.html.HTMLHRElement , HTMLHtmlElement sample code for org.w3c.dom.html.HTMLHtmlElement definition code for org.w3c.dom.html.HTMLHtmlElement , HTMLIFrameElement sample code for org.w3c.dom.html.HTMLIFrameElement definition code for org.w3c.dom.html.HTMLIFrameElement , HTMLImageElement sample code for org.w3c.dom.html.HTMLImageElement definition code for org.w3c.dom.html.HTMLImageElement , HTMLInputElement sample code for org.w3c.dom.html.HTMLInputElement definition code for org.w3c.dom.html.HTMLInputElement , HTMLIsIndexElement sample code for org.w3c.dom.html.HTMLIsIndexElement definition code for org.w3c.dom.html.HTMLIsIndexElement , HTMLLabelElement sample code for org.w3c.dom.html.HTMLLabelElement definition code for org.w3c.dom.html.HTMLLabelElement , HTMLLegendElement sample code for org.w3c.dom.html.HTMLLegendElement definition code for org.w3c.dom.html.HTMLLegendElement , HTMLLIElement sample code for org.w3c.dom.html.HTMLLIElement definition code for org.w3c.dom.html.HTMLLIElement , HTMLLinkElement sample code for org.w3c.dom.html.HTMLLinkElement definition code for org.w3c.dom.html.HTMLLinkElement , HTMLMapElement sample code for org.w3c.dom.html.HTMLMapElement definition code for org.w3c.dom.html.HTMLMapElement , HTMLMenuElement sample code for org.w3c.dom.html.HTMLMenuElement definition code for org.w3c.dom.html.HTMLMenuElement , HTMLMetaElement sample code for org.w3c.dom.html.HTMLMetaElement definition code for org.w3c.dom.html.HTMLMetaElement , HTMLModElement sample code for org.w3c.dom.html.HTMLModElement definition code for org.w3c.dom.html.HTMLModElement , HTMLObjectElement sample code for org.w3c.dom.html.HTMLObjectElement definition code for org.w3c.dom.html.HTMLObjectElement , HTMLOListElement sample code for org.w3c.dom.html.HTMLOListElement definition code for org.w3c.dom.html.HTMLOListElement , HTMLOptGroupElement sample code for org.w3c.dom.html.HTMLOptGroupElement definition code for org.w3c.dom.html.HTMLOptGroupElement , HTMLOptionElement sample code for org.w3c.dom.html.HTMLOptionElement definition code for org.w3c.dom.html.HTMLOptionElement , HTMLParagraphElement sample code for org.w3c.dom.html.HTMLParagraphElement definition code for org.w3c.dom.html.HTMLParagraphElement , HTMLParamElement sample code for org.w3c.dom.html.HTMLParamElement definition code for org.w3c.dom.html.HTMLParamElement , HTMLPreElement sample code for org.w3c.dom.html.HTMLPreElement definition code for org.w3c.dom.html.HTMLPreElement , HTMLQuoteElement sample code for org.w3c.dom.html.HTMLQuoteElement definition code for org.w3c.dom.html.HTMLQuoteElement , HTMLScriptElement sample code for org.w3c.dom.html.HTMLScriptElement definition code for org.w3c.dom.html.HTMLScriptElement , HTMLSelectElement sample code for org.w3c.dom.html.HTMLSelectElement definition code for org.w3c.dom.html.HTMLSelectElement , HTMLStyleElement sample code for org.w3c.dom.html.HTMLStyleElement definition code for org.w3c.dom.html.HTMLStyleElement , HTMLTableCaptionElement sample code for org.w3c.dom.html.HTMLTableCaptionElement definition code for org.w3c.dom.html.HTMLTableCaptionElement , HTMLTableCellElement sample code for org.w3c.dom.html.HTMLTableCellElement definition code for org.w3c.dom.html.HTMLTableCellElement , HTMLTableColElement sample code for org.w3c.dom.html.HTMLTableColElement definition code for org.w3c.dom.html.HTMLTableColElement , HTMLTableElement sample code for org.w3c.dom.html.HTMLTableElement definition code for org.w3c.dom.html.HTMLTableElement , HTMLTableRowElement sample code for org.w3c.dom.html.HTMLTableRowElement definition code for org.w3c.dom.html.HTMLTableRowElement , HTMLTableSectionElement sample code for org.w3c.dom.html.HTMLTableSectionElement definition code for org.w3c.dom.html.HTMLTableSectionElement , HTMLTextAreaElement sample code for org.w3c.dom.html.HTMLTextAreaElement definition code for org.w3c.dom.html.HTMLTextAreaElement , HTMLTitleElement sample code for org.w3c.dom.html.HTMLTitleElement definition code for org.w3c.dom.html.HTMLTitleElement , HTMLUListElement sample code for org.w3c.dom.html.HTMLUListElement definition code for org.w3c.dom.html.HTMLUListElement
All Known Implementing Classes:
IIOMetadataNode sample code for javax.imageio.metadata.IIOMetadataNode definition code for javax.imageio.metadata.IIOMetadataNode

public interface Element
extends Node sample code for org.w3c.dom.Node definition code for org.w3c.dom.Node

The Element interface represents an element in an HTML or XML document. Elements may have attributes associated with them; since the Element interface inherits from Node, the generic Node interface attribute attributes may be used to retrieve the set of all attributes for an element. There are methods on the Element interface to retrieve either an Attr object by name or an attribute value by name. In XML, where an attribute value may contain entity references, an Attr object should be retrieved to examine the possibly fairly complex sub-tree representing the attribute value. On the other hand, in HTML, where all attributes have simple string values, methods to directly access an attribute value can safely be used as a convenience.

Note: In DOM Level 2, the method normalize is inherited from the Node interface where it was moved.

See also the Document Object Model (DOM) Level 3 Core Specification.


Field Summary
 
Fields inherited from interface org.w3c.dom.Node sample code for org.w3c.dom.Node definition code for org.w3c.dom.Node
ATTRIBUTE_NODE sample code for org.w3c.dom.Node.ATTRIBUTE_NODE definition code for org.w3c.dom.Node.ATTRIBUTE_NODE , CDATA_SECTION_NODE sample code for org.w3c.dom.Node.CDATA_SECTION_NODE definition code for org.w3c.dom.Node.CDATA_SECTION_NODE , COMMENT_NODE sample code for org.w3c.dom.Node.COMMENT_NODE definition code for org.w3c.dom.Node.COMMENT_NODE , DOCUMENT_FRAGMENT_NODE sample code for org.w3c.dom.Node.DOCUMENT_FRAGMENT_NODE definition code for org.w3c.dom.Node.DOCUMENT_FRAGMENT_NODE , DOCUMENT_NODE sample code for org.w3c.dom.Node.DOCUMENT_NODE definition code for org.w3c.dom.Node.DOCUMENT_NODE , DOCUMENT_POSITION_CONTAINED_BY sample code for org.w3c.dom.Node.DOCUMENT_POSITION_CONTAINED_BY definition code for org.w3c.dom.Node.DOCUMENT_POSITION_CONTAINED_BY , DOCUMENT_POSITION_CONTAINS sample code for org.w3c.dom.Node.DOCUMENT_POSITION_CONTAINS definition code for org.w3c.dom.Node.DOCUMENT_POSITION_CONTAINS , DOCUMENT_POSITION_DISCONNECTED sample code for org.w3c.dom.Node.DOCUMENT_POSITION_DISCONNECTED definition code for org.w3c.dom.Node.DOCUMENT_POSITION_DISCONNECTED , DOCUMENT_POSITION_FOLLOWING sample code for org.w3c.dom.Node.DOCUMENT_POSITION_FOLLOWING definition code for org.w3c.dom.Node.DOCUMENT_POSITION_FOLLOWING , DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC sample code for org.w3c.dom.Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC definition code for org.w3c.dom.Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC , DOCUMENT_POSITION_PRECEDING sample code for org.w3c.dom.Node.DOCUMENT_POSITION_PRECEDING definition code for org.w3c.dom.Node.DOCUMENT_POSITION_PRECEDING , DOCUMENT_TYPE_NODE sample code for org.w3c.dom.Node.DOCUMENT_TYPE_NODE definition code for org.w3c.dom.Node.DOCUMENT_TYPE_NODE , ELEMENT_NODE sample code for org.w3c.dom.Node.ELEMENT_NODE definition code for org.w3c.dom.Node.ELEMENT_NODE , ENTITY_NODE sample code for org.w3c.dom.Node.ENTITY_NODE definition code for org.w3c.dom.Node.ENTITY_NODE , ENTITY_REFERENCE_NODE sample code for org.w3c.dom.Node.ENTITY_REFERENCE_NODE definition code for org.w3c.dom.Node.ENTITY_REFERENCE_NODE , NOTATION_NODE sample code for org.w3c.dom.Node.NOTATION_NODE definition code for org.w3c.dom.Node.NOTATION_NODE , PROCESSING_INSTRUCTION_NODE sample code for org.w3c.dom.Node.PROCESSING_INSTRUCTION_NODE definition code for org.w3c.dom.Node.PROCESSING_INSTRUCTION_NODE , TEXT_NODE sample code for org.w3c.dom.Node.TEXT_NODE definition code for org.w3c.dom.Node.TEXT_NODE
 
Method Summary
 String sample code for java.lang.String definition code for java.lang.String getAttribute sample code for org.w3c.dom.Element.getAttribute(java.lang.String) definition code for org.w3c.dom.Element.getAttribute(java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  name)
          Retrieves an attribute value by name.
 Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr getAttributeNode sample code for org.w3c.dom.Element.getAttributeNode(java.lang.String) definition code for org.w3c.dom.Element.getAttributeNode(java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  name)
          Retrieves an attribute node by name.
 Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr getAttributeNodeNS sample code for org.w3c.dom.Element.getAttributeNodeNS(java.lang.String, java.lang.String) definition code for org.w3c.dom.Element.getAttributeNodeNS(java.lang.String, java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  namespaceURI, String sample code for java.lang.String definition code for java.lang.String  localName)
          Retrieves an Attr node by local name and namespace URI.
 String sample code for java.lang.String definition code for java.lang.String getAttributeNS sample code for org.w3c.dom.Element.getAttributeNS(java.lang.String, java.lang.String) definition code for org.w3c.dom.Element.getAttributeNS(java.lang.String, java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  namespaceURI, String sample code for java.lang.String definition code for java.lang.String  localName)
          Retrieves an attribute value by local name and namespace URI.
 NodeList sample code for org.w3c.dom.NodeList definition code for org.w3c.dom.NodeList getElementsByTagName sample code for org.w3c.dom.Element.getElementsByTagName(java.lang.String) definition code for org.w3c.dom.Element.getElementsByTagName(java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  name)
          Returns a NodeList of all descendant Elements with a given tag name, in document order.
 NodeList sample code for org.w3c.dom.NodeList definition code for org.w3c.dom.NodeList getElementsByTagNameNS sample code for org.w3c.dom.Element.getElementsByTagNameNS(java.lang.String, java.lang.String) definition code for org.w3c.dom.Element.getElementsByTagNameNS(java.lang.String, java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  namespaceURI, String sample code for java.lang.String definition code for java.lang.String  localName)
          Returns a NodeList of all the descendant Elements with a given local name and namespace URI in document order.
 TypeInfo sample code for org.w3c.dom.TypeInfo definition code for org.w3c.dom.TypeInfo getSchemaTypeInfo sample code for org.w3c.dom.Element.getSchemaTypeInfo() definition code for org.w3c.dom.Element.getSchemaTypeInfo() ()
          The type information associated with this element.
 String sample code for java.lang.String definition code for java.lang.String getTagName sample code for org.w3c.dom.Element.getTagName() definition code for org.w3c.dom.Element.getTagName() ()
          The name of the element.
 boolean hasAttribute sample code for org.w3c.dom.Element.hasAttribute(java.lang.String) definition code for org.w3c.dom.Element.hasAttribute(java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  name)
          Returns true when an attribute with a given name is specified on this element or has a default value, false otherwise.
 boolean hasAttributeNS sample code for org.w3c.dom.Element.hasAttributeNS(java.lang.String, java.lang.String) definition code for org.w3c.dom.Element.hasAttributeNS(java.lang.String, java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  namespaceURI, String sample code for java.lang.String definition code for java.lang.String  localName)
          Returns true when an attribute with a given local name and namespace URI is specified on this element or has a default value, false otherwise.
 void removeAttribute sample code for org.w3c.dom.Element.removeAttribute(java.lang.String) definition code for org.w3c.dom.Element.removeAttribute(java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  name)
          Removes an attribute by name.
 Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr removeAttributeNode sample code for org.w3c.dom.Element.removeAttributeNode(org.w3c.dom.Attr) definition code for org.w3c.dom.Element.removeAttributeNode(org.w3c.dom.Attr) (Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr  oldAttr)
          Removes the specified attribute node.
 void removeAttributeNS sample code for org.w3c.dom.Element.removeAttributeNS(java.lang.String, java.lang.String) definition code for org.w3c.dom.Element.removeAttributeNS(java.lang.String, java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  namespaceURI, String sample code for java.lang.String definition code for java.lang.String  localName)
          Removes an attribute by local name and namespace URI.
 void setAttribute sample code for org.w3c.dom.Element.setAttribute(java.lang.String, java.lang.String) definition code for org.w3c.dom.Element.setAttribute(java.lang.String, java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  name, String sample code for java.lang.String definition code for java.lang.String  value)
          Adds a new attribute.
 Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr setAttributeNode sample code for org.w3c.dom.Element.setAttributeNode(org.w3c.dom.Attr) definition code for org.w3c.dom.Element.setAttributeNode(org.w3c.dom.Attr) (Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr  newAttr)
          Adds a new attribute node.
 Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr setAttributeNodeNS sample code for org.w3c.dom.Element.setAttributeNodeNS(org.w3c.dom.Attr) definition code for org.w3c.dom.Element.setAttributeNodeNS(org.w3c.dom.Attr) (Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr  newAttr)
          Adds a new attribute.
 void setAttributeNS sample code for org.w3c.dom.Element.setAttributeNS(java.lang.String, java.lang.String, java.lang.String) definition code for org.w3c.dom.Element.setAttributeNS(java.lang.String, java.lang.String, java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  namespaceURI, String sample code for java.lang.String definition code for java.lang.String  qualifiedName, String sample code for java.lang.String definition code for java.lang.String  value)
          Adds a new attribute.
 void setIdAttribute sample code for org.w3c.dom.Element.setIdAttribute(java.lang.String, boolean) definition code for org.w3c.dom.Element.setIdAttribute(java.lang.String, boolean) (String sample code for java.lang.String definition code for java.lang.String  name, boolean isId)
          If the parameter isId is true, this method declares the specified attribute to be a user-determined ID attribute .
 void setIdAttributeNode sample code for org.w3c.dom.Element.setIdAttributeNode(org.w3c.dom.Attr, boolean) definition code for org.w3c.dom.Element.setIdAttributeNode(org.w3c.dom.Attr, boolean) (Attr sample code for org.w3c.dom.Attr definition code for org.w3c.dom.Attr  idAttr, boolean isId)
          If the parameter isId is true, this method declares the specified attribute to be a user-determined ID attribute .
 void setIdAttributeNS sample code for org.w3c.dom.Element.setIdAttributeNS(java.lang.String, java.lang.String, boolean) definition code for org.w3c.dom.Element.setIdAttributeNS(java.lang.String, java.lang.String, boolean) (String sample code for java.lang.String definition code for java.lang.String  namespaceURI, String sample code for java.lang.String definition code for java.lang.String  localName, boolean isId)
          If the parameter isId is true, this method declares the specified attribute to be a user-determined ID attribute .
 
Methods inherited from interface org.w3c.dom.Node sample code for org.w3c.dom.Node definition code for org.w3c.dom.Node
appendChild sample code for org.w3c.dom.Node.appendChild(org.w3c.dom.Node) definition code for org.w3c.dom.Node.appendChild(org.w3c.dom.Node) , cloneNode sample code for org.w3c.dom.Node.cloneNode(boolean) definition code for org.w3c.dom.Node.cloneNode(boolean) , compareDocumentPosition sample code for org.w3c.dom.Node.compareDocumentPosition(org.w3c.dom.Node) definition code for org.w3c.dom.Node.compareDocumentPosition(org.w3c.dom.Node) , getAttributes sample code for org.w3c.dom.Node.getAttributes() definition code for org.w3c.dom.Node.getAttributes() , getBaseURI sample code for org.w3c.dom.Node.getBaseURI() definition code for org.w3c.dom.Node.getBaseURI() , getChildNodes sample code for org.w3c.dom.Node.getChildNodes() definition code for org.w3c.dom.Node.getChildNodes() , getFeature sample code for org.w3c.dom.Node.getFeature(java.lang.String, java.lang.String) definition code for org.w3c.dom.Node.getFeature(java.lang.String, java.lang.String) , getFirstChild sample code for org.w3c.dom.Node.getFirstChild() definition code for org.w3c.dom.Node.getFirstChild() , getLastChild sample code for org.w3c.dom.Node.getLastChild() definition code for org.w3c.dom.Node.getLastChild() , getLocalName sample code for org.w3c.dom.Node.getLocalName() definition code for org.w3c.dom.Node.getLocalName() , getNamespaceURI sample code for org.w3c.dom.Node.getNamespaceURI() definition code for org.w3c.dom.Node.getNamespaceURI() , getNextSibling sample code for org.w3c.dom.Node.getNextSibling() definition code for org.w3c.dom.Node.getNextSibling() , getNodeName sample code for org.w3c.dom.Node.getNodeName() definition code for org.w3c.dom.Node.getNodeName() , getNodeType sample code for org.w3c.dom.Node.getNodeType() definition code for org.w3c.dom.Node.getNodeType() , getNodeValue sample code for org.w3c.dom.Node.getNodeValue() definition code for org.w3c.dom.Node.getNodeValue() , getOwnerDocument sample code for org.w3c.dom.Node.getOwnerDocument() definition code for org.w3c.dom.Node.getOwnerDocument() , getParentNode sample code for org.w3c.dom.Node.getParentNode() definition code for org.w3c.dom.Node.getParentNode() , getPrefix sample code for org.w3c.dom.Node.getPrefix() definition code for org.w3c.dom.Node.getPrefix() , getPreviousSibling sample code for org.w3c.dom.Node.getPreviousSibling() definition code for org.w3c.dom.Node.getPreviousSibling() , getTextContent sample code for org.w3c.dom.Node.getTextContent() definition code for org.w3c.dom.Node.getTextContent() , getUserData sample code for org.w3c.dom.Node.getUserData(java.lang.String) definition code for org.w3c.dom.Node.getUserData(java.lang.String) , hasAttributes sample code for org.w3c.dom.Node.hasAttributes() definition code for org.w3c.dom.Node.hasAttributes() , hasChildNodes sample code for org.w3c.dom.Node.hasChildNodes() definition code for org.w3c.dom.Node.hasChildNodes() , insertBefore sample code for org.w3c.dom.Node.insertBefore(org.w3c.dom.Node, org.w3c.dom.Node) definition code for org.w3c.dom.Node.insertBefore(org.w3c.dom.Node, org.w3c.dom.Node) , isDefaultNamespace sample code for org.w3c.dom.Node.isDefaultNamespace(java.lang.String) definition code for org.w3c.dom.Node.isDefaultNamespace(java.lang.String) , isEqualNode sample code for org.w3c.dom.Node.isEqualNode(org.w3c.dom.Node) definition code for org.w3c.dom.Node.isEqualNode(org.w3c.dom.Node) , isSameNode sample code for org.w3c.dom.Node.isSameNode(org.w3c.dom.Node) definition code for org.w3c.dom.Node.isSameNode(org.w3c.dom.Node) , isSupported sample code for org.w3c.dom.Node.isSupported(java.lang.String, java.lang.String) definition code for org.w3c.dom.Node.isSupported(java.lang.String, java.lang.String) , lookupNamespaceURI sample code for org.w3c.dom.Node.lookupNamespaceURI(java.lang.String) definition code for org.w3c.dom.Node.lookupNamespaceURI(java.lang.String) , lookupPrefix sample code for org.w3c.dom.Node.lookupPrefix(java.lang.String) definition code for org.w3c.dom.Node.lookupPrefix(java.lang.String) , normalize sample code for org.w3c.dom.Node.normalize() definition code for org.w3c.dom.Node.normalize() , removeChild sample code for org.w3c.dom.Node.removeChild(org.w3c.dom.Node) definition code for org.w3c.dom.Node.removeChild(org.w3c.dom.Node) , replaceChild sample code for org.w3c.dom.Node.replaceChild(org.w3c.dom.Node, org.w3c.dom.Node) definition code for org.w3c.dom.Node.replaceChild(org.w3c.dom.Node, org.w3c.dom.Node) , setNodeValue sample code for org.w3c.dom.Node.setNodeValue(java.lang.String) definition code for org.w3c.dom.Node.setNodeValue(java.lang.String) , setPrefix sample code for org.w3c.dom.Node.setPrefix(java.lang.String) definition code for org.w3c.dom.Node.setPrefix(java.lang.String) , setTextContent sample code for org.w3c.dom.Node.setTextContent(java.lang.String) definition code for org.w3c.dom.Node.setTextContent(java.lang.String) , setUserData sample code for org.w3c.dom.Node.setUserData(java.lang.String, java.lang.Object, org.w3c.dom.UserDataHandler) definition code for org.w3c.dom.Node.setUserData(java.lang.String, java.lang.Object, org.w3c.dom.UserDataHandler)
 

Method Detail

getTagName sample code for org.w3c.dom.Element.getTagName() definition code for org.w3c.dom.Element.getTagName()

String sample code for java.lang.String definition code for java.lang.String  getTagName()
The name of the element. If Node.localName is different from null, this attribute is a qualified name. For example, in:
 <elementExample id="demo"> ... 
 </elementExample> , 
tagName has the value "elementExample". Note that this is case-preserving in XML, as are all of the operations of the DOM. The HTML DOM returns the tagName of an HTML element in the canonical uppercase form, regardless of the case in the source HTML document.


getAttribute sample code for org.w3c.dom.Element.getAttribute(java.lang.String) definition code for org.w3c.dom.Element.getAttribute(java.lang.String)

String sample code for java.lang.String definition code for java.lang.String  getAttribute(String sample code for java.lang.String definition code for java.lang.String  name)
Retrieves an attribute value by name.

Parameters:
name - The name of the attribute to retrieve.
Returns:
The Attr value as a string, or the empty string if that attribute does not have a specified or