Modifier and Type | Field and Description |
---|---|
static ElementKey<java.lang.Void,Category> |
KEY
The key for this element.
|
static AttributeKey<java.lang.String> |
LABEL
The category label attribute.
|
static AttributeKey<java.lang.String> |
SCHEME
The category scheme attribute.
|
static AttributeKey<java.lang.String> |
TERM
The category term attribute.
|
static AttributeKey<java.lang.String> |
XML_LANG
Qualified name for the XML lang attribute
|
Constructor and Description |
---|
Category()
Constructs a new category instance using the default metadata.
|
Category(java.lang.String category)
Constructs a new category from a Category string.
|
Category(java.lang.String scheme,
java.lang.String term)
Constructs a new category with the specified scheme and term values.
|
Category(java.lang.String scheme,
java.lang.String term,
java.lang.String label)
Constructs a new category with the specified scheme, term, and label
values.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getLabel()
Returns the category label or
null if there is no label value. |
java.lang.String |
getLabelLang()
Returns the language associated with the category label (or
null
if undefined). |
java.lang.String |
getScheme()
Returns the category scheme or
null if the category does not have
a scheme. |
java.lang.String |
getTerm()
Returns the category term.
|
int |
hashCode() |
Category |
lock()
Locks this element.
|
static void |
registerMetadata(MetadataRegistry registry)
Registers the metadata for this element.
|
void |
setLabel(java.lang.String label)
Sets the category label.
|
void |
setLabelLang(java.lang.String lang)
Sets the language associated with the category label (or
nulll if
undefined). |
void |
setScheme(java.lang.String scheme)
Sets the category scheme.
|
void |
setTerm(java.lang.String term)
Sets the category term value.
|
java.lang.String |
toString() |
addElement, addElement, addElement, clear, createElement, createElement, getAttributeCount, getAttributeIterator, getAttributeIterator, getAttributeValue, getAttributeValue, getDefaultKey, getElement, getElement, getElementCount, getElementId, getElementIterator, getElementIterator, getElementKey, getElements, getElements, getElementSet, getElementSet, getElementValue, getElementValue, getTextValue, getTextValue, hasAttribute, hasAttribute, hasElement, hasElement, hasTextValue, isLocked, removeAttribute, removeAttribute, removeAttributeValue, removeAttributeValue, removeElement, removeElement, removeElement, removeElement, replaceElement, resolve, resolve, setAttributeValue, setAttributeValue, setElement, setElement, setElement, setTextValue, visit
public static final ElementKey<java.lang.Void,Category> KEY
public static final AttributeKey<java.lang.String> SCHEME
public static final AttributeKey<java.lang.String> TERM
public static final AttributeKey<java.lang.String> LABEL
public static final AttributeKey<java.lang.String> XML_LANG
public Category()
public Category(java.lang.String category)
category
- the category stringpublic Category(java.lang.String scheme, java.lang.String term)
public Category(java.lang.String scheme, java.lang.String term, java.lang.String label)
public static void registerMetadata(MetadataRegistry registry)
public Category lock()
Element
public java.lang.String getScheme()
null
if the category does not have
a scheme.public void setScheme(java.lang.String scheme)
null
indicates that there is
no category scheme.scheme
- category scheme URI.public java.lang.String getTerm()
public void setTerm(java.lang.String term)
term
- public java.lang.String getLabel()
null
if there is no label value.public void setLabel(java.lang.String label)
null
indicates that there is
no label.label
- category label value.public java.lang.String getLabelLang()
null
if undefined).public void setLabelLang(java.lang.String lang)
nulll
if
undefined).lang
- label language.