public static class IlvTimeIncrementPolicy.Month extends Object implements IlvTimeIncrementPolicy
IlvTimeIncrementPolicy.Month
implements a strategy for stepping through
discrete month increments.IlvTimeIncrementPolicy.Day, IlvTimeIncrementPolicy.HalfDay, IlvTimeIncrementPolicy.Hour, IlvTimeIncrementPolicy.Minute, IlvTimeIncrementPolicy.Month, IlvTimeIncrementPolicy.Second, IlvTimeIncrementPolicy.Week, IlvTimeIncrementPolicy.Year
Constructor and Description |
---|
Month()
Creates a new
IlvTimeIncrementPolicy.Month policy. |
Modifier and Type | Method and Description |
---|---|
void |
decrementTime(Calendar calendar)
Decrements the given
Calendar downwards by
monthStep months. |
void |
floorTime(Calendar calendar)
Truncates the given
Calendar downwards to the nearest
monthStep month boundary. |
int |
getMonthStep()
Returns the number of months in a step increment.
|
void |
incrementTime(Calendar calendar)
Increments the given
Calendar upwards by
monthStep months. |
void |
setMonthStep(int monthStep)
Sets the number of months in a step increment.
|
public int getMonthStep()
1
.setMonthStep(int)
public void setMonthStep(int monthStep)
monthStep
- The number of months in a step increment.getMonthStep()
public void floorTime(Calendar calendar)
Calendar
downwards to the nearest
monthStep month boundary.floorTime
in interface IlvTimeIncrementPolicy
calendar
- The calendar to floor.public void incrementTime(Calendar calendar)
Calendar
upwards by
monthStep months.incrementTime
in interface IlvTimeIncrementPolicy
calendar
- The calendar to increment.public void decrementTime(Calendar calendar)
Calendar
downwards by
monthStep months.decrementTime
in interface IlvTimeIncrementPolicy
calendar
- The calendar to decrement.© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.