public abstract class XAttributeImpl extends java.lang.Object implements XAttribute
| Modifier | Constructor and Description |
|---|---|
protected |
XAttributeImpl(java.lang.String key)
Creates a new, empty attribute.
|
protected |
XAttributeImpl(java.lang.String key,
XExtension extension)
Creates a new attribute.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
clone()
Attributes must be cloneable.
|
int |
compareTo(XAttribute o) |
boolean |
equals(java.lang.Object obj) |
XAttributeMap |
getAttributes()
Retrieves the attributes set for this element.
|
XExtension |
getExtension()
Retrieves the extension defining this attribute.
|
java.util.Set<XExtension> |
getExtensions()
Retrieves the extensions used by this element, i.e.
|
java.lang.String |
getKey()
Retrieves the key, i.e.
|
boolean |
hasAttributes()
Checks for the existence of attributes.
|
int |
hashCode() |
void |
setAttributes(XAttributeMap attributes)
Sets the map of attributes for this element.
|
finalize, getClass, notify, notifyAll, toString, wait, wait, waitaccept, toStringprotected XAttributeImpl(java.lang.String key)
key - The key, i.e. unique name identifier, of this attribute.protected XAttributeImpl(java.lang.String key,
XExtension extension)
key - The key, i.e. unique name identifier, of this attribute.extension - The extension used for defining this attribute.public java.lang.String getKey()
XAttributegetKey in interface XAttributepublic XExtension getExtension()
XAttributegetExtension in interface XAttributenull, if there is no extension
defining this attribute.public XAttributeMap getAttributes()
XAttributablegetAttributes in interface XAttributablepublic void setAttributes(XAttributeMap attributes)
XAttributablesetAttributes in interface XAttributableattributes - A map of attributes.public boolean hasAttributes()
XAttributableXAttributable.getAttributes() in certain situations.hasAttributes in interface XAttributablepublic java.util.Set<XExtension> getExtensions()
XAttributablegetExtensions in interface XAttributablepublic java.lang.Object clone()
XAttributeclone in interface XAttributeclone in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic int compareTo(XAttribute o)
compareTo in interface java.lang.Comparable<XAttribute>