org.exolab.jms.events
Interface EventHandler
- All Superinterfaces:
- java.io.Serializable
- All Known Implementing Classes:
- GarbageCollectionService, BatchingRdbmsAdapter, ObjectAdapter, RDBMSAdapter, AdminConnectionManager, JmsServerConnectionManager
- public interface EventHandler
- extends java.io.Serializable
This class defines an object that receives event notification from an
EventManager
. It also defines a method to return a
HandleIfc
to the event handler, making it possible to be
resolved at some future time (i.e across EventManager invocations)
- Version:
- $Revision: 1.3 $ $Date: 2003/08/17 01:32:22 $
- Author:
- Jim Alateras
- See Also:
EventManager
,
Event
Method Summary |
org.exolab.core.foundation.HandleIfc |
getHandle()
Return a handle to this event handler for the purpose of storing and
restoring it. |
void |
handleEvent(int event,
java.lang.Object callback,
long time)
Handle the specified event, generated by the EventManager . |
handleEvent
public void handleEvent(int event,
java.lang.Object callback,
long time)
- Handle the specified event, generated by the
EventManager
.
The event handler pressumably knows how to handle the callback object
and should cast it appropriately before using it.
This methodshould not throw any exceptions
- Parameters:
event
- the event to handlecallback
- the callback objecttime
- the absolute time, in ms, that the event
fired.
getHandle
public org.exolab.core.foundation.HandleIfc getHandle()
- Return a handle to this event handler for the purpose of storing and
restoring it. If you want event handlers to persist across subsequent
invocations of the
EventManager
then you must support this
method, otherwise this method can simply return null.
- Returns:
- HandleIfc return a reference to the handle.
Copyright © 1999-2004 The OpenJMS Group. All Rights Reserved.