Refactored FiscalYear/-Month/-Week/-Day-Calculators into single
[fiscal-year.java.git] / src / main / java / com / github / sebhoss / time / FiscalDateCalculator.java
blob9daed325b6e7818a31af1a42c1d104e217c9e511
1 /*
2 * This program is free software. It comes without any warranty, to
3 * the extent permitted by applicable law. You can redistribute it
4 * and/or modify it under the terms of the Do What The Fuck You Want
5 * To Public License, Version 2, as published by Sam Hocevar. See
6 * http://www.wtfpl.net/ for more details.
7 */
8 package com.github.sebhoss.time;
10 import org.joda.time.LocalDate;
12 /**
13 * TODO: Write documentation
15 public interface FiscalDateCalculator {
17 /**
18 * @param calendarDate
19 * The calendar date to transform.
20 * @return The fiscal year of the given calendar date.
22 int calculateFiscalYear(LocalDate calendarDate);
24 /**
25 * @param calendarDate
26 * The calendar date to transform.
27 * @return The fiscal month of the given calendar date.
29 int calculateFiscalMonth(LocalDate calendarDate);
31 /**
32 * @param calendarDate
33 * The calendar date to transform.
34 * @return The fiscal week-of-year of the given calendar date.
36 int calculateFiscalWeekOfYear(LocalDate calendarDate);
38 /**
39 * @param calendarDate
40 * The calendar date to transform.
41 * @return The fiscal day-of-year of the given calendar date.
43 int calculateFiscalDayOfYear(LocalDate calendarDate);