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.service; 17 18 import org.kuali.ole.sys.businessobject.UniversityDate; 19 20 /** 21 * 22 * This service interface defines methods that a UniversityDateService implementation must provide. 23 * 24 */ 25 public interface UniversityDateService { 26 27 /** 28 * Returns the current university date. 29 * 30 * @return The current university date. 31 */ 32 public UniversityDate getCurrentUniversityDate(); 33 34 /** 35 * Given a Date, returns the fiscal year corresponding to that date. 36 * 37 * @return Fiscal year associated with the given Date. 38 * @throws IllegalArgumentException if the given Date is null. 39 */ 40 public Integer getFiscalYear(java.util.Date date); 41 42 /** 43 * Returns the first date of the specified Fiscal Year. 44 * 45 * @param fiscalYear The fiscal year to retrieve the first date for. 46 * @return java.util.Date The first date of the fiscal year given. 47 */ 48 public java.util.Date getFirstDateOfFiscalYear(Integer fiscalYear); 49 50 /** 51 * Returns the last date of the specified Fiscal Year. 52 * 53 * @param fiscalYear The fiscal year to retrieve the last date for. 54 * @return java.util.Date The last date of the fiscal year given. 55 */ 56 public java.util.Date getLastDateOfFiscalYear(Integer fiscalYear); 57 58 /** 59 * Returns the current fiscal year. 60 * 61 * @return The current fiscal year 62 */ 63 public Integer getCurrentFiscalYear(); 64 65 }