001    /*
002     * Copyright 2011 The Kuali Foundation.
003     * 
004     * Licensed under the Educational Community License, Version 2.0 (the "License");
005     * you may not use this file except in compliance with the License.
006     * You may obtain a copy of the License at
007     * 
008     * http://www.opensource.org/licenses/ecl2.php
009     * 
010     * Unless required by applicable law or agreed to in writing, software
011     * distributed under the License is distributed on an "AS IS" BASIS,
012     * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013     * See the License for the specific language governing permissions and
014     * limitations under the License.
015     */
016    package org.kuali.kfs.module.ld.document.service;
017    
018    import org.kuali.kfs.module.ld.businessobject.ExpenseTransferAccountingLine;
019    import org.kuali.kfs.module.ld.businessobject.LaborLedgerPendingEntry;
020    import org.kuali.kfs.module.ld.document.LaborLedgerPostingDocument;
021    import org.kuali.kfs.sys.businessobject.GeneralLedgerPendingEntrySequenceHelper;
022    import org.kuali.rice.kns.util.KualiDecimal;
023    
024    /**
025     * This class provides a set of facilities that can convert the accounting document and its accounting lines into labor pending
026     * entries
027     */
028    public interface LaborPendingEntryConverterService {
029        /**
030         * convert the given document and accounting line into the expense pending entries
031         * 
032         * @param document the given accounting document
033         * @param accountingLine the given accounting line
034         * @param sequenceHelper the given sequence helper
035         * @return a set of expense pending entries
036         */
037        public abstract LaborLedgerPendingEntry getExpensePendingEntry(LaborLedgerPostingDocument document, ExpenseTransferAccountingLine accountingLine, GeneralLedgerPendingEntrySequenceHelper sequenceHelper);
038        
039        /**
040         * convert the given document and accounting line into the expense pending entries for effort reporting
041         * 
042         * @param document the given accounting document
043         * @param accountingLine the given accounting line
044         * @param sequenceHelper the given sequence helper
045         * @return a set of expense pending entries for effort reporting
046         */
047        public abstract LaborLedgerPendingEntry getExpenseA21PendingEntry(LaborLedgerPostingDocument document, ExpenseTransferAccountingLine accountingLine, GeneralLedgerPendingEntrySequenceHelper sequenceHelper);
048        
049        /**
050         * convert the given document and accounting line into the expense reversal pending entries for effort reporting
051         * 
052         * @param document the given accounting document
053         * @param accountingLine the given accounting line
054         * @param sequenceHelper the given sequence helper
055         * @return a set of expense reversal pending entries for effort reporting
056         */
057        public abstract LaborLedgerPendingEntry getExpenseA21ReversalPendingEntry(LaborLedgerPostingDocument document, ExpenseTransferAccountingLine accountingLine, GeneralLedgerPendingEntrySequenceHelper sequenceHelper);
058        
059        /**
060         * convert the given document and accounting line into the benefit pending entries
061         * 
062         * @param document the given accounting document
063         * @param accountingLine the given accounting line
064         * @param sequenceHelper the given sequence helper
065         * @param benefitAmount the given benefit amount
066         * @param fringeBenefitObjectCode the given fringe benefit object code
067         * @return a set of benefit pending entries
068         */
069        public abstract LaborLedgerPendingEntry getBenefitPendingEntry(LaborLedgerPostingDocument document, ExpenseTransferAccountingLine accountingLine, GeneralLedgerPendingEntrySequenceHelper sequenceHelper, KualiDecimal benefitAmount, String fringeBenefitObjectCode);
070        
071        /**
072         * convert the given document and accounting line into the benefit pending entry for effort reporting
073         * 
074         * @param document the given accounting document
075         * @param accountingLine the given accounting line
076         * @param sequenceHelper the given sequence helper
077         * @param benefitAmount the given benefit amount
078         * @param fringeBenefitObjectCode the given fringe benefit object code
079         * @return a set of benefit pending entries for effort reporting
080         */
081        public abstract LaborLedgerPendingEntry getBenefitA21PendingEntry(LaborLedgerPostingDocument document, ExpenseTransferAccountingLine accountingLine, GeneralLedgerPendingEntrySequenceHelper sequenceHelper, KualiDecimal benefitAmount, String fringeBenefitObjectCode);
082        
083        /**
084         * convert the given document and accounting line into the benefit reversal pending entries for effort reporting
085         * 
086         * @param document the given accounting document
087         * @param accountingLine the given accounting line
088         * @param sequenceHelper the given sequence helper
089         * @param benefitAmount the given benefit amount
090         * @param fringeBenefitObjectCode the given fringe benefit object code
091         * @return a set of benefit reversal pending entries for effort reporting
092         */
093        public abstract LaborLedgerPendingEntry getBenefitA21ReversalPendingEntry(LaborLedgerPostingDocument document, ExpenseTransferAccountingLine accountingLine, GeneralLedgerPendingEntrySequenceHelper sequenceHelper, KualiDecimal benefitAmount, String fringeBenefitObjectCode);
094        
095        /**
096         * convert the given document into benefit clearing pending entries with the given account, chart, amount and benefit type
097         * 
098         * @param document the given accounting document
099         * @param sequenceHelper the given sequence helper
100         * @param accountNumber the given account number that the benefit clearing amount can be charged
101         * @param chartOfAccountsCode the given chart of accounts code that the benefit clearing amount can be charged
102         * @param benefitTypeCode the given benefit type code
103         * @param clearingAmount the benefit clearing amount
104         * @return a set of benefit clearing pending entries
105         */
106        public abstract LaborLedgerPendingEntry getBenefitClearingPendingEntry(LaborLedgerPostingDocument document, GeneralLedgerPendingEntrySequenceHelper sequenceHelper, String accountNumber, String chartOfAccountsCode, String benefitTypeCode, KualiDecimal clearingAmount);
107        
108        /**
109         * construct a LaborLedgerPendingEntry object based on the information in the given document and accounting line. The object can
110         * be used as a template
111         * 
112         * @param document the given document
113         * @param accountingLine the given accounting line
114         * @return a LaborLedgerPendingEntry object based on the information in the given document and accounting line
115         */
116        public abstract LaborLedgerPendingEntry getDefaultPendingEntry(LaborLedgerPostingDocument document, ExpenseTransferAccountingLine accountingLine);
117        
118        /**
119         * construct a LaborLedgerPendingEntry object based on the information in the given document. The object can be used as a
120         * template
121         * 
122         * @param document the given document
123         * @return a LaborLedgerPendingEntry object based on the information in the given document
124         */
125        public abstract LaborLedgerPendingEntry getDefaultPendingEntry(LaborLedgerPostingDocument document);
126        
127        /**
128         * construct a LaborLedgerPendingEntry object based on the information in the given document and accounting line. The object can
129         * be used as a template
130         * 
131         * @param document the given document
132         * @param accountingLine the given accounting line
133         * @return a LaborLedgerPendingEntry object based on the information in the given document and accounting line
134         */
135        public abstract LaborLedgerPendingEntry getSimpleDefaultPendingEntry();
136    
137    
138    
139     
140    
141    
142    
143    
144    }