views:

23

answers:

0

I have the following method which is constantly receiving events:

@Override
public void update(EventBean[] newEvents, EventBean[] oldEvents) {
   // Process events
}

I want to be alerted when there is a gap of greater than x seconds since the last event. I have had a look at the Java timer classes and the quartz scheduling api but I have not seen any really good clean examples.

Any general advise, apis, ideas, pitfalls on the subject would be appreciated.

Thanks, Karl