1 /* 2 * Copyright 2010 The Kuali Foundation. 3 * 4 * Licensed under the Educational Community License, Version 1.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.opensource.org/licenses/ecl1.php 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 package org.kuali.ole.fp.document.service; 17 18 import org.kuali.ole.sys.businessobject.AccountingLine; 19 import org.kuali.ole.sys.businessobject.GeneralLedgerPendingEntry; 20 import org.kuali.ole.sys.businessobject.GeneralLedgerPendingEntrySourceDetail; 21 import org.kuali.rice.krad.document.TransactionalDocument; 22 23 /** 24 * Methods needed to update pending entries on FP year end documents 25 */ 26 public interface YearEndPendingEntryService { 27 /** 28 * @return the previous fiscal year used with all GLPE 29 */ 30 public abstract Integer getPreviousFiscalYear(); 31 32 /** 33 * @return the accounting period code used with all GLPE 34 */ 35 public abstract String getFinalAccountingPeriod(); 36 37 /** 38 * populates a <code>GeneralLedgerPendingEntry</code> populated with common year end document data into the explicit general 39 * ledger pending entry. currently is the following: 40 * <ol> 41 * <li>fiscal period code = final accounting period code 42 * <li>fiscal year= previous fiscal year 43 * </ol> 44 * 45 * @param transactionalDocument 46 * @param accountingLine 47 * @param explicitEntry 48 */ 49 public abstract void customizeExplicitGeneralLedgerPendingEntry(TransactionalDocument transactionalDocument, AccountingLine accountingLine, GeneralLedgerPendingEntry explicitEntry); 50 51 /** 52 * Populates an offset GeneralLedgerPendingEntry such that it uses the Offset Definition from the previous year 53 * @param transactionalDocument the transactional document with general ledger pending entries on it 54 * @param accountingLine the general ledger pending entry source which generated the explicit and offset entry 55 * @param explicitEntry the explicit entry requiring this offset entry 56 * @param offsetEntry the offset entry which is being customized 57 * @return whether the offset could be successfully customized for year end or not 58 */ 59 public abstract boolean customizeOffsetGeneralLedgerPendingEntry(TransactionalDocument transactionalDocument, GeneralLedgerPendingEntrySourceDetail accountingLine, GeneralLedgerPendingEntry explicitEntry, GeneralLedgerPendingEntry offsetEntry); 60 61 62 63 64 }