public class CustomTaskChangeHandler extends Object implements ITaskChangedEvent.IListener, com.webmethods.portal.event.IPortalEvent.IListener, com.webmethods.portal.system.init.IInitializable
Modifier and Type | Class and Description |
---|---|
static interface |
CustomTaskChangeHandler.ICustomTaskEventSubscriber
Interface to be implemented for listening to TaskChangeEvents using a custom listener.
|
Modifier and Type | Field and Description |
---|---|
static String |
CUSTOM_TASK_CHANGED_EVENTS_QUEUEID |
static String |
TASK_LWQ_CONFIG |
static boolean |
TASK_RETRY_LOOKUP_PRINCIPAL |
static long |
TASK_RETRY_LOOKUP_PRINCIPAL_TIMEOUT |
Constructor and Description |
---|
CustomTaskChangeHandler(com.webmethods.portal.mech.task.impl.TaskMechanics taskMechanics) |
Modifier and Type | Method and Description |
---|---|
static void |
addSubscriber(CustomTaskChangeHandler.ICustomTaskEventSubscriber subscriber)
A custom subscriber must be added here first in order to receive events.
|
static CustomTaskChangeHandler.ICustomTaskEventSubscriber[] |
getSubscribers()
Returns all the active custom subscribers receiving the TaskChangeEvents.
|
void |
init(com.webmethods.portal.system.IComponentData data,
String phase)
This component should initialize now.
|
void |
onEvent(com.webmethods.portal.event.IPortalEvent ev) |
void |
onEvent(ITaskChangedEvent event) |
void |
processTaskChangedEvent(ITaskChangedEvent event) |
void |
queueTaskChangeEvent(ITaskChangedEvent event) |
static void |
removeSubscriber(CustomTaskChangeHandler.ICustomTaskEventSubscriber subscriber)
An added custom subscriber can be removed using this method.
|
void |
shutdown()
This object is being uninitialized.
|
public static final String CUSTOM_TASK_CHANGED_EVENTS_QUEUEID
public static final String TASK_LWQ_CONFIG
public static final boolean TASK_RETRY_LOOKUP_PRINCIPAL
public static final long TASK_RETRY_LOOKUP_PRINCIPAL_TIMEOUT
public CustomTaskChangeHandler(com.webmethods.portal.mech.task.impl.TaskMechanics taskMechanics)
public void queueTaskChangeEvent(ITaskChangedEvent event)
public void init(com.webmethods.portal.system.IComponentData data, String phase) throws com.webmethods.portal.system.init.InitializationException
IComponentProvider
then it should
initialize all of its IComponent
s.init
in interface com.webmethods.portal.system.init.IInitializable
phase
- the name of the current phasedata
- the IComponentDatacom.webmethods.portal.system.init.InitializationException
InitializationException.RECOVERABLE_ERROR
,
InitializationException.NON_RECOVERABLE_ERROR
public void shutdown()
shutdown
in interface com.webmethods.portal.system.init.IInitializable
IInitializable.shutdown()
public void onEvent(com.webmethods.portal.event.IPortalEvent ev)
onEvent
in interface com.webmethods.portal.event.IPortalEvent.IListener
public void onEvent(ITaskChangedEvent event)
onEvent
in interface ITaskChangedEvent.IListener
public void processTaskChangedEvent(ITaskChangedEvent event)
public static void addSubscriber(CustomTaskChangeHandler.ICustomTaskEventSubscriber subscriber)
subscriber
- an instance of ICustomTaskEventSubscriber.public static void removeSubscriber(CustomTaskChangeHandler.ICustomTaskEventSubscriber subscriber)
subscriber
- an instance of ICustomTaskEventSubscriber.public static CustomTaskChangeHandler.ICustomTaskEventSubscriber[] getSubscribers()