|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mycore.datamodel.metadata.MCRMetaDefault
org.mycore.datamodel.metadata.MCRMetaLink
org.mycore.datamodel.metadata.MCRMetaLinkID
public final class MCRMetaLinkID
This class implements all method for special handling with the MCRMetaLink part of a metadata object. The MCRMetaLinkID class present two types. At once a reference only of a other MCRObject. At second a bidirectional link between two MCRObject's. Optional you can append the reference with the label attribute. See to W3C XLink Standard for more informations.
<tag class="MCRMetaLinkID">
<subtag xlink:type="locator" xlink:href=" MCRObjectID"
xlink:label="..." xlink:title="..."/>
<subtag xlink:type="arc" xlink:from=" MCRObjectID"
xlink:to="MCRObjectID"/>
</tag>
| Field Summary |
|---|
| Fields inherited from class org.mycore.datamodel.metadata.MCRMetaLink |
|---|
from, href, label, linktype, MAX_XLINK_FROM_LENGTH, MAX_XLINK_HREF_LENGTH, MAX_XLINK_LABEL_LENGTH, MAX_XLINK_TITLE_LENGTH, MAX_XLINK_TO_LENGTH, MAX_XLINK_TYPE_LENGTH, title, to |
| Fields inherited from class org.mycore.datamodel.metadata.MCRMetaDefault |
|---|
datapart, DEFAULT_DATAPART, DEFAULT_INHERITED, DEFAULT_LANG_LENGTH, DEFAULT_LANGUAGE, DEFAULT_STRING_LENGTH, DEFAULT_TYPE_LENGTH, inherited, lang, LOGGER, NL, subtag, type |
| Constructor Summary | |
|---|---|
MCRMetaLinkID()
This is the constructor. |
|
MCRMetaLinkID(String set_datapart,
String set_subtag,
String default_lang,
int set_inherted)
This is the constructor. |
|
| Method Summary | |
|---|---|
MCRObjectID |
getXLinkFromID()
This method get the xlink:from element as MCRObjectID. |
MCRObjectID |
getXLinkHrefID()
This method get the xlink:href element as MCRObjectID. |
MCRObjectID |
getXLinkToID()
This method get the xlink:to element as MCRObjectID. |
void |
setBiLink(MCRObjectID set_from,
MCRObjectID set_to,
String set_title)
This method set a bidirectional link with xlink:from, xlink:to and xlink:title. |
void |
setBiLink(String set_from,
String set_to,
String set_title)
This method set a bidirectional link with xlink:from, xlink:to and xlink:title. |
void |
setFromDOM(Element element)
This method read the XML input stream part from a DOM part for the metadata of the document. |
void |
setReference(MCRObjectID set_href,
String set_label,
String set_title)
This method set a reference with xlink:href, xlink:label and xlink:title. |
void |
setReference(String set_href,
String set_label,
String set_title)
This method set a reference with xlink:href, xlink:label and xlink:title. |
| Methods inherited from class org.mycore.datamodel.metadata.MCRMetaLink |
|---|
clone, compare, createXML, debug, getXLinkFrom, getXLinkHref, getXLinkLabel, getXLinkTitle, getXLinkTo, getXLinkType, isValid, setXLinkLabel, setXLinkTitle |
| Methods inherited from class org.mycore.datamodel.metadata.MCRMetaDefault |
|---|
debugDefault, decrementInherited, getDataPart, getInherited, getInheritedToString, getLang, getSubTag, getType, incrementInherited, setDataPart, setInherited, setLang, setSubTag, setType |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MCRMetaLinkID()
public MCRMetaLinkID(String set_datapart,
String set_subtag,
String default_lang,
int set_inherted)
throws MCRException
set_datapart - the global part of the elements like 'metadata'
or 'service' or soset_subtag - the name of the subtagdefault_lang - the default languageset_inherted - a value >= 0
MCRException - if the set_datapart or set_subtag value is null or
empty| Method Detail |
|---|
public final void setReference(String set_href,
String set_label,
String set_title)
throws MCRException
setReference in class MCRMetaLinkset_href - the reference as MCRObjectID stringset_label - the new label stringset_title - the new title string
MCRException - if the set_href value is null, empty or not a MCRObjectID
public final void setReference(MCRObjectID set_href,
String set_label,
String set_title)
throws MCRException
set_href - the reference as MCRObjectIDset_label - the new label stringset_title - the new title string
MCRException - if the set_href value is null, empty or not a MCRObjectID
public final void setBiLink(String set_from,
String set_to,
String set_title)
throws MCRException
setBiLink in class MCRMetaLinkset_from - the source MCRObjectID stringset_to - the target MCRObjectID stringset_title - the new title string
MCRException - if the from or to element is not a MCRObjectId
public final void setBiLink(MCRObjectID set_from,
MCRObjectID set_to,
String set_title)
throws MCRException
set_from - the source MCRObjectIDset_to - the target MCRObjectIDset_title - the new title string
MCRException - if the from or to element is not a MCRObjectIdpublic final MCRObjectID getXLinkHrefID()
public final MCRObjectID getXLinkFromID()
public final MCRObjectID getXLinkToID()
public final void setFromDOM(Element element)
setFromDOM in interface MCRMetaInterfacesetFromDOM in class MCRMetaLinkelement - a relevant DOM element for the metadata
MCRException - if the xlink:type is not locator or arc or if href or from
and to are not a MCRObjectID
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||