01: /*
02: * Copyright 2006-2007 The Kuali Foundation.
03: *
04: * Licensed under the Educational Community License, Version 1.0 (the "License");
05: * you may not use this file except in compliance with the License.
06: * You may obtain a copy of the License at
07: *
08: * http://www.opensource.org/licenses/ecl1.php
09: *
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.module.financial.service;
17:
18: import java.sql.Timestamp;
19:
20: import org.kuali.core.util.KualiDecimal;
21:
22: /**
23: *
24: * This service interface defines the methods that a DisbursementVoucherTravelService implementation must provide.
25: *
26: * Performs calculations of travel per diem and mileage amounts.
27: *
28: */
29: public interface DisbursementVoucherTravelService {
30:
31: /**
32: *
33: * Calculates the per diem travel amount.
34: *
35: * @param startDateTime The start date and time of the period of time we will calculate the per diem amount for.
36: * @param endDateTime The end date and time of the period of time we will calculate the per diem amount for.
37: * @param perDiemRate The per diem rate used to calculate the total amount.
38: * @return The per diem amount for the time period passed in and based on the rate given.
39: */
40: public KualiDecimal calculatePerDiemAmount(Timestamp startDateTime,
41: Timestamp endDateTime, KualiDecimal perDiemRate);
42:
43: /**
44: *
45: * Calculates the mileage travel amount.
46: *
47: * @param totalMileage The total distance traveled.
48: * @param travelStartDate The start date of the travel.
49: * @return The mileage amount for the mileage given.
50: */
51: public KualiDecimal calculateMileageAmount(Integer totalMileage,
52: Timestamp travelStartDate);
53:
54: }
|