org.kuali.kfs.fp.document.validation.impl
Class ProcurementCardFixErrorPathValidation

java.lang.Object
  extended by org.kuali.kfs.sys.document.validation.ParameterizedValidation
      extended by org.kuali.kfs.sys.document.validation.GenericValidation
          extended by org.kuali.kfs.fp.document.validation.impl.ProcurementCardFixErrorPathValidation
All Implemented Interfaces:
Validation

public class ProcurementCardFixErrorPathValidation
extends GenericValidation

Validates that an accounting line does not have a capital object object code


Field Summary
protected static org.apache.log4j.Logger LOG
           
 
Constructor Summary
ProcurementCardFixErrorPathValidation()
           
 
Method Summary
 AccountingLine getAccountingLineForValidation()
          Gets the accountingLineForValidation attribute.
protected  boolean isTransactionBalanceValid(ProcurementCardTransactionDetail pcTransactionDetail)
          This method validates the balance of the transaction given.
 void setAccountingLineForValidation(AccountingLine accountingLineForValidation)
          Sets the accountingLineForValidation attribute value.
 boolean validate(AttributedDocumentEvent event)
          Validates that an accounting line does not have a capital object object code Expects an accounting line as the first a parameter
 
Methods inherited from class org.kuali.kfs.sys.document.validation.GenericValidation
setQuitOnFail, shouldQuitOnFail, stageValidation
 
Methods inherited from class org.kuali.kfs.sys.document.validation.ParameterizedValidation
getParameterProperties, populateParameterFromEvent, populateParametersFromEvent, setParameterProperties
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG

protected static org.apache.log4j.Logger LOG
Constructor Detail

ProcurementCardFixErrorPathValidation

public ProcurementCardFixErrorPathValidation()
Method Detail

validate

public boolean validate(AttributedDocumentEvent event)
Validates that an accounting line does not have a capital object object code Expects an accounting line as the first a parameter

Returns:
true if validation should continue, false otherwise
See Also:
org.kuali.kfs.sys.document.validation.Validation#validate(java.lang.Object[])

isTransactionBalanceValid

protected boolean isTransactionBalanceValid(ProcurementCardTransactionDetail pcTransactionDetail)
This method validates the balance of the transaction given. A procurement card transaction is in balance if the total amount of the transaction equals the total of the target accounting lines corresponding to the transaction.

Parameters:
pcTransaction - The transaction detail used to retrieve the procurement card transaction and target accounting lines used to check for in balance.
Returns:
True if the amounts are equal and the transaction is in balance, false otherwise.

getAccountingLineForValidation

public AccountingLine getAccountingLineForValidation()
Gets the accountingLineForValidation attribute.

Returns:
Returns the accountingLineForValidation.

setAccountingLineForValidation

public void setAccountingLineForValidation(AccountingLine accountingLineForValidation)
Sets the accountingLineForValidation attribute value.

Parameters:
accountingLineForValidation - The accountingLineForValidation to set.


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