Oracle

com.compoze.collab.exchange
Class AppointmentRecurrencePattern

java.lang.Object
  extended by com.compoze.collab.exchange.RecurrencePattern
      extended by com.compoze.collab.exchange.AppointmentRecurrencePattern

public final class AppointmentRecurrencePattern
extends RecurrencePattern

This class is used to set recurrence patterns on an appoinment.


Field Summary
static AppointmentRecurrencePattern NONE
          This constant represents no recurrence, and may be passed in to clear the recurrence pattern on an existing appointment.
 
Method Summary
static AppointmentRecurrencePattern createDaily(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, java.util.Date endDate, int iInterval)
          Creates a daily appointment recurrence pattern with an end date
static AppointmentRecurrencePattern createDaily(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, int iInterval)
          Creates a daily appointment recurrence pattern with no end date.
static AppointmentRecurrencePattern createDaily(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, int iInterval, int iOccurrences)
          Creates a daily appointment recurrence pattern for a number of occurrences.
static AppointmentRecurrencePattern createMonthly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, java.util.Date endDate, int iDayOfMonth, int iInterval)
          Creates a monthly recurrence pattern with an end date.
static AppointmentRecurrencePattern createMonthly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, int iDayOfMonth, int iInterval)
          Creates a monthly appointment recurrence pattern with no end date.
static AppointmentRecurrencePattern createMonthly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, int iDayOfMonth, int iInterval, int iOccurrences)
          Creates a monthly recurrence pattern for a number of occurrences.
static AppointmentRecurrencePattern createMonthlyNth(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, java.util.Date endDate, RecurrenceInstance instance, DaysOfWeek daysOfWeek, int iInterval)
          Creates a monthly nth recurrence pattern with an end date.
static AppointmentRecurrencePattern createMonthlyNth(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, RecurrenceInstance instance, DaysOfWeek daysOfWeek, int iInterval)
          Creates a monthly nth recurrence pattern with no end date.
static AppointmentRecurrencePattern createMonthlyNth(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, RecurrenceInstance instance, DaysOfWeek daysOfWeek, int iInterval, int iOccurrences)
          Creates a monthly nth recurrence pattern for occurrences.
static AppointmentRecurrencePattern createWeekly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, java.util.Date endDate, DaysOfWeek daysOfWeek, int iInterval)
          Creates a weekly recurrence pattern with an end date.
static AppointmentRecurrencePattern createWeekly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, DaysOfWeek daysOfWeek, int iInterval)
          Creates a weekly recurrence pattern with no end date.
static AppointmentRecurrencePattern createWeekly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, DaysOfWeek daysOfWeek, int iInterval, int iOccurrences)
          Creates a weekly recurrence pattern for a number of occurrences.
static AppointmentRecurrencePattern createYearly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, java.util.Date endDate, int iMonthOfYear, int iDayOfMonth)
          Creates a yearly recurrence pattern with an end date.
static AppointmentRecurrencePattern createYearly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, int iMonthOfYear, int iDayOfMonth)
          Creates a yearly recurrence pattern with no end date.
static AppointmentRecurrencePattern createYearly(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, int iMonthOfYear, int iDayOfMonth, int iOccurrences)
          Creates a yearly recurrence pattern ending for a number of occurrences.
static AppointmentRecurrencePattern createYearlyNth(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, java.util.Date endDate, RecurrenceInstance instance, DaysOfWeek daysOfWeek, int iMonthOfYear)
          Creates a yearly nth recurrence pattern with an end date.
static AppointmentRecurrencePattern createYearlyNth(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, RecurrenceInstance instance, DaysOfWeek daysOfWeek, int iMonthOfYear)
          Creates a yearly nth recurrence pattern with no end date.
static AppointmentRecurrencePattern createYearlyNth(java.util.Date startTime, java.util.Date endTime, java.util.Date startDate, RecurrenceInstance instance, DaysOfWeek daysOfWeek, int iMonthOfYear, int iOccurrences)
          Creates a yearly nth recurrence pattern with a number of occurrences.
 boolean equals(java.lang.Object o)
          Compares equality of two patterns.
 java.util.Date getEndTime()
          Gets the end time of the pattern.
static AppointmentRecurrencePattern getFrom(IExchangeCalendarItem appt)
          Gets the recurrence pattern from an appointment.
 java.util.Date getStartTime()
          Gets the start time of the pattern.
 void setTimes(java.util.Date startTime, java.util.Date endTime)
          Sets the start time and end time of a pattern.
 java.lang.String toString()
          Gets the string representation of the pattern.
 
Methods inherited from class com.compoze.collab.exchange.RecurrencePattern
getDayOfMonth, getDaysOfWeek, getEndType, getInstance, getInterval, getMonthOfYear, getOccurrences, getPatternEndDate, getPatternStartDate, getType
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

NONE

public static final AppointmentRecurrencePattern NONE
This constant represents no recurrence, and may be passed in to clear the recurrence pattern on an existing appointment.

Method Detail

createDaily

public static AppointmentRecurrencePattern createDaily(java.util.Date startTime,
                                                       java.util.Date endTime,
                                                       java.util.Date startDate,
                                                       int iInterval)
Creates a daily appointment recurrence pattern with no end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
iInterval - the number of days between recurrences. The interval must be greater than 0.
Returns:
the pattern

createDaily

public static AppointmentRecurrencePattern createDaily(java.util.Date startTime,
                                                       java.util.Date endTime,
                                                       java.util.Date startDate,
                                                       java.util.Date endDate,
                                                       int iInterval)
Creates a daily appointment recurrence pattern with an end date

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
endDate - the end date of the pattern or null to specify that the pattern has no end.
iInterval - the number of days between recurrences. The interval must be greater than 0.
Returns:
the pattern

createDaily

public static AppointmentRecurrencePattern createDaily(java.util.Date startTime,
                                                       java.util.Date endTime,
                                                       java.util.Date startDate,
                                                       int iInterval,
                                                       int iOccurrences)
Creates a daily appointment recurrence pattern for a number of occurrences.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
iInterval - the number of days between recurrences. The interval must be greater than 0.
iOccurrences - the number of times the appointment recurs. The occurrences must be greater than 0.
Returns:
the pattern

createWeekly

public static AppointmentRecurrencePattern createWeekly(java.util.Date startTime,
                                                        java.util.Date endTime,
                                                        java.util.Date startDate,
                                                        DaysOfWeek daysOfWeek,
                                                        int iInterval)
Creates a weekly recurrence pattern with no end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
daysOfWeek - the days of week to recur (or null to use the day of the week of the start date)
iInterval - the number of weeks between recurrences. The interval must be greater than 0.
Returns:
the pattern

createWeekly

public static AppointmentRecurrencePattern createWeekly(java.util.Date startTime,
                                                        java.util.Date endTime,
                                                        java.util.Date startDate,
                                                        java.util.Date endDate,
                                                        DaysOfWeek daysOfWeek,
                                                        int iInterval)
Creates a weekly recurrence pattern with an end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
endDate - the end date of the pattern
daysOfWeek - the days of week to recur (or null to use the day of the week of the start date)
iInterval - the number of weeks between recurrences. The interval must be greater than 0.
Returns:
the pattern

createWeekly

public static AppointmentRecurrencePattern createWeekly(java.util.Date startTime,
                                                        java.util.Date endTime,
                                                        java.util.Date startDate,
                                                        DaysOfWeek daysOfWeek,
                                                        int iInterval,
                                                        int iOccurrences)
Creates a weekly recurrence pattern for a number of occurrences.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
daysOfWeek - the days of week to recur (or null to use the day of the week of the start date)
iInterval - the number of weeks between recurrences. The interval must be greater than 0.
iOccurrences - the number of times the pattern recurs. The occurrences must be greater than 0. to one)
Returns:
the pattern

createMonthly

public static AppointmentRecurrencePattern createMonthly(java.util.Date startTime,
                                                         java.util.Date endTime,
                                                         java.util.Date startDate,
                                                         int iDayOfMonth,
                                                         int iInterval)
Creates a monthly appointment recurrence pattern with no end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
iDayOfMonth - the day of the month to recur (or 0 to use the day of the month of the start date)
iInterval - the number of months between recurrences. The interval must be greater than 0.
Returns:
the pattern

createMonthly

public static AppointmentRecurrencePattern createMonthly(java.util.Date startTime,
                                                         java.util.Date endTime,
                                                         java.util.Date startDate,
                                                         java.util.Date endDate,
                                                         int iDayOfMonth,
                                                         int iInterval)
Creates a monthly recurrence pattern with an end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
endDate - the end date of the pattern
iDayOfMonth - the day of the month to recur (or 0 to use the day of the month of the start date)
iInterval - the number of months between recurrences. The interval must be greater than 0.
Returns:
the pattern

createMonthly

public static AppointmentRecurrencePattern createMonthly(java.util.Date startTime,
                                                         java.util.Date endTime,
                                                         java.util.Date startDate,
                                                         int iDayOfMonth,
                                                         int iInterval,
                                                         int iOccurrences)
Creates a monthly recurrence pattern for a number of occurrences.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
iDayOfMonth - the day of the month to recur (or 0 to use the day of the month of the start date)
iInterval - the number of months between recurrences. The interval must be greater than 0.
iOccurrences - the number of times the pattern recurs. The occurrences must be greater than 0.
Returns:
the pattern

createMonthlyNth

public static AppointmentRecurrencePattern createMonthlyNth(java.util.Date startTime,
                                                            java.util.Date endTime,
                                                            java.util.Date startDate,
                                                            RecurrenceInstance instance,
                                                            DaysOfWeek daysOfWeek,
                                                            int iInterval)
Creates a monthly nth recurrence pattern with no end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
instance - the instance of the days of the week that the appointment recurs
daysOfWeek - the days of week (or null to use the day of the week of the start date)
iInterval - the number of months between recurrences. The interval must be greater than 0.
Returns:
the pattern

createMonthlyNth

public static AppointmentRecurrencePattern createMonthlyNth(java.util.Date startTime,
                                                            java.util.Date endTime,
                                                            java.util.Date startDate,
                                                            RecurrenceInstance instance,
                                                            DaysOfWeek daysOfWeek,
                                                            int iInterval,
                                                            int iOccurrences)
Creates a monthly nth recurrence pattern for occurrences.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
instance - the instance of the days of the week that the pattern recurs
daysOfWeek - the days of week (or null to use the day of the week of the start date)
iInterval - the number of months between recurrences. The interval must be greater than 0.
iOccurrences - the number of times the pattern recurs. The occurrences must be greater than 0.
Returns:
the pattern

createMonthlyNth

public static AppointmentRecurrencePattern createMonthlyNth(java.util.Date startTime,
                                                            java.util.Date endTime,
                                                            java.util.Date startDate,
                                                            java.util.Date endDate,
                                                            RecurrenceInstance instance,
                                                            DaysOfWeek daysOfWeek,
                                                            int iInterval)
Creates a monthly nth recurrence pattern with an end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
endDate - the end date of the pattern (or null if the pattern has no end)
instance - the instance of the days of the week that the pattern recurs
daysOfWeek - the days of week (or null to use the day of the week of the start date)
iInterval - the number of months between recurrences. The interval must be greater than 0.
Returns:
the pattern

createYearly

public static AppointmentRecurrencePattern createYearly(java.util.Date startTime,
                                                        java.util.Date endTime,
                                                        java.util.Date startDate,
                                                        int iMonthOfYear,
                                                        int iDayOfMonth)
Creates a yearly recurrence pattern with no end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
iMonthOfYear - the month of the year to recur (or 0 to use the month of the year of the start date)
iDayOfMonth - the day of the month to recur (or 0 to use the day of the month of the start date)
Returns:
the pattern

createYearly

public static AppointmentRecurrencePattern createYearly(java.util.Date startTime,
                                                        java.util.Date endTime,
                                                        java.util.Date startDate,
                                                        java.util.Date endDate,
                                                        int iMonthOfYear,
                                                        int iDayOfMonth)
Creates a yearly recurrence pattern with an end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
endDate - the end date of the pattern (or null if the pattern has no end)
iMonthOfYear - the month of the year to recur (or 0 to use the month of the year of the start date)
iDayOfMonth - the day of the month to recur (or 0 to use the day of the month of the start date)
Returns:
the pattern

createYearly

public static AppointmentRecurrencePattern createYearly(java.util.Date startTime,
                                                        java.util.Date endTime,
                                                        java.util.Date startDate,
                                                        int iMonthOfYear,
                                                        int iDayOfMonth,
                                                        int iOccurrences)
Creates a yearly recurrence pattern ending for a number of occurrences.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
iMonthOfYear - the month of the year to recur (or 0 to use the month of the year of the start date)
iDayOfMonth - the day of the month to recur (or 0 to use the day of the month of the start date)
iOccurrences - the number of times the pattern recurs. The occurrences must be greater than 0.
Returns:
the pattern

createYearlyNth

public static AppointmentRecurrencePattern createYearlyNth(java.util.Date startTime,
                                                           java.util.Date endTime,
                                                           java.util.Date startDate,
                                                           RecurrenceInstance instance,
                                                           DaysOfWeek daysOfWeek,
                                                           int iMonthOfYear)
Creates a yearly nth recurrence pattern with no end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
instance - the instance of the days of the week that the pattern recurs
daysOfWeek - the days of week (or null to use the day of the week of the start date)
iMonthOfYear - the month of the year to recur (or 0 to use the month of the year of the start date)
Returns:
the pattern

createYearlyNth

public static AppointmentRecurrencePattern createYearlyNth(java.util.Date startTime,
                                                           java.util.Date endTime,
                                                           java.util.Date startDate,
                                                           RecurrenceInstance instance,
                                                           DaysOfWeek daysOfWeek,
                                                           int iMonthOfYear,
                                                           int iOccurrences)
Creates a yearly nth recurrence pattern with a number of occurrences.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
instance - the instance of the days of the week that the pattern recurs
daysOfWeek - the days of week (or null to use the day of the week of the start date)
iMonthOfYear - the month of the year to recur (or 0 to use the month of the year of the start date)
iOccurrences - the number of times the pattern recurs. The occurrences must be greater than 0.
Returns:
the pattern

createYearlyNth

public static AppointmentRecurrencePattern createYearlyNth(java.util.Date startTime,
                                                           java.util.Date endTime,
                                                           java.util.Date startDate,
                                                           java.util.Date endDate,
                                                           RecurrenceInstance instance,
                                                           DaysOfWeek daysOfWeek,
                                                           int iMonthOfYear)
Creates a yearly nth recurrence pattern with an end date.

Parameters:
startTime - the start time of the pattern (not null).
endTime - the end time of the pattern (not null).
startDate - the start date of the pattern (or null to use startTime)
endDate - the end date of the pattern (or null if the pattern has no end)
instance - the instance of the days of the week that the pattern recurs
daysOfWeek - the days of week (or null to use the day of the week of the start date)
iMonthOfYear - the month of the year to recur (or 0 to use the month of the year of the start date)
Returns:
the pattern

getStartTime

public java.util.Date getStartTime()
Gets the start time of the pattern. The start time of a pattern contains no date information, only time information. The date value should be ignored. This value requires that a timezone is applied to it in order to display the correct time since it is stored in GMT.

Returns:
a date object representing the start time

getEndTime

public java.util.Date getEndTime()
Gets the end time of the pattern. The end time of a pattern contains no date information, only time information. The date value should be ignored. This value requires that a timezone is applied to it in order to display the correct time since it is stored in GMT.

Returns:
a date object representing the end time

getFrom

public static AppointmentRecurrencePattern getFrom(IExchangeCalendarItem appt)
                                            throws CollaborationException
Gets the recurrence pattern from an appointment.

Parameters:
appt - the appointment
Returns:
the pattern
Throws:
CollaborationException - if there was an error getting the pattern

equals

public boolean equals(java.lang.Object o)
Compares equality of two patterns.

Overrides:
equals in class java.lang.Object
Returns:
true if the two patterns are equal.

toString

public java.lang.String toString()
Gets the string representation of the pattern.

Overrides:
toString in class java.lang.Object

setTimes

public void setTimes(java.util.Date startTime,
                     java.util.Date endTime)
Sets the start time and end time of a pattern. Appointment recurrence patterns store the start/end time and start/end date separately.

Parameters:
startTime - the time that the pattern starts.
endTime - the time that the pattern ends.

Oracle

Copyright ©1999-2008 Oracle All rights reserved.