|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.teamkonzept.dom4jb.dom.NodeList | +--com.teamkonzept.dom4jb.dom.Node | +--com.teamkonzept.dom4jb.dom.NamedNode | +--com.teamkonzept.dom4jb.dom.Attribute
Field Summary |
Fields inherited from class com.teamkonzept.dom4jb.dom.Node |
document |
Fields inherited from class com.teamkonzept.dom4jb.dom.NodeList |
EMPTY, initialCapacity, nodeData, nodeIterator, parent, size |
Fields inherited from interface org.w3c.dom.Node |
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE |
Constructor Summary | |
Attribute(Document document,
AttributeDescriptor descriptor,
Object bean)
Creates new Attribute |
Method Summary | |
boolean |
accept(Filter filter)
|
int |
getChildIndex()
|
String |
getName()
Returns the name of this attribute. |
short |
getNodeType()
A code representing the type of the Attribute |
String |
getNodeValue()
The value of this node, depending on its type; see the table above. |
Element |
getOwnerElement()
The Element node this attribute is attached to or
null if this attribute is not in use. |
Node |
getParentNode()
The parent of this node. |
boolean |
getSpecified()
If this attribute was explicitly given a value in the original document, this is true ; otherwise, it is
false . |
String |
getValue()
On retrieval, the value of the attribute is returned as a string. |
void |
setValue(String value)
On retrieval, the value of the attribute is returned as a string. |
Methods inherited from class com.teamkonzept.dom4jb.dom.NamedNode |
getLocalName, getNamespaceURI, getNamingItem, getNodeName, getPrefix, setPrefix |
Methods inherited from class com.teamkonzept.dom4jb.dom.Node |
appendChild, attach, cloneNode, getAttributes, getChildNodes, getFirstChild, getLastChild, getNextSibling, getOwnerDocument, getPreviousSibling, hasAttributes, hasChildNodes, insertBefore, isSupported, normalize, removeChild, replaceChild, setNodeValue |
Methods inherited from class com.teamkonzept.dom4jb.dom.NodeList |
add, clear, ensureCapacity, get, getLength, isEmpty, item, setIterator, setParentNode, size, trimToSize |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.w3c.dom.Node |
appendChild, cloneNode, getAttributes, getChildNodes, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getOwnerDocument, getPrefix, getPreviousSibling, hasAttributes, hasChildNodes, insertBefore, isSupported, normalize, removeChild, replaceChild, setNodeValue, setPrefix |
Constructor Detail |
public Attribute(Document document, AttributeDescriptor descriptor, Object bean)
Method Detail |
public int getChildIndex()
getChildIndex
in class Node
public final short getNodeType()
getNodeType
in interface Node
Node.ATTRIBUTE_NODE
public boolean getSpecified()
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).
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
.
getSpecified
in interface Attr
public String getName()
getName
in interface Attr
public Element getOwnerElement()
Element
node this attribute is attached to or
null
if this attribute is not in use.
getOwnerElement
in interface Attr
public void setValue(String value)
getAttribute
on the
Element
interface.
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 setAttribute
on the Element
interface.
setValue
in interface Attr
public String getValue()
getAttribute
on the
Element
interface.
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 setAttribute
on the Element
interface.
getValue
in interface Attr
public String getNodeValue()
null
, setting it has no effect.
getNodeValue
in interface Node
getNodeValue
in class Node
public Node getParentNode()
Attr
may have not a parent.
getParentNode
in interface Node
getParentNode
in class NodeList
public boolean accept(Filter filter)
accept
in class Node
Node.accept(Filter)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |