Interface DateRange
- All Known Implementing Classes:
AbstractDateRange,SimpleDateRange
public interface DateRange
-
Method Summary
Modifier and TypeMethodDescriptionTrys to return the calculatedDateRangeResultfor the supplied dateRetunns the default description, e.g.getKey()Returns the identification key, e.g.Returns thePeriodto move the date, if anybooleanbooleanbooleanReturns if theDateRangeis settable from a date
Example:falsefor TODAYtruefor MONTHtruefor FREEmoveDateRange(LocalDate baseDate, int dif) Trys to return a movedDateRangeResult
-
Method Details
-
getKey
String getKey()Returns the identification key, e.g. DAY, MONTH, etc- Returns:
- identification key
-
getOptMovePeriod
Returns thePeriodto move the date, if any- Returns:
Periodto move the date
-
getDefaultDescription
String getDefaultDescription()Retunns the default description, e.g. "Day" or "Half year"- Returns:
- default description
-
calcFor
Trys to return the calculatedDateRangeResultfor the supplied date- Parameters:
date- date that is used for calculation- Returns:
- calculated
DateRangeResult
-
moveDateRange
Trys to return a movedDateRangeResult- Parameters:
baseDate- Date that is used as a basedif- Count of moves- Returns:
- moved
DateRangeResult
-
isMovable
boolean isMovable()- Returns:
- if the
DateRangeis movable
-
isCalcable
boolean isCalcable()- Returns:
- if the
DateRangeis calcable
-
isSettable
boolean isSettable()Returns if theDateRangeis settable from a date
Example:-
falsefor TODAY -
truefor MONTH -
truefor FREE
- Returns:
- if the
DateRangeis settable from a date
-
-