org.kuali.kfs.coa.dataaccess.impl
Class AccountDelegateDaoOjb

java.lang.Object
  extended by org.springframework.dao.support.DaoSupport
      extended by org.springmodules.orm.ojb.support.PersistenceBrokerDaoSupport
          extended by org.kuali.rice.kns.dao.impl.PlatformAwareDaoBaseOjb
              extended by org.kuali.kfs.coa.dataaccess.impl.AccountDelegateDaoOjb
All Implemented Interfaces:
AccountDelegateDao, org.kuali.rice.kns.dao.PlatformAwareDao, org.springframework.beans.factory.InitializingBean

public class AccountDelegateDaoOjb
extends org.kuali.rice.kns.dao.impl.PlatformAwareDaoBaseOjb
implements AccountDelegateDao

This class is the OJB implementation of the AccountDelegateDao.


Field Summary
 
Fields inherited from class org.springframework.dao.support.DaoSupport
logger
 
Constructor Summary
AccountDelegateDaoOjb()
           
 
Method Summary
 Iterator<AccountDelegate> getAccountDelegationsForPerson(String principalId, boolean primary)
          Retrieves all active account delegates which reference the given user
 org.kuali.rice.kns.service.DateTimeService getDateTimeService()
          Gets the dateTimeService attribute.
 String getLockingDocumentNumber(String lockingRepresentation, String documentNumber)
          Retrieves the Document Number of any AccountDelegate locking this record.
 boolean isPrincipalInAnyWayShapeOrFormPrimaryAccountDelegate(String principalId)
          Determines if the given principal is an active delegate for any non-closed account
 boolean isPrincipalInAnyWayShapeOrFormSecondaryAccountDelegate(String principalId)
          Determines if the given principal is an active delegate for any non-closed account
protected  boolean queryPrincipalIsAccountDelegate(String principalId, boolean primary)
          Determines if any non-closed accounts exist where the principal id is an account delegate
 void setDateTimeService(org.kuali.rice.kns.service.DateTimeService dateTimeService)
          Sets the dateTimeService attribute value.
 
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
 

Constructor Detail

AccountDelegateDaoOjb

public AccountDelegateDaoOjb()
Method Detail

getLockingDocumentNumber

public String getLockingDocumentNumber(String lockingRepresentation,
                                       String documentNumber)
Description copied from interface: AccountDelegateDao
Retrieves the Document Number of any AccountDelegate locking this record.

Specified by:
getLockingDocumentNumber in interface AccountDelegateDao
Parameters:
lockingRepresentation - String representation of the MaintanceLock to check against.
documentNumber - the document number being checked against.
Returns:
the document number of the Document locking this record.
See Also:
AccountDelegateDao.getLockingDocumentNumber(java.lang.String, java.lang.String)

getAccountDelegationsForPerson

public Iterator<AccountDelegate> getAccountDelegationsForPerson(String principalId,
                                                                boolean primary)
Description copied from interface: AccountDelegateDao
Retrieves all active account delegates which reference the given user

Specified by:
getAccountDelegationsForPerson in interface AccountDelegateDao
Parameters:
principalId - a principal ID of the person to find account delegations for
primary - whether the account delegates returned should be primary or not
Returns:
a Collection, presumably of AccountDelegates
See Also:
org.kuali.kfs.coa.dataaccess.AccountDelegateDao#getAccountDelegationsForPerson(java.lang.String)

isPrincipalInAnyWayShapeOrFormPrimaryAccountDelegate

public boolean isPrincipalInAnyWayShapeOrFormPrimaryAccountDelegate(String principalId)
Description copied from interface: AccountDelegateDao
Determines if the given principal is an active delegate for any non-closed account

Specified by:
isPrincipalInAnyWayShapeOrFormPrimaryAccountDelegate in interface AccountDelegateDao
Parameters:
principalId - the principal ID to check primary account delegations for
Returns:
true if the principal is a primary account delegate, false otherwise
See Also:
AccountDelegateDao.isPrincipalInAnyWayShapeOrFormPrimaryAccountDelegate(java.lang.String)

isPrincipalInAnyWayShapeOrFormSecondaryAccountDelegate

public boolean isPrincipalInAnyWayShapeOrFormSecondaryAccountDelegate(String principalId)
Description copied from interface: AccountDelegateDao
Determines if the given principal is an active delegate for any non-closed account

Specified by:
isPrincipalInAnyWayShapeOrFormSecondaryAccountDelegate in interface AccountDelegateDao
Parameters:
principalId - the principal ID to check secondary account delegations for
Returns:
true if the principal is a secondary account delegate, false otherwise
See Also:
AccountDelegateDao.isPrincipalInAnyWayShapeOrFormSecondaryAccountDelegate(java.lang.String)

queryPrincipalIsAccountDelegate

protected boolean queryPrincipalIsAccountDelegate(String principalId,
                                                  boolean primary)
Determines if any non-closed accounts exist where the principal id is an account delegate

Parameters:
principalId - the principal id to check
primary - whether to check primary delegations (if true) or secondary delegations (if false)
Returns:
true if the principal has an account delegation

getDateTimeService

public org.kuali.rice.kns.service.DateTimeService getDateTimeService()
Gets the dateTimeService attribute.

Returns:
Returns the dateTimeService.

setDateTimeService

public void setDateTimeService(org.kuali.rice.kns.service.DateTimeService dateTimeService)
Sets the dateTimeService attribute value.

Parameters:
dateTimeService - The dateTimeService to set.


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