org.yawlfoundation.yawl.worklet.support
Class WorkletEventServer

java.lang.Object
  extended by org.yawlfoundation.yawl.engine.interfce.Interface_Client
      extended by org.yawlfoundation.yawl.worklet.support.WorkletEventServer

public class WorkletEventServer
extends Interface_Client

Announces worklet service events to registered listeners Author: Michael Adams Creation Date: 12/12/2012


Nested Class Summary
static class WorkletEventServer.Event
           
 
Constructor Summary
WorkletEventServer()
          Constructs a new event server
 
Method Summary
 String addListener(String uri)
          Adds a listener to the set of registered listeners
 void announceConstraintPass(String caseID, org.jdom.Element caseData, RuleType rType)
          Announces a case-level exception
 void announceConstraintPass(WorkItemRecord wir, org.jdom.Element caseData, RuleType rType)
          Announces an item-level exception
 void announceException(String caseID, org.jdom.Element caseData, RdrNode node, RuleType rType)
          Announces a case-level exception
 void announceException(WorkItemRecord wir, org.jdom.Element caseData, RdrNode node, RuleType rType)
          Announces an item-level exception
 void announceSelection(CheckedOutChildItem item, RdrNode node)
          Announces a worklet selection
 boolean hasListeners()
           
 String removeListener(String uri)
          Removes a listener to the set of registered listeners
 void shutdownListeners()
          Announces the worklet service is shutting down
 
Methods inherited from class org.yawlfoundation.yawl.engine.interfce.Interface_Client
executeGet, executePost, prepareParamMap, setReadTimeout, stripOuterElement, successful
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WorkletEventServer

public WorkletEventServer()
Constructs a new event server

Method Detail

hasListeners

public boolean hasListeners()
Returns:
true if the server has at least one registered listener

addListener

public String addListener(String uri)
Adds a listener to the set of registered listeners

Parameters:
uri - the URI of the listener to add
Returns:
a message describing success or error

removeListener

public String removeListener(String uri)
Removes a listener to the set of registered listeners

Parameters:
uri - the URI of the listener to remove
Returns:
a message describing success or error

announceException

public void announceException(String caseID,
                              org.jdom.Element caseData,
                              RdrNode node,
                              RuleType rType)
Announces a case-level exception

Parameters:
caseID - the id of the case on which the exception was raised
caseData - the current case data used to evaluate the exception
node - the node that evaluated to true
rType - the type of exception raised

announceException

public void announceException(WorkItemRecord wir,
                              org.jdom.Element caseData,
                              RdrNode node,
                              RuleType rType)
Announces an item-level exception

Parameters:
wir - the workitem on which the exception was raised
caseData - the current case data used to evaluate the exception
node - the node that evaluated to true
rType - the type of exception raised

announceConstraintPass

public void announceConstraintPass(String caseID,
                                   org.jdom.Element caseData,
                                   RuleType rType)
Announces a case-level exception

Parameters:
caseID - the id of the case on which the exception was raised
caseData - the current case data used to evaluate the exception
rType - the type of exception raised

announceConstraintPass

public void announceConstraintPass(WorkItemRecord wir,
                                   org.jdom.Element caseData,
                                   RuleType rType)
Announces an item-level exception

Parameters:
wir - the workitem on which the exception was raised
caseData - the current case data used to evaluate the exception
rType - the type of exception raised

announceSelection

public void announceSelection(CheckedOutChildItem item,
                              RdrNode node)
Announces a worklet selection

Parameters:
item - a descriptor containing case, workitem, data and raised worklet info

shutdownListeners

public void shutdownListeners()
Announces the worklet service is shutting down



Copyright © 2004-2012 The YAWL Foundation.