Top Fields Constructors Methods
com.sun.webkit.dom

public Class AttrImpl

extends NodeImpl
implements Attr
Class Inheritance
All Implemented Interfaces
org.w3c.dom.Attr, org.w3c.dom.Node
Imports
org.w3c.dom.Attr, .DOMException, .Element, .TypeInfo

Field Summary

Inherited from com.sun.webkit.dom.NodeImpl:
ATTRIBUTE_NODECDATA_SECTION_NODECOMMENT_NODEDOCUMENT_FRAGMENT_NODEDOCUMENT_NODEDOCUMENT_POSITION_CONTAINED_BYDOCUMENT_POSITION_CONTAINSDOCUMENT_POSITION_DISCONNECTEDDOCUMENT_POSITION_FOLLOWINGDOCUMENT_POSITION_IMPLEMENTATION_SPECIFICDOCUMENT_POSITION_PRECEDINGDOCUMENT_TYPE_NODEELEMENT_NODEENTITY_NODEENTITY_REFERENCE_NODENOTATION_NODEPROCESSING_INSTRUCTION_NODETEXT_NODE

Constructor Summary

AccessConstructor and Description
pack-priv
AttrImpl(long peer)

Method Summary

Modifier and TypeMethod and Description
pack-priv static Attr
public String
getName()

Implements org.w3c.dom.Attr.getName.

Returns the name of this attribute.

pack-priv static native String
getNameImpl(long peer)

public Element
getOwnerElement()

Implements org.w3c.dom.Attr.getOwnerElement.

The Element node this attribute is attached to or null if this attribute is not in use.

pack-priv static native long
public TypeInfo
getSchemaTypeInfo()

Implements org.w3c.dom.Attr.getSchemaTypeInfo.

The type information associated with this attribute.

public boolean
getSpecified()

Implements org.w3c.dom.Attr.getSpecified.

True if this attribute was explicitly given a value in the instance document, false otherwise.

pack-priv static native boolean
getSpecifiedImpl(long peer)

public String
getValue()

Implements org.w3c.dom.Attr.getValue.

On retrieval, the value of the attribute is returned as a string.

pack-priv static native String
getValueImpl(long peer)

public boolean
isId()

Implements org.w3c.dom.Attr.isId.

Returns whether this attribute is known to be of type ID (i.e. to contain an identifier for its owner element) or not.

pack-priv static native boolean
isIdImpl(long peer)

public void
setValue(String value)

Implements org.w3c.dom.Attr.setValue.

On retrieval, the value of the attribute is returned as a string.

pack-priv static native void
setValueImpl(long peer, String value)

Inherited from com.sun.webkit.dom.NodeImpl:
addEventListeneraddEventListenerImplappendChildappendChildImplcloneNodecloneNodeImplcompareDocumentPositioncompareDocumentPositionImplcontainscontainsImplcreatecreateInterfacedispatchEventdispatchEventImplgetAttributesgetAttributesImplgetBaseURIgetBaseURIImplgetChildNodesgetChildNodesImplgetFeaturegetFirstChildgetFirstChildImplgetLastChildgetLastChildImplgetLocalNamegetLocalNameImplgetNamespaceURIgetNamespaceURIImplgetNextSiblinggetNextSiblingImplgetNodeNamegetNodeNameImplgetNodeTypegetNodeTypeImplgetNodeValuegetNodeValueImplgetOwnerDocumentgetOwnerDocumentImplgetParentElementgetParentElementImplgetParentNodegetParentNodeImplgetPeergetPrefixgetPrefixImplgetPreviousSiblinggetPreviousSiblingImplgetTextContentgetTextContentImplgetUserDatahasAttributeshasAttributesImplhasChildNodeshasChildNodesImplinsertBeforeinsertBeforeImplisDefaultNamespaceisDefaultNamespaceImplisEqualNodeisEqualNodeImplisSameNodeisSameNodeImplisSupportedisSupportedImpllookupNamespaceURIlookupNamespaceURIImpllookupPrefixlookupPrefixImplnormalizenormalizeImplremoveChildremoveChildImplremoveEventListenerremoveEventListenerImplreplaceChildreplaceChildImplsetNodeValuesetNodeValueImplsetPrefixsetPrefixImplsetTextContentsetTextContentImplsetUserDatatest_getHashCount

Constructor Detail

AttrImplback to summary
pack-priv AttrImpl(long peer)

Method Detail

getImplback to summary
pack-priv static Attr getImpl(long peer)

Hides com.sun.webkit.dom.NodeImpl.getImpl.

getNameback to summary
public String getName()

Implements org.w3c.dom.Attr.getName.

Doc from org.w3c.dom.Attr.getName.

Returns the name of this attribute. If Node.localName is different from null, this attribute is a qualified name.

getNameImplback to summary
pack-priv static native String getNameImpl(long peer)
getOwnerElementback to summary
public Element getOwnerElement()

Implements org.w3c.dom.Attr.getOwnerElement.

Doc from org.w3c.dom.Attr.getOwnerElement.

The Element node this attribute is attached to or null if this attribute is not in use.

getOwnerElementImplback to summary
pack-priv static native long getOwnerElementImpl(long peer)
getSchemaTypeInfoback to summary
public TypeInfo getSchemaTypeInfo()

Implements org.w3c.dom.Attr.getSchemaTypeInfo.

Doc from org.w3c.dom.Attr.getSchemaTypeInfo.

The type information associated with this attribute. While the type information contained in this attribute is guarantee to be correct after loading the document or invoking Document.normalizeDocument(), schemaTypeInfo may not be reliable if the node was moved.

getSpecifiedback to summary
public boolean getSpecified()

Implements org.w3c.dom.Attr.getSpecified.

Doc from org.w3c.dom.Attr.getSpecified.

True if this attribute was explicitly given a value in the instance document, false otherwise. If the application changed the value of this attribute node (even if it ends up having the same value as the default value) then it is set to true. The implementation may handle attributes with default values from other schemas similarly but applications should use Document.normalizeDocument() to guarantee this information is up-to-date.

getSpecifiedImplback to summary
pack-priv static native boolean getSpecifiedImpl(long peer)
getValueback to summary
public String getValue()

Implements org.w3c.dom.Attr.getValue.

Doc from org.w3c.dom.Attr.getValue.

On retrieval, the value of the attribute is returned as a string. Character and general entity references are replaced with their values. See also the method getAttribute on the Element interface.
On setting, this creates a Text node with the unparsed contents of the string, i.e. any characters that an XML processor would recognize as markup are instead treated as literal text. See also the method Element.setAttribute().
Some specialized implementations, such as some [SVG 1.1] implementations, may do normalization automatically, even after mutation; in such case, the value on retrieval may differ from the value on setting.

getValueImplback to summary
pack-priv static native String getValueImpl(long peer)
isIdback to summary
public boolean isId()

Implements org.w3c.dom.Attr.isId.

Doc from org.w3c.dom.Attr.isId.

Returns whether this attribute is known to be of type ID (i.e. to contain an identifier for its owner element) or not. When it is and its value is unique, the ownerElement of this attribute can be retrieved using the method Document.getElementById . The implementation could use several ways to determine if an attribute node is known to contain an identifier:

  • If validation occurred using an XML Schema [XML Schema Part 1] while loading the document or while invoking Document.normalizeDocument(), the post-schema-validation infoset contributions (PSVI contributions) values are used to determine if this attribute is a schema-determined ID attribute using the schema-determined ID definition in [XPointer] .
  • If validation occurred using a DTD while loading the document or while invoking Document.normalizeDocument(), the infoset [type definition] value is used to determine if this attribute is a DTD-determined ID attribute using the DTD-determined ID definition in [XPointer] .
  • from the use of the methods Element.setIdAttribute(), Element.setIdAttributeNS(), or Element.setIdAttributeNode(), i.e. it is an user-determined ID attribute;

    Note: XPointer framework (see section 3.2 in [XPointer] ) consider the DOM user-determined ID attribute as being part of the XPointer externally-determined ID definition.

  • using mechanisms that are outside the scope of this specification, it is then an externally-determined ID attribute. This includes using schema languages different from XML schema and DTD.

If validation occurred while invoking Document.normalizeDocument(), all user-determined ID attributes are reset and all attribute nodes ID information are then reevaluated in accordance to the schema used. As a consequence, if the Attr.schemaTypeInfo attribute contains an ID type, isId will always return true.
isIdImplback to summary
pack-priv static native boolean isIdImpl(long peer)
setValueback to summary
public void setValue(String value) throws DOMException

Implements org.w3c.dom.Attr.setValue.

Doc from org.w3c.dom.Attr.setValue.

On retrieval, the value of the attribute is returned as a string. Character and general entity references are replaced with their values. See also the method getAttribute on the Element interface.
On setting, this creates a Text node with the unparsed contents of the string, i.e. any characters that an XML processor would recognize as markup are instead treated as literal text. See also the method Element.setAttribute().
Some specialized implementations, such as some [SVG 1.1] implementations, may do normalization automatically, even after mutation; in such case, the value on retrieval may differ from the value on setting.

Exceptions
DOMException:
NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
setValueImplback to summary
pack-priv static native void setValueImpl(long peer, String value)