public class EventManager extends Object
Modifier and Type | Field and Description |
---|---|
static int |
CURRENT_TX
execute event in current transaction
|
static int |
NEW_TX
reserved for future use, execute event in a new transaction (not yet implemented)
|
Constructor and Description |
---|
EventManager() |
Modifier and Type | Method and Description |
---|---|
static void |
raiseEvent(Event e)
Raises an event.
|
static long |
register(String name,
Class<? extends IEventHandler> eh,
Object context)
Register an event handler
|
static long |
register(String name,
Class<? extends IEventHandler> eh,
Object context,
ActivityInstance registrant)
Register an event handler
|
static void |
unregister(long oid)
unregister an event handler
|
static void |
unregister(String name,
ProcessInstance registrant)
Unregister all event handler for the named event.
|
static void |
unregisterAll(ActivityInstance registrant) |
static void |
unregisterAll(ProcessInstance registrant)
unregister all event handlers of a process
|
public static final int CURRENT_TX
public static final int NEW_TX
public static void raiseEvent(Event e)
e
- the eventpublic static long register(String name, Class<? extends IEventHandler> eh, Object context)
name
- the name of the eventeh
- the class of the eventhandler, must be a subclass of EventHandlercontext
- a context objectpublic static long register(String name, Class<? extends IEventHandler> eh, Object context, ActivityInstance registrant)
name
- the name of the eventeh
- the class of the eventhandler, must be a subclass of EventHandlercontext
- a context objectregistrant
- an activity of te registering process instance, or the process instance itselfpublic static void unregister(long oid)
public static void unregister(String name, ProcessInstance registrant)
name
- the event nameregistrant
- the process which registeredpublic static void unregisterAll(ProcessInstance registrant)
public static void unregisterAll(ActivityInstance registrant)
@enterprise 10.0.39049 Copyright © 2024 FREQUENTIS AG. All Rights Reserved.