Lesson 8: SchedulerListeners   Leave a comment

SchedulerListeners are much like TriggerListeners
and JobListeners, except they receive notification of events within the
Scheduler itself – not necessarily events related to a specific trigger
or job.

Scheduler-related events include: the addition of a job/trigger, the
removal of a job/trigger, a serious error within the scheduler,
notification of the scheduler being shutdown, and others.

The org.quartz.SchedulerListener Interface
public interface SchedulerListener {

public void jobScheduled(Trigger trigger);

public void jobUnscheduled(String triggerName, String triggerGroup);

public void triggerFinalized(Trigger trigger);

public void triggersPaused(String triggerName, String triggerGroup);

public void triggersResumed(String triggerName, String triggerGroup);

public void jobsPaused(String jobName, String jobGroup);

public void jobsResumed(String jobName, String jobGroup);

public void schedulerError(String msg, SchedulerException cause);

public void schedulerShutdown();

}

SchedulerListeners are created and registered in much the same way
as the other listener types, except there is no distinction between
global and non-global listeners. SchedulerListeners can be virtually
any object that implements the org.quartz.SchedulerListener interface.

Posted 2009年11月3日 by gw8310 in Computers and Internet

发表评论

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / 更改 )

Twitter picture

You are commenting using your Twitter account. Log Out / 更改 )

Facebook photo

You are commenting using your Facebook account. Log Out / 更改 )

Google+ photo

You are commenting using your Google+ account. Log Out / 更改 )

Connecting to %s

%d 博主赞过: