public class Category extends Object implements Serializable
Constructor and Description |
---|
Category() |
Modifier and Type | Method and Description |
---|---|
void |
addService(int index,
String vService) |
void |
addService(String vService) |
void |
deleteNormal() |
void |
deleteWarning() |
Enumeration<String> |
enumerateService()
Method enumerateService.
|
boolean |
equals(Object obj)
Overrides the java.lang.Object.equals method.
|
String |
getComment()
Returns the value of field 'comment'.
|
String |
getLabel()
Returns the value of field 'label'.
|
double |
getNormal()
Returns the value of field 'normal'.
|
String |
getRule()
Returns the value of field 'rule'.
|
String[] |
getService()
Method getService.Returns the contents of the collection in
an Array.
|
String |
getService(int index)
Method getService.
|
List<String> |
getServiceCollection()
Method getServiceCollection.Returns a reference to
'_serviceList'.
|
int |
getServiceCount()
Method getServiceCount.
|
double |
getWarning()
Returns the value of field 'warning'.
|
int |
hashCode()
Overrides the java.lang.Object.hashCode method.
|
boolean |
hasNormal()
Method hasNormal.
|
boolean |
hasWarning()
Method hasWarning.
|
boolean |
isValid()
Method isValid.
|
Iterator<String> |
iterateService()
Method iterateService.
|
void |
marshal(ContentHandler handler) |
void |
marshal(Writer out) |
void |
removeAllService() |
boolean |
removeService(String vService)
Method removeService.
|
String |
removeServiceAt(int index)
Method removeServiceAt.
|
void |
setComment(String comment)
Sets the value of field 'comment'.
|
void |
setLabel(String label)
Sets the value of field 'label'.
|
void |
setNormal(double normal)
Sets the value of field 'normal'.
|
void |
setRule(String rule)
Sets the value of field 'rule'.
|
void |
setService(int index,
String vService) |
void |
setService(List<String> vServiceList)
Sets the value of '_serviceList' by copying the given
Vector.
|
void |
setService(String[] vServiceArray) |
void |
setServiceCollection(List<String> serviceList)
Deprecated.
|
void |
setWarning(double warning)
Sets the value of field 'warning'.
|
static Category |
unmarshal(Reader reader)
Method unmarshal.
|
void |
validate() |
public void addService(String vService) throws IndexOutOfBoundsException
vService
- IndexOutOfBoundsException
- if the index
given is outside the bounds of the collectionpublic void addService(int index, String vService) throws IndexOutOfBoundsException
index
- vService
- IndexOutOfBoundsException
- if the index
given is outside the bounds of the collectionpublic void deleteNormal()
public void deleteWarning()
public Enumeration<String> enumerateService()
public boolean equals(Object obj)
public String getComment()
public String getLabel()
public double getNormal()
public String getRule()
public String getService(int index) throws IndexOutOfBoundsException
index
- IndexOutOfBoundsException
- if the index
given is outside the bounds of the collectionpublic String[] getService()
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> getServiceCollection()
public int getServiceCount()
public double getWarning()
public boolean hasNormal()
public boolean hasWarning()
public int hashCode()
The following steps came from Effective Java Programming Language Guide by Joshua Bloch, Chapter 3
public boolean isValid()
public Iterator<String> iterateService()
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 removeAllService()
public boolean removeService(String vService)
vService
- public String removeServiceAt(int index)
index
- public void setComment(String comment)
comment
- the value of field 'comment'.public void setLabel(String label)
label
- the value of field 'label'.public void setNormal(double normal)
normal
- the value of field 'normal'.public void setRule(String rule)
rule
- the value of field 'rule'.public void setService(int index, String vService) throws IndexOutOfBoundsException
index
- vService
- IndexOutOfBoundsException
- if the index
given is outside the bounds of the collectionpublic void setService(String[] vServiceArray)
vServiceArray
- public void setService(List<String> vServiceList)
vServiceList
- the Vector to copy.public void setServiceCollection(List<String> serviceList)
serviceList
- the Vector to set.public void setWarning(double warning)
warning
- the value of field 'warning'.public static Category 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 © 2016. All rights reserved.