org.yawlfoundation.yawl.engine.interfce.interfaceA
Interface InterfaceAManagement

All Known Implementing Classes:
YEngine

public interface InterfaceAManagement

Defines the 'A' interface into the YAWL Engine corresponding to WfMC interface 5 - Administration + Monitoring.

Author:
Andrew Hastie Creation Date: 10-Jun-2005

Method Summary
 boolean addExternalClient(YExternalClient client)
           
 List<YSpecificationID> addSpecifications(String specificationStr, boolean ignoreErors, List<YVerificationMessage> errorMessages)
          Loads a process specification into the engine from an XML definition file created by the YAWL Designer.
 void addYawlService(YAWLServiceReference yawlService)
          Loads a YAWL service into the engine.
 void cancelCase(YIdentifier id)
          Cancel the execution of a case.
 void dump()
          Invokes a diagnostic dump of the engine's internal tables.
 AnnouncementContext getAnnouncementContext()
           
 YAnnouncer getAnnouncer()
           
 YIdentifier getCaseID(String caseIDStr)
          Returns the internal engine identifier for a case.
 Set<YIdentifier> getCasesForSpecification(YSpecificationID specID)
          Given a process specification id return the cases that are its running instances.
 YEngine.Status getEngineStatus()
           
 YExternalClient getExternalClient(String name)
           
 YSpecification getLatestSpecification(String id)
          Returns the process specification identified by its ID.
 Set<YSpecificationID> getLoadedSpecificationIDs()
           
 String getLoadStatus(YSpecificationID specID)
          Indicates the load status of the supplied specification ID.
 YSpecification getProcessDefinition(YSpecificationID specID)
          Returns the specification for a loaded specification via the supplied specification ID.
 YAWLServiceReference getRegisteredYawlService(String yawlServiceID)
           
 YSpecification getSpecification(YSpecificationID specID)
           
 YSpecification getSpecificationForCase(YIdentifier caseID)
           
 String getStateForCase(YIdentifier caseID)
          Returns the state for a case.
 String getStateTextForCase(YIdentifier caseID)
          Returns the text description for the state that a case is currently in.
 Set getUsers()
          Returns a set of users currently loaded within the engine.
 boolean loadSpecification(YSpecification spec)
           
 int reannounceEnabledWorkItems()
          Causes the engine to re-announce all workitems which are in an "enabled" state.
 int reannounceExecutingWorkItems()
          Causes the engine to re-announce all workitems which are in an "executing" state.
 int reannounceFiredWorkItems()
          Causes the engine to re-announce all workitems which are in an "fired" state.
 void reannounceWorkItem(YWorkItem workItem)
          Causes the engine to re-announce a specific workitem regardless of state.
 void registerInterfaceAClient(InterfaceAManagementObserver observer)
          Register an InterfaceA management client with the engine in order to recieve callbacks.
 YAWLServiceReference removeYawlService(String serviceURI)
          Removes a YAWL service from the engine.
 void resumeCase(YIdentifier id)
          Resumes execution of a case.
 void setEngineStatus(YEngine.Status engineStatus)
           
 void storeObject(Object object)
          Stores an object within the engine's persistent storage area.
 void suspendCase(YIdentifier id)
          Returns a set of users currently loaded within the engine.
 void unloadSpecification(YSpecificationID specID)
          Unloads a specification from the engine.
 

Method Detail

registerInterfaceAClient

void registerInterfaceAClient(InterfaceAManagementObserver observer)
Register an InterfaceA management client with the engine in order to recieve callbacks.

Parameters:
observer -

addSpecifications

List<YSpecificationID> addSpecifications(String specificationStr,
                                         boolean ignoreErors,
                                         List<YVerificationMessage> errorMessages)
                                         throws org.jdom.JDOMException,
                                                IOException,
                                                YPersistenceException
Loads a process specification into the engine from an XML definition file created by the YAWL Designer.

Parameters:
specificationStr -
ignoreErors -
errorMessages -
Returns:
a list of specification ids for the specifications loaded
Throws:
org.jdom.JDOMException
IOException
YPersistenceException

loadSpecification

boolean loadSpecification(YSpecification spec)

getLoadedSpecificationIDs

Set<YSpecificationID> getLoadedSpecificationIDs()
                                                throws YPersistenceException
Throws:
YPersistenceException

getLatestSpecification

YSpecification getLatestSpecification(String id)
Returns the process specification identified by its ID.

The process must have been loaded into the engine either when it initialised (using persisted specifications held in the database), or specifications added during the lifetime of the current engine instance. Null is returned if the process ID requested is not found in the engines internal cache. Further, this returns the newest version of the specification running.

Parameters:
id -

getSpecification

YSpecification getSpecification(YSpecificationID specID)

getSpecificationForCase

YSpecification getSpecificationForCase(YIdentifier caseID)

unloadSpecification

void unloadSpecification(YSpecificationID specID)
                         throws YStateException,
                                YPersistenceException
Unloads a specification from the engine.

Parameters:
specID -
Throws:
YStateException
YPersistenceException

getCasesForSpecification

Set<YIdentifier> getCasesForSpecification(YSpecificationID specID)
Given a process specification id return the cases that are its running instances.

Parameters:
specID - the process specification id string.
Returns:
a set of YIdentifer caseIDs that are run time instances of the process specification with id = specID

getCaseID

YIdentifier getCaseID(String caseIDStr)
                      throws YPersistenceException
Returns the internal engine identifier for a case.

Parameters:
caseIDStr -
Returns:
the internal engine identifier for a case
Throws:
YPersistenceException

getStateTextForCase

String getStateTextForCase(YIdentifier caseID)
                           throws YPersistenceException
Returns the text description for the state that a case is currently in.

Parameters:
caseID -
Returns:
a text description of the current case state
Throws:
YPersistenceException

getStateForCase

String getStateForCase(YIdentifier caseID)
                       throws YPersistenceException
Returns the state for a case.

Parameters:
caseID -
Returns:
the current case state
Throws:
YPersistenceException

cancelCase

void cancelCase(YIdentifier id)
                throws YPersistenceException,
                       YEngineStateException
Cancel the execution of a case.

Parameters:
id -
Throws:
YPersistenceException
YEngineStateException

suspendCase

void suspendCase(YIdentifier id)
                 throws YPersistenceException,
                        YStateException
Returns a set of users currently loaded within the engine.

Suspends execution of a case.

Parameters:
id -
Throws:
YPersistenceException
YStateException

resumeCase

void resumeCase(YIdentifier id)
                throws YPersistenceException,
                       YStateException
Resumes execution of a case.

Parameters:
id -
Throws:
YPersistenceException
YStateException

getUsers

Set getUsers()
Returns a set of users currently loaded within the engine.


getExternalClient

YExternalClient getExternalClient(String name)

addExternalClient

boolean addExternalClient(YExternalClient client)
                          throws YPersistenceException
Throws:
YPersistenceException

getRegisteredYawlService

YAWLServiceReference getRegisteredYawlService(String yawlServiceID)

addYawlService

void addYawlService(YAWLServiceReference yawlService)
                    throws YPersistenceException
Loads a YAWL service into the engine.

Parameters:
yawlService -
Throws:
YPersistenceException

removeYawlService

YAWLServiceReference removeYawlService(String serviceURI)
                                       throws YPersistenceException
Removes a YAWL service from the engine.

Parameters:
serviceURI -
Returns:
the removed service
Throws:
YPersistenceException

getLoadStatus

String getLoadStatus(YSpecificationID specID)
Indicates the load status of the supplied specification ID.

Parameters:
specID -
Returns:
the current laod status for the specification with the id passed

reannounceEnabledWorkItems

int reannounceEnabledWorkItems()
                               throws YStateException
Causes the engine to re-announce all workitems which are in an "enabled" state.

Returns:
The number of enabled workitems that were reannounced
Throws:
YStateException

reannounceExecutingWorkItems

int reannounceExecutingWorkItems()
                                 throws YStateException
Causes the engine to re-announce all workitems which are in an "executing" state.

Returns:
The number of executing workitems that were reannounced
Throws:
YStateException

reannounceFiredWorkItems

int reannounceFiredWorkItems()
                             throws YStateException
Causes the engine to re-announce all workitems which are in an "fired" state.

Returns:
The number of fired workitems that were reannounced
Throws:
YStateException

reannounceWorkItem

void reannounceWorkItem(YWorkItem workItem)
                        throws YStateException
Causes the engine to re-announce a specific workitem regardless of state.

Note: This interface current;y only supported workitems in the following states:

  • Enabled
  • Executing
  • Fired

    Throws:
    YStateException

  • getProcessDefinition

    YSpecification getProcessDefinition(YSpecificationID specID)
    Returns the specification for a loaded specification via the supplied specification ID.

    Parameters:
    specID -
    Returns:
    the specification matching the id

    storeObject

    void storeObject(Object object)
                     throws YPersistenceException
    Stores an object within the engine's persistent storage area.

    Parameters:
    object -
    Throws:
    YPersistenceException

    dump

    void dump()
    Invokes a diagnostic dump of the engine's internal tables.


    setEngineStatus

    void setEngineStatus(YEngine.Status engineStatus)

    getEngineStatus

    YEngine.Status getEngineStatus()

    getAnnouncementContext

    AnnouncementContext getAnnouncementContext()

    getAnnouncer

    YAnnouncer getAnnouncer()


    Copyright © 2004-2012 The YAWL Foundation.