|
Oracle© Fusion Middleware Java API Reference for Oracle ADF Faces 11g Release 1 (11.1.1.7.0) E10684-08 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.adf.view.rich.model.CalendarModel
public abstract class CalendarModel
CalendarModel is an abstract base class that represents a model for a Calendar component. The calendarModel returns CalendarActivity objects.
The Calendar model needs to generate separate CalendarActivity objects representing each recurring calendar activity.
CalendarActivity
Constructor Summary | |
---|---|
CalendarModel() |
Method Summary | |
---|---|
abstract CalendarActivity |
getActivity(java.lang.String providerId, java.lang.String activityId, java.util.Date rangeStart, java.util.Date rangeEnd, java.util.TimeZone timeZone) Return CalendarActivity based on providerId and id within a range. |
abstract java.util.List<CalendarActivity> |
getAllDayActivities(java.util.Date rangeStart, java.util.Date rangeEnd, java.util.TimeZone timeZone) Returns activities that intersect the range. |
CalendarProvider |
getProvider(java.lang.String id) Find a provider, or activity owner, based on an id. |
java.util.List<CalendarProvider> |
getProviders() A CalendarProvider represents the provider, or owner, of activities. |
abstract java.util.List<CalendarActivity> |
getTimeActivities(java.util.Date rangeStart, java.util.Date rangeEnd, java.util.TimeZone timeZone) Returns activities that intersect the range. |
static boolean |
isActivityInRange(CalendarActivity activity, java.util.TimeZone timeZone, java.util.Date rangeStart, java.util.Date rangeEnd) Return true if the activity intersects the date range. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CalendarModel()
Method Detail |
---|
public abstract java.util.List<CalendarActivity> getTimeActivities(java.util.Date rangeStart, java.util.Date rangeEnd, java.util.TimeZone timeZone)
Returns activities that intersect the range. The start date is inclusive, meaning if the activity start date is an exact match to the range start date it is included in the returned list. The end date is exclusive, meaning if the activity start date is an exact match to the range end date it is not included in the returned list.
This method will generate a List of CalendarActivity objects where TimeType is TIME. The activities are returned in sorted order by start date.
If the start date is null, return all the activities before the end date (exclusive). If the end date is null, return all the activities after the start date (inclusive). If both are null, return all activities
Activities should be stable per request. Meaning between the time the model is asked for activities in a range, and the time the activities are rendered, the activity should not change. For example the start and end time should not change, the timeType should not change, etc.
rangeStart
- range start date (inclusive)rangeEnd
- range end date (exclusive)timeZone
- the timeZoneCalendarActivity
objectspublic abstract java.util.List<CalendarActivity> getAllDayActivities(java.util.Date rangeStart, java.util.Date rangeEnd, java.util.TimeZone timeZone)
Returns activities that intersect the range. The start date is inclusive, meaning if the activity start date is an exact match to the range start date it is included in the returned list. The end date is exclusive, meaning if the activity start date is an exact match to the range end date it is not included in the returned list.
This method will generate a List of CalendarActivity objects where TimeType is ALLDAY. The activities must be returned in sorted order by start date.
If the start date is null, return all the activities before the end date (exclusive). If the end date is null, return all the activities after the start date (inclusive). If both are null, return all activities
Activities should be stable per request. Meaning between the time the model is asked for activities in a range, and the time the activities are rendered, the activity should not change. For example the start and end time should not change, the timeType should not change, etc.
rangeStart
- range start date (inclusive)rangeEnd
- range end date (exclusive)timeZone
- the timeZoneCalendarActivity
objects.public abstract CalendarActivity getActivity(java.lang.String providerId, java.lang.String activityId, java.util.Date rangeStart, java.util.Date rangeEnd, java.util.TimeZone timeZone)
providerId
- the id of the provideractivityId
- the id of the activityrangeStart
- the start of the range to search in. This is just a hint which the model may (or may not) be able to use to search efficiently, for example by looking at the expected range the model may know whether or not to search cached activities. If the activity exists it will be returned, regardless of whether it's in the range. A rangeStart of null is legal.rangeEnd
- the end of the range to search in. This is just a hint which the model may (or may not) be able to use to search efficiently, for example by looking at the expected range the model may know whether or not to search cached activities. If the activity exists it will be returned, regardless of whether it's in the range. A rangeEnd of null is legal.timeZone
- the timeZoneCalendarActivity
object or null if its not found.public CalendarProvider getProvider(java.lang.String id)
id
- the id of the provider to returnpublic java.util.List<CalendarProvider> getProviders()
public static boolean isActivityInRange(CalendarActivity activity, java.util.TimeZone timeZone, java.util.Date rangeStart, java.util.Date rangeEnd)
The conditions in which an activity intersects the date range are as follows:
activity
-timeZone
-rangeStart
-rangeEnd
-java.lang.NullPointerException
- if activity or timeZone is null
.
|
Oracle© Fusion Middleware Java API Reference for Oracle ADF Faces 11g Release 1 (11.1.1.7.0) E10684-08 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |