|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SchedulerMBean
ScheduleMBean interface.
Field Summary | |
---|---|
static ObjectName |
OBJECT_NAME
The default ObjectName |
Fields inherited from interface org.jboss.system.ServiceMBean |
---|
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED |
Method Summary | |
---|---|
String |
getDateFormat()
|
boolean |
getFixedRate()
|
long |
getInitialRepetitions()
|
String |
getInitialStartDate()
|
long |
getRemainingRepetitions()
|
String |
getSchedulableArguments()
|
String |
getSchedulableArgumentTypes()
|
String |
getSchedulableClass()
|
String |
getSchedulableMBean()
|
String |
getSchedulableMBeanMethod()
|
long |
getSchedulePeriod()
|
String |
getTimerName()
|
boolean |
isActive()
|
boolean |
isRestartPending()
|
boolean |
isStartAtStartup()
|
boolean |
isStarted()
|
boolean |
isUsingMBean()
|
void |
restartSchedule()
Stops the server right now and starts it right now. |
void |
setDateFormat(String dateFormat)
The date format used to parse date/times - when empty or null the locale is used to parse dates |
void |
setFixedRate(boolean fixedRate)
The default scheduling to use, fixed-rate or fixed-delay (false, default) |
void |
setInitialRepetitions(long numberOfCalls)
The number of scheduled calls |
void |
setInitialStartDate(String startDate)
The first scheduled call - NOW: date will be the current date (new Date()) plus 1 seconds - Date as String able to be parsed by SimpleDateFormat with default format - Date as String parsed using the date format attribute - Milliseconds since 1/1/1970 If the date is in the past the Scheduler will search a start date in the future with respect to the initial repetitions and the period between calls. |
void |
setSchedulableArguments(String argumentList)
The arguments to pass to the schedule |
void |
setSchedulableArgumentTypes(String typeList)
The comma seperated list of argument types for the Schedulable class. |
void |
setSchedulableClass(String schedulableClass)
The fully qualified Class name of the Schedulable Class being called by the Scheduler. |
void |
setSchedulableMBean(String schedulableMBean)
The fully qualified JMX MBean name of the Schedulable MBean to be called. |
void |
setSchedulableMBeanMethod(String schedulableMBeanMethod)
The method name to be called on the Schedulable MBean. |
void |
setSchedulePeriod(long period)
The Schedule Period between two scheduled call (in msecs) |
void |
setStartAtStartup(boolean startAtStartup)
Start the scheduler when the MBean started or not. |
void |
setTimerName(String timerName)
The JMX Timer to use (or create if not there) |
void |
startSchedule()
Starts the schedule if the schedule is stopped otherwise nothing will happen. |
void |
stopSchedule()
Stops the schedule immediately. |
void |
stopSchedule(boolean doItNow)
Stops the schedule because it is either not used anymore or to restart it with new values. |
Methods inherited from interface org.jboss.system.ServiceMBean |
---|
getName, getState, getStateString, jbossInternalLifecycle |
Methods inherited from interface org.jboss.system.Service |
---|
create, destroy, start, stop |
Field Detail |
---|
static final ObjectName OBJECT_NAME
Method Detail |
---|
void setInitialStartDate(String startDate)
String getInitialStartDate()
void setDateFormat(String dateFormat)
String getDateFormat()
void setSchedulePeriod(long period)
long getSchedulePeriod()
void setInitialRepetitions(long numberOfCalls)
long getInitialRepetitions()
void setSchedulableClass(String schedulableClass) throws InvalidParameterException
InvalidParameterException
String getSchedulableClass()
void setSchedulableArguments(String argumentList)
String getSchedulableArguments()
void setSchedulableArgumentTypes(String typeList) throws InvalidParameterException
InvalidParameterException
String getSchedulableArgumentTypes()
void setSchedulableMBean(String schedulableMBean) throws InvalidParameterException
setSchedulableClass(java.lang.String)
,
setSchedulableArguments(java.lang.String)
and setSchedulableArgumentTypes(java.lang.String)
are cleared and not used anymore. Therefore only use either Schedulable Class
or Schedulable MBean. If setSchedulableMBeanMethod(java.lang.String)
is not set then
the schedule method as in the Schedulable.perform(java.util.Date, long)
will be called with
the same arguments. Also note that the Object Name will not be checked if the
MBean is available. If the MBean is not available it will not be called but the
remaining repetitions will be decreased.
InvalidParameterException
String getSchedulableMBean()
void setSchedulableMBeanMethod(String schedulableMBeanMethod) throws InvalidParameterException
InvalidParameterException
String getSchedulableMBeanMethod()
void setFixedRate(boolean fixedRate)
boolean getFixedRate()
void setStartAtStartup(boolean startAtStartup)
boolean isStartAtStartup()
void setTimerName(String timerName)
String getTimerName()
long getRemainingRepetitions()
boolean isActive()
boolean isStarted()
boolean isRestartPending()
boolean isUsingMBean()
void startSchedule()
InvalidParameterException
- If any of the necessary values are not set or invalid
(especially for the Schedulable class attributes).void stopSchedule(boolean doItNow)
doItNow
- If true the schedule will be stopped without waiting for the next scheduled
call otherwise the next call will be performed before the schedule is stopped.void stopSchedule()
void restartSchedule()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |