org.kuali.kfs.coa.service
Interface AccountingPeriodService

All Known Implementing Classes:
AccountingPeriodServiceImpl

public interface AccountingPeriodService

This service interface defines methods necessary for retrieving fully populated AccountingPeriod business objects from the database that are necessary for transaction processing in the application.


Method Summary
 int compareAccountingPeriodsByDate(AccountingPeriod a, AccountingPeriod b)
          This method compares two accounting periods, hopefully by comparing their closing dates.
 Collection getAllAccountingPeriods()
          This method retrieves all valid accounting periods in the system.
 AccountingPeriod getByDate(Date date)
          This method takes a date and returns the corresponding period
 AccountingPeriod getByPeriod(String periodCode, Integer fiscalYear)
          This method retrieves an individual AccountingPeriod based on the period and fiscal year
 AccountingPeriod getByStringDate(String dateString)
          This method allows for AccountingPeriod retrieval via String date.
 Collection getOpenAccountingPeriods()
          This method retrieves a list of all open accounting periods in the system.
 

Method Detail

getAllAccountingPeriods

Collection getAllAccountingPeriods()
This method retrieves all valid accounting periods in the system.

Returns:
A list of accounting periods in Kuali.

getOpenAccountingPeriods

Collection getOpenAccountingPeriods()
This method retrieves a list of all open accounting periods in the system.

Returns:

getByPeriod

AccountingPeriod getByPeriod(String periodCode,
                             Integer fiscalYear)
This method retrieves an individual AccountingPeriod based on the period and fiscal year

Parameters:
periodCode -
fiscalYear -
Returns:
an accounting period

getByStringDate

AccountingPeriod getByStringDate(String dateString)
This method allows for AccountingPeriod retrieval via String date.

Parameters:
String -

getByDate

AccountingPeriod getByDate(Date date)
This method takes a date and returns the corresponding period

Parameters:
date -
Returns:
period that matches the date

compareAccountingPeriodsByDate

int compareAccountingPeriodsByDate(AccountingPeriod a,
                                   AccountingPeriod b)
This method compares two accounting periods, hopefully by comparing their closing dates. If a is earlier than b, it should return a negative number; if a is later, it should return a positive number; and if the closing dates are equal, it should return a 0.

Parameters:
a - the first accounting period to compare
b - the second accounting period to compare
Returns:
an integer representing which is earlier or later, or if they occur simultaneously


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