org.enhydra.xml.xhtml.dom.xerces
Class XHTMLElementImpl
java.lang.Object
|
+--org.enhydra.apache.xerces.dom.NodeImpl
|
+--org.enhydra.apache.xerces.dom.ChildNode
|
+--org.enhydra.apache.xerces.dom.ParentNode
|
+--org.enhydra.apache.xerces.dom.ElementImpl
|
+--org.enhydra.apache.xerces.dom.ElementNSImpl
|
+--org.enhydra.xml.xhtml.dom.xerces.XHTMLElementImpl
- All Implemented Interfaces:
- Cloneable, Element, EventTarget, HTMLElement, Node, NodeList, Serializable, XHTMLElement
- Direct Known Subclasses:
- XHTMLAbbrElementImpl, XHTMLAcronymElementImpl, XHTMLAddressElementImpl, XHTMLAnchorElementImpl, XHTMLAppletElementImpl, XHTMLAreaElementImpl, XHTMLBaseElementImpl, XHTMLBaseFontElementImpl, XHTMLBdoElementImpl, XHTMLBElementImpl, XHTMLBigElementImpl, XHTMLBodyElementImpl, XHTMLBRElementImpl, XHTMLButtonElementImpl, XHTMLCenterElementImpl, XHTMLCiteElementImpl, XHTMLCodeElementImpl, XHTMLDdElementImpl, XHTMLDfnElementImpl, XHTMLDirectoryElementImpl, XHTMLDivElementImpl, XHTMLDListElementImpl, XHTMLDtElementImpl, XHTMLEmElementImpl, XHTMLFieldSetElementImpl, XHTMLFontElementImpl, XHTMLFormElementImpl, XHTMLFrameElementImpl, XHTMLFrameSetElementImpl, XHTMLHeadElementImpl, XHTMLHeadingElementImpl, XHTMLHRElementImpl, XHTMLHtmlElementImpl, XHTMLIElementImpl, XHTMLIFrameElementImpl, XHTMLImageElementImpl, XHTMLInputElementImpl, XHTMLIsIndexElementImpl, XHTMLKbdElementImpl, XHTMLLabelElementImpl, XHTMLLegendElementImpl, XHTMLLIElementImpl, XHTMLLinkElementImpl, XHTMLMapElementImpl, XHTMLMenuElementImpl, XHTMLMetaElementImpl, XHTMLModElementImpl, XHTMLNoframesElementImpl, XHTMLNoscriptElementImpl, XHTMLObjectElementImpl, XHTMLOListElementImpl, XHTMLOptGroupElementImpl, XHTMLOptionElementImpl, XHTMLParagraphElementImpl, XHTMLParamElementImpl, XHTMLPreElementImpl, XHTMLQuoteElementImpl, XHTMLSampElementImpl, XHTMLScriptElementImpl, XHTMLSelectElementImpl, XHTMLSElementImpl, XHTMLSmallElementImpl, XHTMLSpanElementImpl, XHTMLStrikeElementImpl, XHTMLStrongElementImpl, XHTMLStyleElementImpl, XHTMLSubElementImpl, XHTMLSupElementImpl, XHTMLTableCaptionElementImpl, XHTMLTableCellElementImpl, XHTMLTableColElementImpl, XHTMLTableElementImpl, XHTMLTableRowElementImpl, XHTMLTableSectionElementImpl, XHTMLTextAreaElementImpl, XHTMLTitleElementImpl, XHTMLTtElementImpl, XHTMLUElementImpl, XHTMLUListElementImpl, XHTMLVarElementImpl
- public class XHTMLElementImpl
- extends org.enhydra.apache.xerces.dom.ElementNSImpl
- implements XHTMLElement
Implements an HTML-specific element, an Element
that
will only appear inside HTML documents. This element extends ElementImpl
by adding methods for directly
manipulating HTML-specific attributes. All HTML elements gain access to
the id
, title
, lang
,
dir
and class
attributes. Other elements
add their own specific attributes.
- Version:
- $Revision: 1.6 $ $Date: 2006/01/21 17:58:39 $
- See Also:
HTMLElement
, Serialized Form
Fields inherited from class org.enhydra.apache.xerces.dom.ElementNSImpl |
localName, namespaceURI, serialVersionUID, xmlURI |
Fields inherited from class org.enhydra.apache.xerces.dom.ElementImpl |
attributes, name |
Fields inherited from class org.enhydra.apache.xerces.dom.ParentNode |
fCachedChild, fCachedChildIndex, fCachedLength, firstChild, ownerDocument |
Fields inherited from class org.enhydra.apache.xerces.dom.ChildNode |
nextSibling, previousSibling |
Fields inherited from class org.enhydra.apache.xerces.dom.NodeImpl |
ELEMENT_DEFINITION_NODE, FIRSTCHILD, flags, HASSTRING, IGNORABLEWS, OWNED, ownerNode, READONLY, SPECIFIED, SYNCCHILDREN, SYNCDATA, UNNORMALIZED |
Fields inherited from interface org.w3c.dom.Node |
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE |
Methods inherited from class org.enhydra.apache.xerces.dom.ElementNSImpl |
getLocalName, getNamespaceURI, getPrefix, setPrefix |
Methods inherited from class org.enhydra.apache.xerces.dom.ElementImpl |
cloneNode, getAttributes, getDefaultAttributes, getNodeName, getNodeType, getSchemaTypeInfo, getTagName, hasAttribute, hasAttributeNS, hasAttributes, normalize, reconcileDefaultAttributes, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setIdAttribute, setIdAttributeNode, setIdAttributeNS, setOwnerDocument, setReadOnly, setupDefaultAttributes, synchronizeData |
Methods inherited from class org.enhydra.apache.xerces.dom.ParentNode |
checkNormalizationAfterInsert, checkNormalizationAfterRemove, getChildNodes, getChildNodesUnoptimized, getFirstChild, getLastChild, getLength, getOwnerDocument, hasChildNodes, insertBefore, internalInsertBefore, internalRemoveChild, item, lastChild, lastChild, ownerDocument, removeChild, replaceChild, synchronizeChildren |
Methods inherited from class org.enhydra.apache.xerces.dom.ChildNode |
getNextSibling, getParentNode, getPreviousSibling, parentNode, previousSibling |
Methods inherited from class org.enhydra.apache.xerces.dom.NodeImpl |
addEventListener, appendChild, changed, changes, compareDocumentPosition, dispatchEvent, getBaseURI, getFeature, getNodeValue, getReadOnly, getTextContent, getUserData, getUserData, hasStringValue, hasStringValue, internalIsIgnorableWhitespace, isDefaultNamespace, isEqualNode, isFirstChild, isFirstChild, isIgnorableWhitespace, isNormalized, isNormalized, isOwned, isOwned, isReadOnly, isReadOnly, isSameNode, isSpecified, isSpecified, isSupported, lookupNamespaceURI, lookupPrefix, needsSyncChildren, needsSyncChildren, needsSyncData, needsSyncData, removeEventListener, setNodeValue, setTextContent, setUserData, setUserData, toString |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.w3c.dom.Element |
getSchemaTypeInfo, getTagName, hasAttribute, hasAttributeNS, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setIdAttribute, setIdAttributeNode, setIdAttributeNS |
Methods inherited from interface org.w3c.dom.Node |
appendChild, cloneNode, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserData |
XHTMLElementImpl
XHTMLElementImpl(XHTMLDocumentBase owner,
String namespaceURI,
String tagName)
- Constructor required owner document and element tag name. Will be called
by the constructor of specific element types but with a known tag name.
Assures that the owner document is an HTML element.
- Parameters:
owner
- The owner HTML documenttagName
- The element's tag name
getId
public String getId()
- Specified by:
getId
in interface HTMLElement
setId
public void setId(String id)
- Specified by:
setId
in interface HTMLElement
getTitle
public String getTitle()
- Specified by:
getTitle
in interface HTMLElement
setTitle
public void setTitle(String title)
- Specified by:
setTitle
in interface HTMLElement
getLang
public String getLang()
- Specified by:
getLang
in interface HTMLElement
setLang
public void setLang(String lang)
- Specified by:
setLang
in interface HTMLElement
setXmlLang
public void setXmlLang(String xmlLang)
- Specified by:
setXmlLang
in interface XHTMLElement
getXmlLang
public String getXmlLang()
- Description copied from interface:
XHTMLElement
- Language code defined in RFC 1766. See the xml:lang attribute definition
in XHTML 1.0.
- Specified by:
getXmlLang
in interface XHTMLElement
getDir
public String getDir()
- Specified by:
getDir
in interface HTMLElement
setDir
public void setDir(String dir)
- Specified by:
setDir
in interface HTMLElement
getClassName
public String getClassName()
- Specified by:
getClassName
in interface HTMLElement
setClassName
public void setClassName(String className)
- Specified by:
setClassName
in interface HTMLElement
getInteger
int getInteger(String value)
- Convenience method used to translate an attribute value into an integer
value. Returns the integer value or zero if the attribute is not a
valid numeric string.
- Parameters:
value
- The value of the attribute- Returns:
- The integer value, or zero if not a valid numeric string
setAttribute
void setAttribute(String attr,
int value)
getBinary
boolean getBinary(String name)
- Convenience method used to translate an attribute value into a boolean
value. If the attribute has an associated value (even an empty string),
it is set and true is returned. If the attribute does not exist, false
is returend.
- Parameters:
value
- The value of the attribute- Returns:
- True or false depending on whether the attribute has been set
setAttribute
void setAttribute(String name,
boolean value)
- Convenience method used to set a boolean attribute. If the value is true,
the attribute is set to an empty string. If the value is false, the attribute
is removed. HTML 4.0 understands empty strings as set attributes.
- Parameters:
name
- The name of the attributevalue
- The value of the attribute
getAttributeNode
public Attr getAttributeNode(String attrName)
- Specified by:
getAttributeNode
in interface Element
- Overrides:
getAttributeNode
in class org.enhydra.apache.xerces.dom.ElementImpl
getAttributeNodeNS
public Attr getAttributeNodeNS(String namespaceURI,
String localName)
- Specified by:
getAttributeNodeNS
in interface Element
- Overrides:
getAttributeNodeNS
in class org.enhydra.apache.xerces.dom.ElementImpl
getAttribute
public String getAttribute(String attrName)
- Specified by:
getAttribute
in interface Element
- Overrides:
getAttribute
in class org.enhydra.apache.xerces.dom.ElementImpl
getAttributeNS
public String getAttributeNS(String namespaceURI,
String localName)
- Specified by:
getAttributeNS
in interface Element
- Overrides:
getAttributeNS
in class org.enhydra.apache.xerces.dom.ElementImpl
getElementsByTagName
public final NodeList getElementsByTagName(String tagName)
- Specified by:
getElementsByTagName
in interface Element
- Overrides:
getElementsByTagName
in class org.enhydra.apache.xerces.dom.ElementImpl
getElementsByTagNameNS
public final NodeList getElementsByTagNameNS(String namespaceURI,
String localName)
- Specified by:
getElementsByTagNameNS
in interface Element
- Overrides:
getElementsByTagNameNS
in class org.enhydra.apache.xerces.dom.ElementImpl
getForm
public HTMLFormElement getForm()
- Convenience method returns the form in which this form element is contained.
This method is exposed for form elements through the DOM API, but other
elements have no access to it through the API.
setOnKeyUp
public void setOnKeyUp(String newValue)
getOnKeyUp
public String getOnKeyUp()
setStyle
public void setStyle(String newValue)
getStyle
public String getStyle()
setOnMouseDown
public void setOnMouseDown(String newValue)
getOnMouseDown
public String getOnMouseDown()
setOnKeyPress
public void setOnKeyPress(String newValue)
getOnKeyPress
public String getOnKeyPress()
setOnDblClick
public void setOnDblClick(String newValue)
getOnDblClick
public String getOnDblClick()
setOnKeyDown
public void setOnKeyDown(String newValue)
getOnKeyDown
public String getOnKeyDown()
setOnMouseMove
public void setOnMouseMove(String newValue)
getOnMouseMove
public String getOnMouseMove()
setOnMouseUp
public void setOnMouseUp(String newValue)
getOnMouseUp
public String getOnMouseUp()
setOnMouseOut
public void setOnMouseOut(String newValue)
getOnMouseOut
public String getOnMouseOut()
setOnClick
public void setOnClick(String newValue)
getOnClick
public String getOnClick()
setOnMouseOver
public void setOnMouseOver(String newValue)
getOnMouseOver
public String getOnMouseOver()
setOnBlur
public void setOnBlur(String newValue)
getOnBlur
public String getOnBlur()
setOnFocus
public void setOnFocus(String newValue)
getOnFocus
public String getOnFocus()
Copyright © 1999-2002 Mark Diekhans, enhydra.org. All Rights reserved.