| java.lang.Object org.enhydra.xml.NodeImpl org.enhydra.xml.AttrImpl
Field Summary | |
String | name Attribute name. | Element | owner Document owner. | boolean | specified If this attribute was explicitly given a value in the original
document, this is true ; otherwise, it is
false . | String | value Attribute value. |
specified | boolean specified(Code) | | If this attribute was explicitly given a value in the original
document, this is true ; otherwise, it is
false .
|
AttrImpl | public AttrImpl(Element owner, String name, String value)(Code) | | Constructs an empty AttrImpl .
Parameters: owner - document owner. Parameters: name - node name. Parameters: value - node value. |
AttrImpl | public AttrImpl(Attr attr)(Code) | | Constructs a AttrImpl from the given node.
node, as a AttrImpl . |
getName | public String getName()(Code) | | Returns the attribute name associated with this node.
the attribute name, as a String . |
getNodeName | public String getNodeName()(Code) | | Returns the name associated with this node.
the name, as a String . |
getNodeType | public short getNodeType()(Code) | | Returns the node type.
the ATTRIBUTE_NODE node type. |
getNodeValue | public String getNodeValue()(Code) | | Returns the value associated with this node.
the node value, as a String . |
getOwnerElement | public Element getOwnerElement()(Code) | | Returns the owner of this attribute.
the attribute owner node. |
getSpecified | public boolean getSpecified()(Code) | | If this attribute was explicitly given a value in the original
document, this is true ; otherwise, it is
false . Note that the implementation is in charge of this
attribute, not the user. If the user changes the value of the
attribute (even if it ends up having the same value as the default
value) then the specified flag is automatically flipped
to true . To re-specify the attribute as the default
value from the DTD, the user must delete the attribute. The
implementation will then make a new attribute available with
specified set to false and the default
value (if one exists).
In summary: If the attribute has an assigned value in the document
then specified is true , and the value is
the assigned value.If the attribute has no assigned value in the
document and has a default value in the DTD, then
specified is false , and the value is the
default value in the DTD.If the attribute has no assigned value in
the document and has a value of #IMPLIED in the DTD, then the
attribute does not appear in the structure model of the document.If
the ownerElement attribute is null (i.e.
because it was just created or was set to null by the
various removal and cloning operations) specified is
true .
Retuns always true .
|
getValue | public String getValue()(Code) | | Returns the value associated with this attributes.
the node attributes, as a String . |
isDefaultNamespace | public boolean isDefaultNamespace(String arg0)(Code) | | |
isEqualNode | public boolean isEqualNode(Node arg0)(Code) | | |
isId | public boolean isId()(Code) | | |
isSameNode | public boolean isSameNode(Node arg0)(Code) | | |
setNodeValue | public void setNodeValue(String value)(Code) | | Sets the value of this node to the given one.
the node value, as a String . |
setValue | public void setValue(String value)(Code) | | Sets the value of this attribute to the given one.
Parameters: value - the new attribute value, as a String . |
|
|