Class XmlDates
- java.lang.Object
-
- de.ipk_gatersleben.bit.bi.edal.primary_data.reference.datacite.xml.XmlDates
-
- All Implemented Interfaces:
java.io.Serializable
public class XmlDates extends java.lang.Object implements java.io.SerializableXML mapping class for the 'dates' element.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description XmlDates()Default constructorXmlDates(DateEvents elementValue)
-
Method Summary
Modifier and Type Method Description voidaddDate(int index, XmlDate date)voidaddDate(XmlDate date)java.util.Iterator<? extends XmlDate>enumerateDate()Return anIteratorof allXmlDate.XmlDate[]getDate()Returns the contents of the collection in an Array.XmlDategetDate(int index)Return theXmlDateat the specified position in theList.intgetDateCount()Return the number of theXmlDate.voidremoveAllDate()Remove allXmlDatein theList.booleanremoveDate(XmlDate date)Remove a specifiedXmlDate.XmlDateremoveDateAt(int index)Remove aXmlDateat the specified position.voidsetDate(int index, XmlDate date)Set theXmlDateat the specified position of theList.voidsetDate(XmlDate[] dateArray)Set a allXmlDateto theList.
-
-
-
Constructor Detail
-
XmlDates
public XmlDates()
Default constructor
-
XmlDates
public XmlDates(DateEvents elementValue)
-
-
Method Detail
-
addDate
public void addDate(XmlDate date) throws java.lang.IndexOutOfBoundsException
- Parameters:
date- theXmlDateto add.- Throws:
java.lang.IndexOutOfBoundsException- if the index given is outside the bounds of the collection.
-
addDate
public void addDate(int index, XmlDate date) throws java.lang.IndexOutOfBoundsException
-
enumerateDate
public java.util.Iterator<? extends XmlDate> enumerateDate()
Return anIteratorof allXmlDate.- Returns:
- an Iterator over all
XmlDateelements.
-
getDate
public XmlDate getDate(int index) throws java.lang.IndexOutOfBoundsException
Return theXmlDateat the specified position in theList.
-
getDate
public XmlDate[] getDate()
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
-
getDateCount
public int getDateCount()
Return the number of theXmlDate.- Returns:
- the size of this collection
-
removeAllDate
public void removeAllDate()
Remove allXmlDatein theList.
-
removeDate
public boolean removeDate(XmlDate date)
Remove a specifiedXmlDate.- Parameters:
date- theXmlDateto remove.- Returns:
- true if the object was removed from the collection.
-
removeDateAt
public XmlDate removeDateAt(int index)
Remove aXmlDateat the specified position.- Parameters:
index- the position of theXmlDateto remove.- Returns:
- the element removed from the collection
-
setDate
public void setDate(int index, XmlDate date) throws java.lang.IndexOutOfBoundsExceptionSet theXmlDateat the specified position of theList.
-
-