Class XmlTitles
- java.lang.Object
-
- de.ipk_gatersleben.bit.bi.edal.primary_data.reference.datacite.xml.XmlTitles
-
- All Implemented Interfaces:
java.io.Serializable
public class XmlTitles extends java.lang.Object implements java.io.SerializableXML mapping class for the 'titles' element.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description XmlTitles()Default constructor.
-
Method Summary
Modifier and Type Method Description voidaddTitle(int index, XmlTitle title)voidaddTitle(XmlTitle title)java.util.Iterator<? extends XmlTitle>enumerateTitle()Return anIteratorof allXmlTitle.XmlTitle[]getTitle()Returns the contents of the collection in an Array.XmlTitlegetTitle(int index)Return theXmlTitleat the specified position in theList.intgetTitleCount()Return the number of theXmlTitle.voidremoveAllTitle()Remove allXmlTitlein theList.booleanremoveTitle(XmlTitle title)Remove a specifiedXmlTitle.XmlTitleremoveTitleAt(int index)Remove aXmlTitleat the specified position.voidsetTitle(int index, XmlTitle title)Set theXmlTitleat the specified position of theList.voidsetTitle(XmlTitle[] titleArray)Set a allXmlTitleto theList.
-
-
-
Method Detail
-
addTitle
public void addTitle(XmlTitle title) throws java.lang.IndexOutOfBoundsException
- Parameters:
title- theXmlTitleto add.- Throws:
java.lang.IndexOutOfBoundsException- if the index given is outside the bounds of the collection.
-
addTitle
public void addTitle(int index, XmlTitle title) throws java.lang.IndexOutOfBoundsException
-
enumerateTitle
public java.util.Iterator<? extends XmlTitle> enumerateTitle()
Return anIteratorof allXmlTitle.- Returns:
- an Iterator over all
XmlTitleelements.
-
getTitle
public XmlTitle getTitle(int index) throws java.lang.IndexOutOfBoundsException
Return theXmlTitleat the specified position in theList.
-
getTitle
public XmlTitle[] getTitle()
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
-
getTitleCount
public int getTitleCount()
Return the number of theXmlTitle.- Returns:
- the size of this collection
-
removeAllTitle
public void removeAllTitle()
Remove allXmlTitlein theList.
-
removeTitle
public boolean removeTitle(XmlTitle title)
Remove a specifiedXmlTitle.- Parameters:
title- theXmlTitleto remove.- Returns:
- true if the object was removed from the collection.
-
removeTitleAt
public XmlTitle removeTitleAt(int index)
Remove aXmlTitleat the specified position.- Parameters:
index- the position of theXmlTitleto remove.- Returns:
- the element removed from the collection
-
setTitle
public void setTitle(int index, XmlTitle title) throws java.lang.IndexOutOfBoundsExceptionSet theXmlTitleat the specified position of theList.- Parameters:
title- the position to set theXmlTitle.index- the position to set.- Throws:
java.lang.IndexOutOfBoundsException- if the index given is outside the bounds of the collection
-
-