View Javadoc
1   /*
2    * Copyright 2007 The Kuali Foundation
3    * 
4    * Licensed under the Educational Community License, Version 2.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/ecl2.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.sys.batch.dataaccess;
17  
18  import java.util.Collection;
19  import java.util.Map;
20  import java.util.Set;
21  
22  import org.kuali.ole.sys.businessobject.FiscalYearBasedBusinessObject;
23  
24  /**
25   * Provides data access methods for the fiscal year maker process
26   */
27  public interface FiscalYearMakersDao {
28  
29      /**
30       * Clears out records for the new year and object being copied
31       * 
32       * @param baseYear fiscal year that we are copying
33       * @param objectFiscalYearMaker FiscalYearMaker implementation for the object we are copying
34       */
35      public void deleteNewYearRows(Integer baseYear, FiscalYearMaker objectFiscalYearMaker);
36  
37      /**
38       * Populates records for the new year and object
39       * 
40       * @param baseYear fiscal year that we are copying
41       * @param objectFiscalYearMaker FiscalYearMaker implementation for the object we are copying
42       * @param replaceMode indicates whether records found for the new year should be replaced or left alone
43       * @param parentKeysWritten Map that contains class as key and Set of of primary key strings representing records written
44       * @param isParentClass indicates whether the class being copied is a parent to another FYM class that will be copied
45       * @return Collection of error messages encountered while attempting to copy a record
46       */
47      public Collection<String> createNewYearRows(Integer baseYear, FiscalYearMaker objectFiscalYearMaker, boolean replaceMode, Map<Class<? extends FiscalYearBasedBusinessObject>, Set<String>> parentKeysWritten, boolean isParentClass) throws Exception;
48  
49  }