org.kuali.kfs.module.ld.document.validation.impl
Class LaborExpenseTransferDuplicateSourceAccountingLineValidation

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.module.ld.document.validation.impl.LaborExpenseTransferDuplicateSourceAccountingLineValidation
All Implemented Interfaces:
Validation

public class LaborExpenseTransferDuplicateSourceAccountingLineValidation
extends GenericValidation

determine whether the given accounting line has already been in the given document


Constructor Summary
LaborExpenseTransferDuplicateSourceAccountingLineValidation()
           
 
Method Summary
protected  List<String> defaultKeyOfExpenseTransferAccountingLine()
          Gets the default key of ExpenseTransferAccountingLine
 AccountingDocument getAccountingDocumentForValidation()
          Gets the accountingLineForValidation attribute.
 AccountingLine getAccountingLineForValidation()
          Gets the accountingLineForValidation attribute.
protected  boolean isDuplicateSourceAccountingLine(AccountingDocument accountingDocument, AccountingLine accountingLine)
          determine whether the given accounting line has already been in the given document
 void setAccountingDocumentForValidation(AccountingDocument accountingDocumentForValidation)
          Sets the accountingDocumentForValidation attribute value.
 void setAccountingLineForValidation(AccountingLine accountingLineForValidation)
          Sets the accountingLineForValidation attribute value.
 boolean validate(AttributedDocumentEvent event)
          Validates that an accounting line does not duplicate in the source lines 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
 

Constructor Detail

LaborExpenseTransferDuplicateSourceAccountingLineValidation

public LaborExpenseTransferDuplicateSourceAccountingLineValidation()
Method Detail

validate

public boolean validate(AttributedDocumentEvent event)
Validates that an accounting line does not duplicate in the source lines Expects an accounting line as the first a parameter

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

isDuplicateSourceAccountingLine

protected boolean isDuplicateSourceAccountingLine(AccountingDocument accountingDocument,
                                                  AccountingLine accountingLine)
determine whether the given accounting line has already been in the given document

Parameters:
accountingDocument - the given document
accountingLine - the given accounting line
Returns:
true if the given accounting line has already been in the given document; otherwise, false

defaultKeyOfExpenseTransferAccountingLine

protected List<String> defaultKeyOfExpenseTransferAccountingLine()
Gets the default key of ExpenseTransferAccountingLine

Returns:
the default key of ExpenseTransferAccountingLine

getAccountingDocumentForValidation

public AccountingDocument getAccountingDocumentForValidation()
Gets the accountingLineForValidation attribute.

Returns:
Returns the accountingLineForValidation.

setAccountingDocumentForValidation

public void setAccountingDocumentForValidation(AccountingDocument accountingDocumentForValidation)
Sets the accountingDocumentForValidation attribute value.

Parameters:
accountingDocumentForValidation - The accountingDocumentForValidation to set.

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.