org.kuali.kfs.gl.batch
Class CollectorBatch

java.lang.Object
  extended by org.kuali.rice.kns.bo.BusinessObjectBase
      extended by org.kuali.rice.kns.bo.PersistableBusinessObjectBase
          extended by org.kuali.kfs.gl.batch.CollectorBatch
All Implemented Interfaces:
Serializable, org.apache.ojb.broker.PersistenceBrokerAware, org.kuali.rice.kns.bo.BusinessObject, org.kuali.rice.kns.bo.PersistableBusinessObject

public class CollectorBatch
extends org.kuali.rice.kns.bo.PersistableBusinessObjectBase

Object representation of collector xml input.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.kuali.rice.kns.bo.PersistableBusinessObjectBase
extension, versionNumber
 
Constructor Summary
CollectorBatch()
          Constructs a CollectorBatch
 
Method Summary
 void addCollectorDetail(CollectorDetail collectorDetail)
          Adds a processed id billing to the list.
 void addOriginEntry(OriginEntryFull orginEntry)
          Adds a processed origin entry to the list.
 void clearTotalAmount()
          Sets the total amount field to null.
 CollectorHeader createCollectorHeaderForStorage()
          Creates a CollectorHeader from the batch to be used for storage
 CollectorHeader createCollectorHeaderWithPKValuesOnly()
          Creates an origin entry record with the PK values filled in only.
 String getBatchName()
          Gets the batchName attribute.
 Integer getBatchSequenceNumber()
          Gets the batchSequenceNumber attribute.
 String getCampusCode()
          Gets the campusCode attribute.
 String getChartOfAccountsCode()
          Gets the chartOfAccountsCode attribute.
protected static CollectorBatchHeaderFieldUtil getCollectorBatchHeaderFieldUtil()
           
protected static CollectorBatchTrailerRecordFieldUtil getCollectorBatchTrailerRecordFieldUtil()
           
 List<CollectorDetail> getCollectorDetails()
          Gets the idBillings attribute.
 String getDepartmentName()
          Gets the departmentName attribute.
 String getEmailAddress()
          Gets the emailAddress attribute.
 String getFirstEmptyField()
          Gets the firstEmptyField attribute
 String getMailingAddress()
          Gets the mailingAddress attribute.
 org.kuali.rice.kns.util.MessageMap getMessageMap()
           
 String getOrganizationCode()
          Gets the organizationCode attribute.
 List<OriginEntryFull> getOriginEntries()
          Gets the originEntries attribute.
 OriginEntryTotals getOriginEntryTotals()
           
 String getPersonUserID()
          Gets the personUserID attribute.
 String getPhoneNumber()
          Gets the phoneNumber attribute.
 String getRecordType()
          Gets the recordType attribute.
 String getSecondEmptyField()
          Gets the secondEmptyField attribute
 org.kuali.rice.kns.util.KualiDecimal getTotalAmount()
          Gets the totalAmount attribute.
 Integer getTotalRecords()
          Gets the totalRecords attribute.
 Date getTransmissionDate()
          Gets the transmissionDate attribute.
 String getUniversityFiscalYear()
          Gets the universityFiscalYear attribute.
protected  String getValue(String headerLine, int s, int e)
           
 boolean isHeaderlessBatch()
           
protected  Date parseSqlDate(String date)
           
 void prepareDataForStorage()
          Uppercases the appropriate fields in the batch, if told to do so by the data dictionary
 CollectorHeader retrieveDuplicateHeader()
          Attempts to retrieve a collector header already exists with the primary key values given for this object
 void setBatchName(String batchName)
          Sets the batchName attribute value.
 void setBatchSequenceNumber(Integer batchSequenceNumber)
          Sets the batchSequenceNumber attribute value.
 void setCampusCode(String campusCode)
          Sets the campusCode attribute value.
 void setChartOfAccountsCode(String chartOfAccountsCode)
          Sets the chartOfAccountsCode attribute value.
 void setCollectorDetails(List<CollectorDetail> idDetails)
          Sets the idBillings attribute value.
 void setDefaultsAndStore(CollectorReportData collectorReportData, String demergerOutputFileName, PrintStream originEntryOutputPs)
          Sets defaults for fields not populated from file.
 void setDepartmentName(String departmentName)
          Sets the departmentName attribute value.
 void setEmailAddress(String emailAddress)
          Sets the emailAddress attribute value.
 void setFirstEmptyField(String firstEmptyField)
          Sets the firstEmptyField attribute
 void setFromTextFileForCollectorBatch(String headerLine)
           
 void setFromTextFileForCollectorBatchTrailerRecord(String trailerLine, int lineNumber)
           
 void setHeaderlessBatch(boolean headerlessBatch)
           
 void setMailingAddress(String mailingAddress)
          Sets the mailingAddress attribute value.
 void setMessageMap(org.kuali.rice.kns.util.MessageMap messageMap)
           
 void setOrganizationCode(String organizationCode)
          Sets the organizationCode attribute value.
 void setOriginEntries(List<OriginEntryFull> batchOriginEntry)
          Sets the originEntries attribute value.
 void setOriginEntryTotals(OriginEntryTotals originEntryTotals)
           
 void setPersonUserID(String personUserID)
          Sets the personUserID attribute value.
 void setPhoneNumber(String phoneNumber)
          Sets the phoneNumber attribute value.
 void setRecordType(String recordType)
          Sets the recordType attribute.
 void setSecondEmptyField(String secondEmptyField)
          Sets the secondEmptyField attribute
 void setTotalAmount(org.kuali.rice.kns.util.KualiDecimal totalAmount)
          Sets the totalAmount attribute value.
 void setTotalAmount(String totalAmount)
          Sets the total amount from the String.
 void setTotalRecords(Integer totalRecords)
          Sets the totalRecords attribute value.
 void setTransmissionDate(Date transmissionDate)
          Sets the transmissionDate attribute value.
 void setUniversityFiscalYear(String universityFiscalYear)
          Sets the universityFiscalYear attribute
protected  LinkedHashMap toStringMapper()
           
 
Methods inherited from class org.kuali.rice.kns.bo.PersistableBusinessObjectBase
addNote, afterDelete, afterInsert, afterLookup, afterUpdate, beforeDelete, beforeInsert, beforeInsert, beforeUpdate, beforeUpdate, buildListOfDeletionAwareLists, deleteNote, getAttachmentService, getBoNote, getBoNotes, getExtension, getNoteService, getObjectId, getPersistenceService, getPersistenceStructureService, getVersionNumber, isAutoIncrementSet, isBoNotesSupport, isNewCollectionRecord, linkEditableUserFields, refresh, refreshNonUpdateableReferences, refreshReferenceObject, setAutoIncrementSet, setBoNotes, setExtension, setNewCollectionRecord, setObjectId, setVersionNumber, supportsBoNotes
 
Methods inherited from class org.kuali.rice.kns.bo.BusinessObjectBase
prepareForWorkflow, toString, toStringBuilder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.kuali.rice.kns.bo.BusinessObject
prepareForWorkflow
 

Constructor Detail

CollectorBatch

public CollectorBatch()
Constructs a CollectorBatch

Method Detail

getUniversityFiscalYear

public String getUniversityFiscalYear()
Gets the universityFiscalYear attribute.


setUniversityFiscalYear

public void setUniversityFiscalYear(String universityFiscalYear)
Sets the universityFiscalYear attribute


getBatchSequenceNumber

public Integer getBatchSequenceNumber()
Gets the batchSequenceNumber attribute.


setBatchSequenceNumber

public void setBatchSequenceNumber(Integer batchSequenceNumber)
Sets the batchSequenceNumber attribute value.


getChartOfAccountsCode

public String getChartOfAccountsCode()
Gets the chartOfAccountsCode attribute.


setChartOfAccountsCode

public void setChartOfAccountsCode(String chartOfAccountsCode)
Sets the chartOfAccountsCode attribute value.


getOrganizationCode

public String getOrganizationCode()
Gets the organizationCode attribute.


setOrganizationCode

public void setOrganizationCode(String organizationCode)
Sets the organizationCode attribute value.


getTotalAmount

public org.kuali.rice.kns.util.KualiDecimal getTotalAmount()
Gets the totalAmount attribute.


setTotalAmount

public void setTotalAmount(org.kuali.rice.kns.util.KualiDecimal totalAmount)
Sets the totalAmount attribute value.


setTotalAmount

public void setTotalAmount(String totalAmount)
Sets the total amount from the String.


clearTotalAmount

public void clearTotalAmount()
Sets the total amount field to null.


getSecondEmptyField

public String getSecondEmptyField()
Gets the secondEmptyField attribute


setSecondEmptyField

public void setSecondEmptyField(String secondEmptyField)
Sets the secondEmptyField attribute


getFirstEmptyField

public String getFirstEmptyField()
Gets the firstEmptyField attribute


setFirstEmptyField

public void setFirstEmptyField(String firstEmptyField)
Sets the firstEmptyField attribute


getTotalRecords

public Integer getTotalRecords()
Gets the totalRecords attribute.


setTotalRecords

public void setTotalRecords(Integer totalRecords)
Sets the totalRecords attribute value.


getTransmissionDate

public Date getTransmissionDate()
Gets the transmissionDate attribute.


setTransmissionDate

public void setTransmissionDate(Date transmissionDate)
Sets the transmissionDate attribute value.


getRecordType

public String getRecordType()
Gets the recordType attribute.


setRecordType

public void setRecordType(String recordType)
Sets the recordType attribute.


getEmailAddress

public String getEmailAddress()
Gets the emailAddress attribute.


setEmailAddress

public void setEmailAddress(String emailAddress)
Sets the emailAddress attribute value.


getPersonUserID

public String getPersonUserID()
Gets the personUserID attribute.


setPersonUserID

public void setPersonUserID(String personUserID)
Sets the personUserID attribute value.


getCollectorDetails

public List<CollectorDetail> getCollectorDetails()
Gets the idBillings attribute.


setCollectorDetails

public void setCollectorDetails(List<CollectorDetail> idDetails)
Sets the idBillings attribute value.


getOriginEntries

public List<OriginEntryFull> getOriginEntries()
Gets the originEntries attribute.


setOriginEntries

public void setOriginEntries(List<OriginEntryFull> batchOriginEntry)
Sets the originEntries attribute value.


addOriginEntry

public void addOriginEntry(OriginEntryFull orginEntry)
Adds a processed origin entry to the list.


addCollectorDetail

public void addCollectorDetail(CollectorDetail collectorDetail)
Adds a processed id billing to the list.


retrieveDuplicateHeader

public CollectorHeader retrieveDuplicateHeader()
Attempts to retrieve a collector header already exists with the primary key values given for this object

Returns:
the CollectorHeader found in the database

setDefaultsAndStore

public void setDefaultsAndStore(CollectorReportData collectorReportData,
                                String demergerOutputFileName,
                                PrintStream originEntryOutputPs)
Sets defaults for fields not populated from file. Store an origin entry group, all gl entries and id billing entries from the processed file. Also write the header for the duplicate file check.

Parameters:
originEntryGroup - the group into which to store the origin entries
collectorReportData - report data

prepareDataForStorage

public void prepareDataForStorage()
Uppercases the appropriate fields in the batch, if told to do so by the data dictionary


createCollectorHeaderForStorage

public CollectorHeader createCollectorHeaderForStorage()
Creates a CollectorHeader from the batch to be used for storage

Returns:
CollectorHeader

createCollectorHeaderWithPKValuesOnly

public CollectorHeader createCollectorHeaderWithPKValuesOnly()
Creates an origin entry record with the PK values filled in only. This is useful to check for duplicate headers.

Returns:
CollectorHeader with chart of accounts code, organization code, process transmission date, batch sequence number total record count, and process total amount from this CollectorBatch

getCampusCode

public String getCampusCode()
Gets the campusCode attribute.

Returns:
Returns the campusCode.

setCampusCode

public void setCampusCode(String campusCode)
Sets the campusCode attribute value.

Parameters:
campusCode - The campusCode to set.

getDepartmentName

public String getDepartmentName()
Gets the departmentName attribute.

Returns:
Returns the departmentName.

setDepartmentName

public void setDepartmentName(String departmentName)
Sets the departmentName attribute value.

Parameters:
departmentName - The departmentName to set.

getMailingAddress

public String getMailingAddress()
Gets the mailingAddress attribute.

Returns:
Returns the mailingAddress.

setMailingAddress

public void setMailingAddress(String mailingAddress)
Sets the mailingAddress attribute value.

Parameters:
mailingAddress - The mailingAddress to set.

getPhoneNumber

public String getPhoneNumber()
Gets the phoneNumber attribute.

Returns:
Returns the phoneNumber.

setPhoneNumber

public void setPhoneNumber(String phoneNumber)
Sets the phoneNumber attribute value.

Parameters:
phoneNumber - The phoneNumber to set.

getBatchName

public String getBatchName()
Gets the batchName attribute.

Returns:
Returns the batchName.

setBatchName

public void setBatchName(String batchName)
Sets the batchName attribute value.

Parameters:
batchName - The batchName to set.

getMessageMap

public org.kuali.rice.kns.util.MessageMap getMessageMap()

setMessageMap

public void setMessageMap(org.kuali.rice.kns.util.MessageMap messageMap)

getOriginEntryTotals

public OriginEntryTotals getOriginEntryTotals()

setOriginEntryTotals

public void setOriginEntryTotals(OriginEntryTotals originEntryTotals)

isHeaderlessBatch

public boolean isHeaderlessBatch()

setHeaderlessBatch

public void setHeaderlessBatch(boolean headerlessBatch)

toStringMapper

protected LinkedHashMap toStringMapper()
Specified by:
toStringMapper in class org.kuali.rice.kns.bo.BusinessObjectBase

parseSqlDate

protected Date parseSqlDate(String date)
                     throws ParseException
Throws:
ParseException

getValue

protected String getValue(String headerLine,
                          int s,
                          int e)

getCollectorBatchHeaderFieldUtil

protected static CollectorBatchHeaderFieldUtil getCollectorBatchHeaderFieldUtil()
Returns:
the static instance of the CollectorBatchHeaderFieldUtil

setFromTextFileForCollectorBatch

public void setFromTextFileForCollectorBatch(String headerLine)

getCollectorBatchTrailerRecordFieldUtil

protected static CollectorBatchTrailerRecordFieldUtil getCollectorBatchTrailerRecordFieldUtil()
Returns:
the static instance of the CollectorBatchTrailerRecordFieldUtil

setFromTextFileForCollectorBatchTrailerRecord

public void setFromTextFileForCollectorBatchTrailerRecord(String trailerLine,
                                                          int lineNumber)


Copyright © 2005-2012 The Kuali Foundation. All Rights Reserved.