|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.dao.support.DaoSupport
org.springmodules.orm.ojb.support.PersistenceBrokerDaoSupport
org.kuali.rice.kns.dao.impl.PlatformAwareDaoBaseOjb
org.kuali.kfs.gl.dataaccess.impl.BalanceDaoOjb
public class BalanceDaoOjb
An OJB implementation of BalanceDao
Field Summary | |
---|---|
protected static String |
PARAMETER_PREFIX
|
Fields inherited from class org.springframework.dao.support.DaoSupport |
---|
logger |
Constructor Summary | |
---|---|
BalanceDaoOjb()
|
Method Summary | |
---|---|
protected List<String> |
buildAttributeList(boolean isExtended)
This method builds the atrribute list used by balance searching |
protected org.apache.ojb.broker.query.Criteria |
buildCriteriaFromMap(Map fieldValues,
Balance balance)
This method builds the query criteria based on the input field map |
protected List<String> |
buildGroupByList()
This method builds group by attribute list used by balance searching |
int |
countBalancesForFiscalYear(Integer year)
Returns the count of balances for a given fiscal year; this method is used for year end job reporting |
protected void |
criteriaBuilder(org.apache.ojb.broker.query.Criteria criteria,
String name,
Collection collection)
This method adds to the given criteria if the given collection is non-empty. |
protected void |
criteriaBuilderHelper(org.apache.ojb.broker.query.Criteria criteria,
String name,
Collection collection,
boolean negate)
This method provides the implementation for the conveniences methods criteriaBuilder & negatedCriteriaBuilder |
Iterator<Balance> |
findAccountBalances(Integer universityFiscalYear,
String chartOfAccountsCode,
String accountNumber)
Find all matching account balances. |
Iterator<Balance> |
findAccountBalances(Integer universityFiscalYear,
String chartOfAccountsCode,
String accountNumber,
String sfCode)
Find all matching account balances. |
Iterator<Balance> |
findBalance(Map fieldValues,
boolean isConsolidated)
Given a map of values, build a query out of those and find all the balances that qualify |
Iterator<Balance> |
findBalances(Account account,
Integer fiscalYear,
Collection includedObjectCodes,
Collection excludedObjectCodes,
Collection objectTypeCodes,
Collection balanceTypeCodes)
Build a query based on all the parameters, and return an Iterator of all Balances from the database that qualify |
Iterator<Balance> |
findBalancesForFiscalYear(Integer year)
Queries the database for all the balances for a given fiscal year |
Iterator<Balance> |
findCashBalance(Map fieldValues,
boolean isConsolidated)
Using the given fieldValues as keys, return all cash balance records |
Integer |
findCountGreaterOrEqualThan(Integer year)
|
Iterator<Balance> |
findCumulativeBalancesToForwardForFiscalYear(Integer year)
Returns all of the balances that should be procesed by the BalanceForward year end job under the active rule |
Iterator<Balance> |
findGeneralBalancesToForwardForFiscalYear(Integer year)
Returns all of the balances that should be procesed by the BalanceForward year end job under the general rule |
Iterator<Balance> |
findNominalActivityBalancesForFiscalYear(Integer year)
Finds all of the balances for the fiscal year that should be processed by nominal activity closing |
Iterator<Balance> |
findOrganizationReversionBalancesForFiscalYear(Integer year,
boolean endOfYear)
Returns a list of balances to return for the Organization Reversion year end job to process |
Balance |
getBalanceByPrimaryId(Integer universityFiscalYear,
String chartOfAccountsCode,
String accountNumber)
Whoa! This method is seemingly not called in the code base right now, and you know what? You shouldn't call it First of all, we're not even sending in all the primary keys for Balance, and second of all, we're returning a SufficientFundsBalance, which we cast to a Balance, which is *always* going to throw a ClassCastException. |
Balance |
getBalanceByTransaction(Transaction t)
Using values from the transaction as keys, lookup the balance the transaction would affect were it posted |
protected org.apache.ojb.broker.query.ReportQueryByCriteria |
getBalanceCountQuery(Map fieldValues)
build the query for balance search |
protected org.apache.ojb.broker.query.Query |
getBalanceQuery(Map fieldValues,
boolean isConsolidated)
build the query for balance search |
protected org.apache.ojb.broker.query.ReportQueryByCriteria |
getCashBalanceCountQuery(Map fieldValues)
Builds a query for cash balances, based on the given field values |
protected org.apache.ojb.broker.query.Query |
getCashBalanceQuery(Map fieldValues,
boolean isConsolidated)
build the query for cash balance search |
Iterator |
getConsolidatedBalanceRecordCount(Map fieldValues)
Given a Map of keys to use as a query, if we performed that query as a consolidated query... |
Iterator |
getConsolidatedCashBalanceRecordCount(Map fieldValues)
Given a map of keys, return all of the report data about qualifying cash balances |
Balance |
getCurrentBudgetForObjectCode(Integer universityFiscalYear,
String chartOfAccountsCode,
String accountNumber,
String objectCode)
Since SubAccountNumber, SubObjectCode, and ObjectType are all part of the primary key of Balance, you're guaranteed to get one of those records when you call this method. |
Integer |
getDetailedCashBalanceRecordCount(Map fieldValues)
Get the number of detailed cash balance records that would be returned, were we to do a query based on the given fieldValues |
Iterator<Object[]> |
getGlSummary(int universityFiscalYear,
List<String> balanceTypeCodes)
Does a ReportQuery to summarize GL balance data |
protected void |
negatedCriteriaBuilder(org.apache.ojb.broker.query.Criteria criteria,
String name,
Collection collection)
Similar to criteriaBuilder, this adds a negative criterion (NOT EQUALS, NOT IN) |
void |
purgeYearByChart(String chartOfAccountsCode,
int year)
Purge the sufficient funds balance table by year/chart |
void |
save(Balance b)
Saves a balance |
void |
setBalanceTypService(BalanceTypeService balanceTypService)
|
void |
setOptionsService(OptionsService optionsService)
|
void |
setParameterService(org.kuali.rice.kns.service.ParameterService parameterService)
|
Methods inherited from class org.kuali.rice.kns.dao.impl.PlatformAwareDaoBaseOjb |
---|
getDbPlatform, setDbPlatform |
Methods inherited from class org.springmodules.orm.ojb.support.PersistenceBrokerDaoSupport |
---|
checkDaoConfig, convertOjbAccessException, createPersistenceBrokerTemplate, getJcdAlias, getPersistenceBroker, getPersistenceBrokerTemplate, releasePersistenceBroker, setJcdAlias, setPersistenceBrokerTemplate |
Methods inherited from class org.springframework.dao.support.DaoSupport |
---|
afterPropertiesSet, initDao |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final String PARAMETER_PREFIX
Constructor Detail |
---|
public BalanceDaoOjb()
Method Detail |
---|
public Iterator<Object[]> getGlSummary(int universityFiscalYear, List<String> balanceTypeCodes)
getGlSummary
in interface BalanceDao
universityFiscalYear
- the fiscal year of balances to search forbalanceTypeCodes
- a list of balance type codes of balances to search for
BalanceDao.getGlSummary(int, java.util.List)
public Iterator<Balance> findBalancesForFiscalYear(Integer year)
findBalancesForFiscalYear
in interface BalanceDao
year
- the university fiscal year of balances to return
BalanceDao.findBalancesForFiscalYear(java.lang.Integer)
public void save(Balance b)
save
in interface BalanceDao
b
- a balance to saveBalanceDao.save(org.kuali.kfs.gl.businessobject.Balance)
public Balance getBalanceByTransaction(Transaction t)
getBalanceByTransaction
in interface BalanceDao
t
- a transaction
BalanceDao.getBalanceByTransaction(org.kuali.kfs.gl.businessobject.Transaction)
protected void criteriaBuilder(org.apache.ojb.broker.query.Criteria criteria, String name, Collection collection)
criteria
- - the criteria that might have a criterion appendedname
- - name of the attributecollection
- - the collection to inspectprotected void negatedCriteriaBuilder(org.apache.ojb.broker.query.Criteria criteria, String name, Collection collection)
criteria
- - the criteria that might have a criterion appendedname
- - name of the attributecollection
- - the collection to inspectprotected void criteriaBuilderHelper(org.apache.ojb.broker.query.Criteria criteria, String name, Collection collection, boolean negate)
criteria
- - the criteria that might have a criterion appendedname
- - name of the attributecollection
- - the collection to inspectnegate
- - the criterion will be negated (NOT EQUALS, NOT IN) when this is truepublic Iterator<Balance> findBalances(Account account, Integer fiscalYear, Collection includedObjectCodes, Collection excludedObjectCodes, Collection objectTypeCodes, Collection balanceTypeCodes)
findBalances
in interface BalanceDao
account
- the account of balances to findfiscalYear
- the fiscal year of balances to findincludedObjectCodes
- a Collection of object codes found balances should have one ofexcludedObjectCodes
- a Collection of object codes found balances should not have one ofobjectTypeCodes
- a Collection of object type codes found balances should have one ofbalanceTypeCodes
- a Collection of balance type codes found balances should have one of
BalanceDao.findBalances(org.kuali.kfs.coa.businessobject.Account, java.lang.Integer, java.util.Collection, java.util.Collection, java.util.Collection, java.util.Collection)
public Iterator<Balance> findCashBalance(Map fieldValues, boolean isConsolidated)
findCashBalance
in interface BalanceDao
fieldValues
- the input fields and valuesisConsolidated
- consolidation option is applied or not
BalanceDao.findCashBalance(java.util.Map, boolean)
public Integer getDetailedCashBalanceRecordCount(Map fieldValues)
getDetailedCashBalanceRecordCount
in interface BalanceDao
fieldValues
- the input fields and valuesisConsolidated
- consolidation option is applied or not
org.kuali.kfs.gl.dataaccess.BalanceDao#getCashBalanceRecordCount(java.util.Map, boolean)
public Iterator getConsolidatedCashBalanceRecordCount(Map fieldValues)
getConsolidatedCashBalanceRecordCount
in interface BalanceDao
fieldValues
- the input fields and values
org.kuali.kfs.gl.dataaccess.BalanceDao#getCashBalanceRecordSize(java.util.Map, boolean)
public Iterator<Balance> findBalance(Map fieldValues, boolean isConsolidated)
findBalance
in interface BalanceDao
fieldValues
- a Map of fieldValues to use as keys in the queryisConsolidated
- should the results be consolidated?
BalanceDao.findBalance(java.util.Map, boolean)
public Iterator getConsolidatedBalanceRecordCount(Map fieldValues)
getConsolidatedBalanceRecordCount
in interface BalanceDao
fieldValues
- a Map of values to use as keys to build the query
BalanceDao.getConsolidatedBalanceRecordCount(java.util.Map)
protected org.apache.ojb.broker.query.ReportQueryByCriteria getCashBalanceCountQuery(Map fieldValues)
fieldValues
- a map of keys to use when building the query
protected org.apache.ojb.broker.query.Query getCashBalanceQuery(Map fieldValues, boolean isConsolidated)
fieldValues
- Map of keys to use for the queryisConsolidated
- should the results be consolidated?
protected org.apache.ojb.broker.query.Query getBalanceQuery(Map fieldValues, boolean isConsolidated)
fieldValues
- Map of keys to use for the queryisConsolidated
- should the results be consolidated?
protected org.apache.ojb.broker.query.ReportQueryByCriteria getBalanceCountQuery(Map fieldValues)
fieldValues
- Map of keys to use for the query
protected org.apache.ojb.broker.query.Criteria buildCriteriaFromMap(Map fieldValues, Balance balance)
fieldValues
- Map of keys to use for the querybalance
- this really usen't used in the method
protected List<String> buildAttributeList(boolean isExtended)
isExtended
- should we add the attributes to sum each of the monthly totals?
protected List<String> buildGroupByList()
public Balance getBalanceByPrimaryId(Integer universityFiscalYear, String chartOfAccountsCode, String accountNumber)
getBalanceByPrimaryId
in interface BalanceDao
universityFiscalYear
- the university fiscal year of the balance to findchartOfAccountsCode
- the chart of accounts code of the balance to findaccountNumber
- the account number of the balance to find
BalanceDao.getBalanceByPrimaryId(java.lang.Integer, java.lang.String, java.lang.String)
public Balance getCurrentBudgetForObjectCode(Integer universityFiscalYear, String chartOfAccountsCode, String accountNumber, String objectCode)
getCurrentBudgetForObjectCode
in interface BalanceDao
universityFiscalYear
- the fiscal year of the CB balance to returnchartOfAccountsCode
- the chart of the accounts code of the CB balanes to returnaccountNumber
- the account number of the CB balance to returnobjectCode
- the object code of the CB balance to return
BalanceDao.getCurrentBudgetForObjectCode(java.lang.Integer, java.lang.String, java.lang.String,
java.lang.String)
public Iterator<Balance> findAccountBalances(Integer universityFiscalYear, String chartOfAccountsCode, String accountNumber)
findAccountBalances
in interface BalanceDao
universityFiscalYear
- the university fiscal year of balances to returnchartOfAccountsCode
- the chart of accounts code of balances to returnaccountNumber
- the account number of balances to return
public Iterator<Balance> findAccountBalances(Integer universityFiscalYear, String chartOfAccountsCode, String accountNumber, String sfCode)
findAccountBalances
in interface BalanceDao
universityFiscalYear
- the university fiscal year of balances to returnchartOfAccountsCode
- the chart of accounts code of balances to returnaccountNumber
- the account number of balances to returnsfCode
- the sufficient funds code, used to sort on
public void purgeYearByChart(String chartOfAccountsCode, int year)
purgeYearByChart
in interface BalanceDao
chart
- the chart of balances to purgeyear
- the university fiscal year of balances to purgepublic int countBalancesForFiscalYear(Integer year)
countBalancesForFiscalYear
in interface BalanceDao
year
- the university fiscal year to count balances for
BalanceDao.countBalancesForFiscalYear(java.lang.Integer)
public Iterator<Balance> findNominalActivityBalancesForFiscalYear(Integer year)
findNominalActivityBalancesForFiscalYear
in interface BalanceDao
year
- the university fiscal year of balances to find
BalanceDao.findNominalActivityBalancesForFiscalYear(java.lang.Integer)
public Iterator<Balance> findGeneralBalancesToForwardForFiscalYear(Integer year)
findGeneralBalancesToForwardForFiscalYear
in interface BalanceDao
the
- university fiscal year to find balances for
BalanceDao.findCumulativeBalancesToForwardForFiscalYear(java.lang.Integer)
public Iterator<Balance> findCumulativeBalancesToForwardForFiscalYear(Integer year)
findCumulativeBalancesToForwardForFiscalYear
in interface BalanceDao
the
- university fiscal year to find balances for
BalanceDao.findGeneralBalancesToForwardForFiscalYear(java.lang.Integer)
public Iterator<Balance> findOrganizationReversionBalancesForFiscalYear(Integer year, boolean endOfYear)
findOrganizationReversionBalancesForFiscalYear
in interface BalanceDao
the
- university fiscal year to find balances forendOfYear
- if true, use currrent year accounts, otherwise use prior year accounts
BalanceDao.findOrganizationReversionBalancesForFiscalYear(java.lang.Integer, boolean)
public Integer findCountGreaterOrEqualThan(Integer year)
findCountGreaterOrEqualThan
in interface LedgerBalanceBalancingDao
year
- the given university fiscal year
org.kuali.kfs.gl.dataaccess.BalancingDao#findCountGreaterOrEqualThan(java.lang.Integer)
public void setOptionsService(OptionsService optionsService)
public void setParameterService(org.kuali.rice.kns.service.ParameterService parameterService)
public void setBalanceTypService(BalanceTypeService balanceTypService)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |