com.ail.insurance.policy
Class Section

java.lang.Object
  extended by com.ail.core.Type
      extended by com.ail.insurance.policy.Section
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable

public class Section
extends Type

A section with the policy.

Version:
$Revision: 1.5 $
See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.ail.core.Type
jXPathContext, NOT_PERSISTED
 
Constructor Summary
Section()
           
 
Method Summary
 void addAssetId(java.lang.String assetId)
          Add a assetId to the collection associated with this object.
 void addCoverage(Coverage coverage)
          Add a coverage to the list associated with this section.
 void addExcessId(java.lang.String excessId)
          Add an instance of String to the list associated with this object.
 void addUninsuredAssetId(java.lang.String uninsuredAssetId)
          Add a uninsuredAssetId to the collection associated with this object.
 void addWording(Wording wording)
          Add an instance of com.ail.insurance.policy.Wording to the list associated with this object.
 AssessmentSheet getAssessmentSheet()
          Get the assessment sheet associated with this section.
 java.util.List<java.lang.String> getAssetId()
          Fetch the collection of assetId objects associated with this instance.
 java.lang.String getAssetId(int i)
          Get the instance of assetId at a specific index from the collection of String objects associated with this instance.
 int getAssetIdCount()
          Fetch a count of the number of assetId objects associated with this instance.
 java.util.List<Coverage> getCoverage()
          Get the collection of Coverages associagted with this section.
 Coverage getCoverage(int i)
          Get the Coverage at a specific index in the collection associated with this section.
 Coverage getCoverageById(java.lang.String coverageId)
          Fetch the coverage with a specific id from the collection associated with this section.
 int getCoverageCount()
          Get the number of Coverages associated with this section.
 java.util.List<java.lang.String> getExcessId()
          Get the collection of instances of String associated with this object.
 java.lang.String getExcessId(int i)
          Fetch a spacific String from the collection by index number.
 int getExcessIdCount()
          Get a count of the number of String instances associated with this object
 YesNo getExcluded()
          Getter returning the value of the excluded property.
 java.lang.String getExcludedAsString()
          Get the value of the excluded property as a string (as opposed to an instance of YesNo).
 java.lang.String getId()
          Get this section's ID.
 YesNo getIncluded()
          Getter returning the value of the included property.
 java.lang.String getIncludedAsString()
          Get the value of the included property as a string (as opposed to an instance of YesNo).
 java.lang.String getSectionTypeId()
          Get the section type id associated with this section.
 java.util.List<java.lang.String> getUninsuredAssetId()
          Fetch the collection of uninsuredAssetId objects associated with this instance.
 java.lang.String getUninsuredAssetId(int i)
          Get the instance of uninsuredAssetId at a specific index from the collection of String objects associated with this instance.
 int getUninsuredAssetIdCount()
          Fetch a count of the number of uninsuredAssetId objects associated with this instance.
 java.util.List<Wording> getWording()
          Get the collection of instances of com.ail.insurance.policy.Wording associated with this object.
 Wording getWording(int i)
          Fetch a spacific com.ail.insurance.policy.Wording from the collection by index number.
 int getWordingCount()
          Get a count of the number of com.ail.insurance.policy.Wording instances associated with this object
 void removeAssetId(int i)
          Remove a specific assetId from the collection of String objects associated with this object.
 void removeAssetId(java.lang.String assetId)
          Remove a specific instance of String from the collection associated with this object.
 void removeCoverage(int i)
          Remove the coverage at a specific index in the collection of Coverages associated with this section.
 void removeCoverage(java.util.List<Coverage> coverage)
          Remove the specified coverage from the list associated with this section.
 void removeExcessId(int i)
          Remove the element specified from the list.
 void removeExcessId(java.lang.String excessId)
          Remove the specified instance of String from the list.
 void removeUninsuredAssetId(int i)
          Remove a specific uninsuredAssetId from the collection of String objects associated with this object.
 void removeUninsuredAssetId(java.lang.String uninsuredAssetId)
          Remove a specific instance of uninsuredAssetId from the collection associated with this object.
 void removeWording(int i)
          Remove the element specified from the list.
 void removeWording(Wording wording)
          Remove the specified instance of com.ail.insurance.policy.Wording from the list.
 void setAssessmentSheet(AssessmentSheet assessmentSheet)
          Set the assessment sheet associated with this section.
 void setAssetId(java.util.List<java.lang.String> assetId)
          Set the collection of instances of String associated with this object.
 void setCoverage(java.util.List<Coverage> coverage)
          Set the collection of Coverages associated with this section.
 void setExcessId(java.util.List<java.lang.String> excessId)
          Set the collection of instances of String associated with this object.
 void setExcluded(YesNo excluded)
          Setter to update the value of the excluded property.
 void setExcludedAsString(java.lang.String excluded)
          Set the excluded property as a String.
 void setId(java.lang.String id)
          Set this section's ID.
 void setIncluded(YesNo included)
          Setter to update the value of the included property.
 void setIncludedAsString(java.lang.String included)
          Set the included property as a String.
 void setSectionTypeId(java.lang.String sectionTypeId)
          Set the section type id.
 void setUninsuredAssetId(java.util.List<java.lang.String> uninsuredAssetId)
          Set the collection of instances of uninsuredAssetId associated with this object.
 void setWording(java.util.List<Wording> wording)
          Set the collection of instances of com.ail.insurance.policy.Wording associated with this object.
 
Methods inherited from class com.ail.core.Type
addAttribute, clone, deleteLock, deleteSerialVersion, fetchJXPathContext, getAttribute, getAttribute, getAttributeCount, getForeignSystemId, getLock, getSerialVersion, getSystemId, hasLock, hasSerialVersion, hasSystemId, isPersisted, markAsNotPersisted, mergeWithDataFrom, removeAttribute, removeAttribute, setAttribute, setForeignSystemId, setLock, setSerialVersion, setSystemId, xpathGet, xpathGet, xpathIterate, xpathSet
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Section

public Section()
Method Detail

getId

public java.lang.String getId()
Get this section's ID. This ID is unique within a policy.

Returns:
Section's ID

setId

public void setId(java.lang.String id)
Set this section's ID.

Parameters:
id - Section's ID
See Also:
getId()

getCoverage

public java.util.List<Coverage> getCoverage()
Get the collection of Coverages associagted with this section. Coverages exist at both the section and section levels, this method will only return those associated with the section. Use getCoverage() to get those associated with specific sections.

Returns:
A collection of Coverages

setCoverage

public void setCoverage(java.util.List<Coverage> coverage)
Set the collection of Coverages associated with this section.

Parameters:
coverage - The collection of coverages to be associated with the section.
See Also:
getCoverage()

getCoverageCount

public int getCoverageCount()
Get the number of Coverages associated with this section.

Returns:
The number of coverages associated with this section.

getCoverage

public Coverage getCoverage(int i)
Get the Coverage at a specific index in the collection associated with this section.

Parameters:
i - Index to return the coverage from.
Returns:
Coverage

removeCoverage

public void removeCoverage(int i)
Remove the coverage at a specific index in the collection of Coverages associated with this section.

Parameters:
i - Index of coverage to remove.

addCoverage

public void addCoverage(Coverage coverage)
Add a coverage to the list associated with this section.

Parameters:
coverage - Coverage to add to the list.

removeCoverage

public void removeCoverage(java.util.List<Coverage> coverage)
Remove the specified coverage from the list associated with this section.

Parameters:
coverage - Coverage to be removed

getCoverageById

public Coverage getCoverageById(java.lang.String coverageId)
Fetch the coverage with a specific id from the collection associated with this section.

Parameters:
coverageId - ID of coverage to be returned
Returns:
Coverage, or null if no match is found.

getAssetId

public java.util.List<java.lang.String> getAssetId()
Fetch the collection of assetId objects associated with this instance.

Returns:
A collection of instances of String.

setAssetId

public void setAssetId(java.util.List<java.lang.String> assetId)
Set the collection of instances of String associated with this object.

Parameters:
assetId - A collection of instances of String

getAssetIdCount

public int getAssetIdCount()
Fetch a count of the number of assetId objects associated with this instance.

Returns:
Count of assetId objects.

getAssetId

public java.lang.String getAssetId(int i)
Get the instance of assetId at a specific index from the collection of String objects associated with this instance.

Parameters:
i - Index
Returns:
Instance of String found at index i.

removeAssetId

public void removeAssetId(int i)
Remove a specific assetId from the collection of String objects associated with this object.

Parameters:
i - Index of assetId to remove.

addAssetId

public void addAssetId(java.lang.String assetId)
Add a assetId to the collection associated with this object.

Parameters:
assetId - Instance of String to add.

removeAssetId

public void removeAssetId(java.lang.String assetId)
Remove a specific instance of String from the collection associated with this object.

Parameters:
assetId - Object to be removed from the collection.

getUninsuredAssetId

public java.util.List<java.lang.String> getUninsuredAssetId()
Fetch the collection of uninsuredAssetId objects associated with this instance.

Returns:
A collection of instances of String.

setUninsuredAssetId

public void setUninsuredAssetId(java.util.List<java.lang.String> uninsuredAssetId)
Set the collection of instances of uninsuredAssetId associated with this object.

Parameters:
uninsuredAssetId - A collection of instances of String

getUninsuredAssetIdCount

public int getUninsuredAssetIdCount()
Fetch a count of the number of uninsuredAssetId objects associated with this instance.

Returns:
Count of uninsuredAssetId objects.

getUninsuredAssetId

public java.lang.String getUninsuredAssetId(int i)
Get the instance of uninsuredAssetId at a specific index from the collection of String objects associated with this instance.

Parameters:
i - Index
Returns:
Instance of String found at index i.

removeUninsuredAssetId

public void removeUninsuredAssetId(int i)
Remove a specific uninsuredAssetId from the collection of String objects associated with this object.

Parameters:
i - Index of uninsuredAssetId to remove.

addUninsuredAssetId

public void addUninsuredAssetId(java.lang.String uninsuredAssetId)
Add a uninsuredAssetId to the collection associated with this object.

Parameters:
uninsuredAssetId - Instance of String to add.

removeUninsuredAssetId

public void removeUninsuredAssetId(java.lang.String uninsuredAssetId)
Remove a specific instance of uninsuredAssetId from the collection associated with this object.

Parameters:
uninsuredAssetId - Object to be removed from the collection.

getAssessmentSheet

public AssessmentSheet getAssessmentSheet()
Get the assessment sheet associated with this section.

Returns:
The assessment sheet.

setAssessmentSheet

public void setAssessmentSheet(AssessmentSheet assessmentSheet)
Set the assessment sheet associated with this section.

Parameters:
assessmentSheet - The assessment sheet

getSectionTypeId

public java.lang.String getSectionTypeId()
Get the section type id associated with this section. This id is used to associate an instance of a section with the rules used to process it.

Returns:
Section type id.

setSectionTypeId

public void setSectionTypeId(java.lang.String sectionTypeId)
Set the section type id.

Parameters:
sectionTypeId -
See Also:
getSectionTypeId()

getWording

public java.util.List<Wording> getWording()
Get the collection of instances of com.ail.insurance.policy.Wording associated with this object.

Returns:
wording A collection of instances of Excess
See Also:
setWording(java.util.List)

setWording

public void setWording(java.util.List<Wording> wording)
Set the collection of instances of com.ail.insurance.policy.Wording associated with this object.

Parameters:
wording - A collection of instances of Excess
See Also:
getWording()

getWordingCount

public int getWordingCount()
Get a count of the number of com.ail.insurance.policy.Wording instances associated with this object

Returns:
Number of instances

getWording

public Wording getWording(int i)
Fetch a spacific com.ail.insurance.policy.Wording from the collection by index number.

Parameters:
i - Index of element to return
Returns:
The instance of com.ail.insurance.policy.Wording at the specified index

removeWording

public void removeWording(int i)
Remove the element specified from the list.

Parameters:
i - Index of element to remove

removeWording

public void removeWording(Wording wording)
Remove the specified instance of com.ail.insurance.policy.Wording from the list.

Parameters:
wording - Instance to be removed

addWording

public void addWording(Wording wording)
Add an instance of com.ail.insurance.policy.Wording to the list associated with this object.

Parameters:
wording - Instance to add to list

getExcluded

public YesNo getExcluded()
Getter returning the value of the excluded property. If a section is "excluded" (this property==Yes), then there will be no sum insured or premium calculated but a warranty will be printed on the proposal form e.g. earthquake excluded.

Returns:
Value of the excluded property

setExcluded

public void setExcluded(YesNo excluded)
Setter to update the value of the excluded property. If a section is "excluded" (this property==Yes), then there will be no sum insured or premium calculated but a warranty will be printed on the proposal form e.g. earthquake excluded.

Parameters:
excluded - New value for the excluded property

getExcludedAsString

public java.lang.String getExcludedAsString()
Get the value of the excluded property as a string (as opposed to an instance of YesNo).

Returns:
String representation of the excluded, or null if the property has not been set.

setExcludedAsString

public void setExcludedAsString(java.lang.String excluded)
                         throws java.lang.IndexOutOfBoundsException
Set the excluded property as a String. The String must represents a valid YesNo. i.e. it must be suitable for a call to YesNo.forName().

Parameters:
excluded - New value for property.
Throws:
java.lang.IndexOutOfBoundsException - If excluded is not a valid YesNo.

getIncluded

public YesNo getIncluded()
Getter returning the value of the included property. If a section is included (this property==Yes), then no sum insured is collected or premium calculated but that is an active cover for a claim and is not excluded. The fixed sum insured, if exists, is added into the aggregate limit.

Returns:
Value of the included property

setIncluded

public void setIncluded(YesNo included)
Setter to update the value of the included property. If a section is included (this property==Yes), then no sum insured is collected or premium calculated but that is an active cover for a claim and is not excluded. The fixed sum insured, if exists, is added into the aggregate limit.

Parameters:
included - New value for the included property

getIncludedAsString

public java.lang.String getIncludedAsString()
Get the value of the included property as a string (as opposed to an instance of YesNo).

Returns:
String representation of the included, or null if the property has not been set.

setIncludedAsString

public void setIncludedAsString(java.lang.String included)
                         throws java.lang.IndexOutOfBoundsException
Set the included property as a String. The String must represents a valid YesNo. i.e. it must be suitable for a call to YesNo.forName().

Parameters:
included - New value for property.
Throws:
java.lang.IndexOutOfBoundsException - If included is not a valid YesNo.

getExcessId

public java.util.List<java.lang.String> getExcessId()
Get the collection of instances of String associated with this object.

Returns:
excessId A collection of instances of Excess
See Also:
setExcessId(java.util.List)

setExcessId

public void setExcessId(java.util.List<java.lang.String> excessId)
Set the collection of instances of String associated with this object.

Parameters:
excessId - A collection of instances of Excess
See Also:
getExcessId()

getExcessIdCount

public int getExcessIdCount()
Get a count of the number of String instances associated with this object

Returns:
Number of instances

getExcessId

public java.lang.String getExcessId(int i)
Fetch a spacific String from the collection by index number.

Parameters:
i - Index of element to return
Returns:
The instance of String at the specified index

removeExcessId

public void removeExcessId(int i)
Remove the element specified from the list.

Parameters:
i - Index of element to remove

removeExcessId

public void removeExcessId(java.lang.String excessId)
Remove the specified instance of String from the list.

Parameters:
excessId - Instance to be removed

addExcessId

public void addExcessId(java.lang.String excessId)
Add an instance of String to the list associated with this object.

Parameters:
excessId - Instance to add to list