Class XmlAlternateIdentifiers
- java.lang.Object
-
- de.ipk_gatersleben.bit.bi.edal.primary_data.reference.datacite.xml.XmlAlternateIdentifiers
-
- All Implemented Interfaces:
java.io.Serializable
public class XmlAlternateIdentifiers extends java.lang.Object implements java.io.Serializable
XML mapping class for the 'alternativeIdentifiers' element.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description XmlAlternateIdentifiers()
Default constructor.
-
Method Summary
-
-
-
Method Detail
-
addAlternateIdentifier
public void addAlternateIdentifier(XmlAlternateIdentifier alternateIdentifier) throws java.lang.IndexOutOfBoundsException
- Parameters:
alternateIdentifier
- theXmlAlternateIdentifier
to add.- Throws:
java.lang.IndexOutOfBoundsException
- if the index given is outside the bounds of the collection.
-
addAlternateIdentifier
public void addAlternateIdentifier(int index, XmlAlternateIdentifier alternateIdentifier) throws java.lang.IndexOutOfBoundsException
- Parameters:
index
- the position to insert theXmlAlternateIdentifier
.alternateIdentifier
- theXmlAlternateIdentifier
to add.- Throws:
java.lang.IndexOutOfBoundsException
- if the index given is outside the bounds of the collection
-
enumerateAlternateIdentifier
public java.util.Iterator<? extends XmlAlternateIdentifier> enumerateAlternateIdentifier()
Return anIterator
of allXmlAlternateIdentifier
.- Returns:
- an Iterator over all
XmlAlternateIdentifier
elements.
-
getAlternateIdentifier
public XmlAlternateIdentifier getAlternateIdentifier(int index) throws java.lang.IndexOutOfBoundsException
Return theXmlAlternateIdentifier
at the specified position in theList
.- Parameters:
index
- the position of the searchedXmlAlternateIdentifier
.- Returns:
- the value of the
XmlAlternateIdentifier
at the given index - Throws:
java.lang.IndexOutOfBoundsException
- if the index given is outside the bounds of the collection
-
getAlternateIdentifier
public XmlAlternateIdentifier[] getAlternateIdentifier()
Returns the contents of the collection in an Array.Note: Just in case the collection contents are changing in another thread, we pass a 0-length Array of the correct type into the API call. This way we know that the Array returned is of exactly the correct length.
- Returns:
- this collection as an Array
-
getAlternateIdentifierCount
public int getAlternateIdentifierCount()
Return the number of theXmlAlternateIdentifier
.- Returns:
- the size of this collection
-
removeAllAlternateIdentifier
public void removeAllAlternateIdentifier()
Remove allXmlAlternateIdentifier
in theList
.
-
removeAlternateIdentifier
public boolean removeAlternateIdentifier(XmlAlternateIdentifier alternateIdentifier)
Remove a specifiedXmlAlternateIdentifier
.- Parameters:
alternateIdentifier
- theXmlAlternateIdentifier
to remove.- Returns:
- true if the object was removed from the collection.
-
removeAlternateIdentifierAt
public XmlAlternateIdentifier removeAlternateIdentifierAt(int index)
Remove aXmlAlternateIdentifier
at the specified position.- Parameters:
index
- the position of theXmlAlternateIdentifier
to remove.- Returns:
- the element removed from the collection
-
setAlternateIdentifier
public void setAlternateIdentifier(int index, XmlAlternateIdentifier alternateIdentifier) throws java.lang.IndexOutOfBoundsException
Set theXmlAlternateIdentifier
at the specified position of theList
.- Parameters:
index
- the position to set theXmlAlternateIdentifier
.alternateIdentifier
- theXmlAlternateIdentifier
to set.- Throws:
java.lang.IndexOutOfBoundsException
- if the index given is outside the bounds of the collection
-
setAlternateIdentifier
public void setAlternateIdentifier(XmlAlternateIdentifier[] alternateIdentifierArray)
Set a allXmlAlternateIdentifier
to theList
.- Parameters:
alternateIdentifierArray
- the array of alternate identifiers to set
-
-