public class Section extends Object implements Serializable
Constructor and Description |
---|
Section() |
Modifier and Type | Method and Description |
---|---|
void |
addCategory(int index,
String vCategory) |
void |
addCategory(String vCategory) |
Enumeration<String> |
enumerateCategory()
Method enumerateCategory.
|
boolean |
equals(Object obj)
Overrides the java.lang.Object.equals method.
|
String[] |
getCategory()
Method getCategory.Returns the contents of the collection in
an Array.
|
String |
getCategory(int index)
Method getCategory.
|
List<String> |
getCategoryCollection()
Method getCategoryCollection.Returns a reference to
'_categoryList'.
|
int |
getCategoryCount()
Method getCategoryCount.
|
String |
getSectionName()
Returns the value of field 'sectionName'.
|
int |
hashCode()
Overrides the java.lang.Object.hashCode method.
|
boolean |
isValid()
Method isValid.
|
Iterator<String> |
iterateCategory()
Method iterateCategory.
|
void |
marshal(ContentHandler handler) |
void |
marshal(Writer out) |
void |
removeAllCategory() |
boolean |
removeCategory(String vCategory)
Method removeCategory.
|
String |
removeCategoryAt(int index)
Method removeCategoryAt.
|
void |
setCategory(int index,
String vCategory) |
void |
setCategory(List<String> vCategoryList)
Sets the value of '_categoryList' by copying the given
Vector.
|
void |
setCategory(String[] vCategoryArray) |
void |
setCategoryCollection(List<String> categoryList)
Deprecated.
|
void |
setSectionName(String sectionName)
Sets the value of field 'sectionName'.
|
static Section |
unmarshal(Reader reader)
Method unmarshal.
|
void |
validate() |
public void addCategory(String vCategory) throws IndexOutOfBoundsException
vCategory
- IndexOutOfBoundsException
- if the index
given is outside the bounds of the collectionpublic void addCategory(int index, String vCategory) throws IndexOutOfBoundsException
index
- vCategory
- IndexOutOfBoundsException
- if the index
given is outside the bounds of the collectionpublic Enumeration<String> enumerateCategory()
public boolean equals(Object obj)
public String getCategory(int index) throws IndexOutOfBoundsException
index
- IndexOutOfBoundsException
- if the index
given is outside the bounds of the collectionpublic String[] getCategory()
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.
public List<String> getCategoryCollection()
public int getCategoryCount()
public String getSectionName()
public int hashCode()
The following steps came from Effective Java Programming Language Guide by Joshua Bloch, Chapter 3
public boolean isValid()
public Iterator<String> iterateCategory()
public void marshal(Writer out) throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
out
- org.exolab.castor.xml.MarshalException
- if object is
null or if any SAXException is thrown during marshalingorg.exolab.castor.xml.ValidationException
- if this
object is an invalid instance according to the schemapublic void marshal(ContentHandler handler) throws IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
handler
- IOException
- if an IOException occurs during
marshalingorg.exolab.castor.xml.ValidationException
- if this
object is an invalid instance according to the schemaorg.exolab.castor.xml.MarshalException
- if object is
null or if any SAXException is thrown during marshalingpublic void removeAllCategory()
public boolean removeCategory(String vCategory)
vCategory
- public String removeCategoryAt(int index)
index
- public void setCategory(int index, String vCategory) throws IndexOutOfBoundsException
index
- vCategory
- IndexOutOfBoundsException
- if the index
given is outside the bounds of the collectionpublic void setCategory(String[] vCategoryArray)
vCategoryArray
- public void setCategory(List<String> vCategoryList)
vCategoryList
- the Vector to copy.public void setCategoryCollection(List<String> categoryList)
categoryList
- the Vector to set.public void setSectionName(String sectionName)
sectionName
- the value of field 'sectionName'.public static Section unmarshal(Reader reader) throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
reader
- org.exolab.castor.xml.MarshalException
- if object is
null or if any SAXException is thrown during marshalingorg.exolab.castor.xml.ValidationException
- if this
object is an invalid instance according to the schemapublic void validate() throws org.exolab.castor.xml.ValidationException
org.exolab.castor.xml.ValidationException
- if this
object is an invalid instance according to the schemaCopyright © 2017. All rights reserved.