public interface ISchedulePolicy extends IViewableContainerPolicy
Modifier and Type | Method and Description |
---|---|
IThingID |
createSchedule(IContext context,
String interval,
String timeAt,
String eventName)
|
void |
destroySchedule(IContext context,
IThingID scheduleID)
|
IListView<IView> |
listSchedules(IContext context,
String view)
Returns an
IListView of schedules in the system |
void |
setNextTime(IContext context,
IThingID scheduleID,
long nextTime)
|
void |
setSchedulePaused(IContext context,
IThingID scheduleID,
boolean paused)
Pauses/resumes a schedule.
|
void |
setScheduleProperties(IContext context,
IThingID scheduleID,
String interval,
String timeAt,
String eventName)
|
void |
triggerSchedule(IContext context,
IThingID scheduleID)
Causes an event to be fired for the schedule as if it's scheduled time was now.
|
getPagingCookie, getPagingCookie, pageBackward, pageForeward, setPagingCookie
getIcon, view
getComponentData, getComponentName, getComponentProvider, getURI, isInitialized, setComponentData, setComponentProvider
init, shutdown
IThingID createSchedule(IContext context, String interval, String timeAt, String eventName) throws BizException
ICommand
with
the appropriate IContext
Creates a schedule with the specified information.context
- Context state information (current user, etc.).interval
- for the schedule in ISO8601 format (ex. 2D - every 2 days)timeAt
- firing time for the schedule in ISO8601 format (ex. 14:00:00 - at 2 pm)eventName
- name of the scheduleBizException
void destroySchedule(IContext context, IThingID scheduleID) throws BizException
ICommand
with
the appropriate IContext
Destroys the specified schedule.context
- Context state information (current user, etc.).scheduleID
- IThingID of the schedule to destroyBizException
void setScheduleProperties(IContext context, IThingID scheduleID, String interval, String timeAt, String eventName) throws BizException
ICommand
with
the appropriate IContext
Sets the properties of the specified schedule. Properties that are not being changed may be left null.context
- Context state information (current user, etc.).scheduleID
- IThingID of the schedule whose properties to modifyinterval
- for the scheduled in ISO8601 format (ex. 2D - every 2 days)timeAt
- timeAt firing time for the scheduled in ISO8601 format (ex. 14:00:00 - at 2 pm)eventName
- name of the scheduleBizException
void setNextTime(IContext context, IThingID scheduleID, long nextTime) throws BizException
ICommand
with
the appropriate IContext
Set the next firing time for the specified schedule.context
- Context state information (current user, etc.).scheduleID
- IThingID of the schedule to modifynextTime
- next firing time for the scheduleBizException
void setSchedulePaused(IContext context, IThingID scheduleID, boolean paused) throws BizException
context
- Context state information (current user, etc.).scheduleID
- IThingID of the schedule to pause/resumepaused
- the paused flag. true pauses, false resumes.BizException
void triggerSchedule(IContext context, IThingID scheduleID) throws BizException
context
- Context state information (current user, etc.).scheduleID
- IThingID of the schedule to triggerBizException
IListView<IView> listSchedules(IContext context, String view) throws BizException
IListView
of schedules in the systemcontext
- Context state information (current user, etc.).view
- Name of view.BizException