|
Oracle | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.compoze.domino.RepeatPattern
public class RepeatPattern
This class represents the repeating pattern. A repeating
pattern defines how an entity repeats, for example, daily.
Use the methods starting with create
to
create common repeating patterns.
Field Summary | |
---|---|
static int |
BYWEEK_FIFTH
The value that represents the 'fifth week'. |
static int |
BYWEEK_FIRST
The value that represents the 'first week'. |
static int |
BYWEEK_FOURTH
The value that represents the 'fourth week'. |
static int |
BYWEEK_SECOND
The value that represents the 'second week'. |
static int |
BYWEEK_THIRD
The value that represents the 'third week'. |
static int |
FRIDAY
The value that represents the day Friday. |
static int |
MONDAY
The value that represents the day Monday. |
static int |
SATURDAY
The value that represents the day Saturday. |
static int |
SUNDAY
The value that represents the day Sunday. |
static int |
THURSDAY
The value that represents the day Thursday. |
static int |
TUESDAY
The value that represents the day Tuesday. |
static int |
UPDATE_ALL
The value that represents the update all rule. |
static int |
UPDATE_THIS_INSTANCE
The value that represents the update this instance rule. |
static int |
WEDNESDAY
The value that represents the day Wednesday. |
Method Summary | |
---|---|
static RepeatPattern |
createCustom(java.util.Date[] dates)
Creates a custom repeating pattern. |
static RepeatPattern |
createDaily(java.util.Date startDate,
int iInterval,
RepeatWeekends weekends,
java.util.Date untilDate)
Creates a daily repeating pattern. |
static RepeatPattern |
createDaily(java.util.Date startDate,
int iInterval,
RepeatWeekends weekends,
RepeatForUnit forUnit,
int iFor)
Creates a daily repeating pattern. |
static RepeatPattern |
createMonthlyByDate(java.util.Date startDate,
int iInterval,
int[] daysOfMonth,
RepeatWeekends weekends,
java.util.Date untilDate)
Creates a monthly by date repeating pattern. |
static RepeatPattern |
createMonthlyByDate(java.util.Date startDate,
int iInterval,
int[] daysOfMonth,
RepeatWeekends weekends,
RepeatForUnit forUnit,
int iFor)
Creates a monthly by date repeating pattern. |
static RepeatPattern |
createMonthlyByDay(java.util.Date startDate,
int iInterval,
int[] daysOfWeek,
RepeatWeekends weekends,
java.util.Date untilDate)
Creates a monthly by day repeating pattern. |
static RepeatPattern |
createMonthlyByDay(java.util.Date startDate,
int iInterval,
int[] daysOfWeek,
RepeatWeekends weekends,
RepeatForUnit forUnit,
int iFor)
Creates a monthly by day repeating pattern. |
static RepeatPattern |
createWeekly(java.util.Date startDate,
int iInterval,
int[] daysOfWeek,
RepeatWeekends weekends,
java.util.Date untilDate)
Creates a weekly repeating pattern. |
static RepeatPattern |
createWeekly(java.util.Date startDate,
int iInterval,
int[] daysOfWeek,
RepeatWeekends weekends,
RepeatForUnit forUnit,
int iFor)
Creates a weekly repeating pattern. |
static RepeatPattern |
createYearly(java.util.Date startDate,
int iInterval,
RepeatWeekends weekends,
java.util.Date untilDate)
Creates a yearly repeating pattern. |
static RepeatPattern |
createYearly(java.util.Date startDate,
int iInterval,
RepeatWeekends weekends,
RepeatForUnit forUnit,
int iFor)
Creates a yearly repeating pattern. |
RepeatAdjust |
getAdjust()
Gets the adjust for the repeat pattern. |
static java.lang.String |
getDayByNumber(int iDay)
Gets the localized string for a day. |
static java.lang.String |
getDayByNumber(int iDay,
int iFieldWidth,
java.util.Calendar cal,
java.util.Locale locale)
Gets the localized string for a day. |
static java.lang.String |
getDayByNumber(int iDay,
java.util.Locale locale)
Gets the localized string for a day. |
int |
getFor()
Gets the repeat pattern for. |
RepeatForUnit |
getForUnit()
Gets the repeat pattern for unit. |
RepeatHow |
getHow()
Gets the repeat pattern how. |
java.util.Date[] |
getInstanceDates()
Gets a list of the dates for the repeat pattern. |
int |
getInterval()
Gets the repeat pattern interval. |
RepeatPattern |
getPatternInstance(java.util.Date startDate)
Gets a new instance of the repeat pattern with the new start date. |
RepeatPattern |
getPatternInstance(java.util.Date startDate,
java.util.Date untilDate)
Gets a new instance of the repeat pattern with the new start date. |
java.util.List |
getPropertyValues()
Gets a list of the values from the repeat pattern. |
RepeatWeekends |
getRepeatWeekends()
Gets the repeat pattern weekends. |
java.util.Date |
getStartDate()
Gets the start date for the repeat pattern. |
RepeatType |
getType()
Gets the repeat pattern type. |
java.util.Date |
getUntilDate()
Gets the until date for the repeat pattern. |
static void |
main(java.lang.String[] args)
|
void |
setStartDate(java.util.Date startDate)
Sets the start date for the repeat pattern. |
java.lang.String |
toString()
Returns the string representation of this object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int BYWEEK_FIRST
public static final int BYWEEK_SECOND
public static final int BYWEEK_THIRD
public static final int BYWEEK_FOURTH
public static final int BYWEEK_FIFTH
public static final int SUNDAY
public static final int MONDAY
public static final int TUESDAY
public static final int WEDNESDAY
public static final int THURSDAY
public static final int FRIDAY
public static final int SATURDAY
public static final int UPDATE_ALL
public static final int UPDATE_THIS_INSTANCE
Method Detail |
---|
public RepeatPattern getPatternInstance(java.util.Date startDate) throws InvalidRuleException
startDate
- the start date (may not be null
)
InvalidRuleException
public RepeatPattern getPatternInstance(java.util.Date startDate, java.util.Date untilDate) throws InvalidRuleException
startDate
- the start date (may not be null
)untilDate
- the until date (may not be null
)
InvalidRuleException
public RepeatAdjust getAdjust()
public RepeatType getType()
public java.util.Date getUntilDate()
null
if the repeat how is untilpublic int getInterval()
public int getFor()
public RepeatHow getHow()
getUntilDate()
,
getFor()
,
getForUnit()
public RepeatForUnit getForUnit()
public java.util.Date getStartDate()
public void setStartDate(java.util.Date startDate) throws InvalidRuleException, DominoException
startDate
- the start date (may not be null
)
InvalidRuleException
DominoException
public RepeatWeekends getRepeatWeekends()
public java.util.Date[] getInstanceDates()
public java.util.List getPropertyValues()
PropertyValue
objects (unmodifiable)public static RepeatPattern createDaily(java.util.Date startDate, int iInterval, RepeatWeekends weekends, java.util.Date untilDate) throws InvalidRuleException
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)weekends
- the weekends rule (may not be null
untilDate
- the until date (may not be null
and must be after the start date)
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createDaily(java.util.Date startDate, int iInterval, RepeatWeekends weekends, RepeatForUnit forUnit, int iFor) throws InvalidRuleException
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)weekends
- the weekends rule (may not be null
forUnit
- the for unitiFor
- the number of for units
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createCustom(java.util.Date[] dates) throws InvalidRuleException
dates
- the dates for the repeating pattern
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createYearly(java.util.Date startDate, int iInterval, RepeatWeekends weekends, java.util.Date untilDate) throws InvalidRuleException
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)weekends
- the weekends rule (may not be null
untilDate
- the until date (may not be null
and must be after the start date)
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createYearly(java.util.Date startDate, int iInterval, RepeatWeekends weekends, RepeatForUnit forUnit, int iFor) throws InvalidRuleException
When setting the for unit and number of units, since
this is a yearly repeating pattern, the for unit
must be at a minimum RepeatForUnit.YEARS
. If
not, there could potentially be no instance dates for
the pattern therefore creating an invalid pattern.
If you pass in a for unit less than RepeatForUnit.YEARS
,
the for unit is automatically adjusted.
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)weekends
- the weekends rule (may not be null
forUnit
- the for unit (minimum RepeatForUnit.YEARS
)iFor
- the number of for units
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createWeekly(java.util.Date startDate, int iInterval, int[] daysOfWeek, RepeatWeekends weekends, java.util.Date untilDate) throws InvalidRuleException
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)daysOfWeek
- the days of week (array of int of SUNDAY-SATURDAY
constants)weekends
- the weekends rule (may not be null
untilDate
- the until date (may not be null
and must be after the start date)
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createWeekly(java.util.Date startDate, int iInterval, int[] daysOfWeek, RepeatWeekends weekends, RepeatForUnit forUnit, int iFor) throws InvalidRuleException
When setting the for unit and number of units, since
this is a weekly repeating pattern, the for unit
must be at a minimum RepeatForUnit.WEEKS
. If
not, there could potentially be no instance dates for
the pattern therefore creating an invalid pattern.
If you pass in a for unit less than RepeatForUnit.WEEKS
,
the for unit is automatically adjusted.
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)daysOfWeek
- the days of week (array of int of SUNDAY-SATURDAY
constants)weekends
- the weekends rule (may not be null
forUnit
- the for unit (minimum RepeatForUnit.WEEKS
)iFor
- the number of for units
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createMonthlyByDate(java.util.Date startDate, int iInterval, int[] daysOfMonth, RepeatWeekends weekends, java.util.Date untilDate) throws InvalidRuleException
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)daysOfMonth
- the days of month (array of days, 1-31)weekends
- the weekends rule (may not be null
untilDate
- the until date (may not be null
and must be after the start date)
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createMonthlyByDate(java.util.Date startDate, int iInterval, int[] daysOfMonth, RepeatWeekends weekends, RepeatForUnit forUnit, int iFor) throws InvalidRuleException
When setting the for unit and number of units, since
this is a monthly repeating pattern, the for unit
must be at a minimum RepeatForUnit.MONTHS
. If
not, there could potentially be no instance dates for
the pattern therefore creating an invalid pattern.
If you pass in a for unit less than RepeatForUnit.MONTHS
,
the for unit is automatically adjusted.
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)daysOfMonth
- the days of month (array of days, 1-31)weekends
- the weekends rule (may not be null
forUnit
- the for unit (minimum RepeatForUnit.MONTHS
)iFor
- the number of for units
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createMonthlyByDay(java.util.Date startDate, int iInterval, int[] daysOfWeek, RepeatWeekends weekends, java.util.Date untilDate) throws InvalidRuleException
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)daysOfWeek
- the days of week (array of SUNDAY-SATURDAY
constants possibly or'd with one of the BYWEEK_
constants)weekends
- the weekends rule (may not be null
untilDate
- the until date (may not be null
and must be after the start date)
InvalidRuleException
- if the specified rule is invalidpublic static RepeatPattern createMonthlyByDay(java.util.Date startDate, int iInterval, int[] daysOfWeek, RepeatWeekends weekends, RepeatForUnit forUnit, int iFor) throws InvalidRuleException
When setting the for unit and number of units, since
this is a monthly repeating pattern, the for unit
must be at a minimum RepeatForUnit.MONTHS
. If
not, there could potentially be no instance dates for
the pattern therefore creating an invalid pattern.
If you pass in a for unit less than RepeatForUnit.MONTHS
,
the for unit is automatically adjusted.
startDate
- the start date (may not be null
)iInterval
- the interval (i.e. every, every other, every third)daysOfWeek
- the days of week (array of SUNDAY-SATURDAY
constants possibly or'd with one of the BYWEEK_
constants)weekends
- the weekends rule (may not be null
forUnit
- the for unit (minimum RepeatForUnit.MONTHS
)iFor
- the number of for units
InvalidRuleException
- if the specified rule is invalidpublic static java.lang.String getDayByNumber(int iDay)
iDay
- day number (see SUNDAY-SATURDAY
constants)
public static java.lang.String getDayByNumber(int iDay, java.util.Locale locale)
iDay
- day number (see SUNDAY-SATURDAY
constants)locale
- locale to use
public static java.lang.String getDayByNumber(int iDay, int iFieldWidth, java.util.Calendar cal, java.util.Locale locale)
iDay
- day number (see SUNDAY-SATURDAY
constants)iFieldWidth
- width of day fieldlocale
- locale to usecal
- calendar to use
public java.lang.String toString()
toString
in class java.lang.Object
public static void main(java.lang.String[] args)
|
Oracle | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |