jadex.bpmn.features.IInternalBpmnComponentFeature Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jadex-kernel-bpmn Show documentation
Show all versions of jadex-kernel-bpmn Show documentation
The Jadex BPMN kernel provides a workflow kernel for the standardized business process modeling notation. The kernel relies on annotated BPMN diagrams, which include detailed execution information.
package jadex.bpmn.features;
import java.util.List;
import jadex.bpmn.model.MActivity;
import jadex.bpmn.runtime.IActivityHandler;
import jadex.bpmn.runtime.ProcessThread;
import jadex.bridge.IConnection;
import jadex.bridge.IInternalAccess;
import jadex.bridge.service.types.monitoring.IMonitoringEvent;
/**
*
*/
public interface IInternalBpmnComponentFeature
{
/** Constant for step event. */
public static final String TYPE_ACTIVITY = "activity";
/** The change event prefix denoting a thread event. */
public static final String TYPE_THREAD = "thread";
/**
* Test if the given context variable is declared.
* @param name The variable name.
* @return True, if the variable is declared.
*/
public boolean hasContextVariable(String name);
/**
* Get the value of the given context variable.
* @param name The variable name.
* @return The variable value.
*/
public Object getContextVariable(String name);
/**
* Set the value of the given context variable.
* @param name The variable name.
* @param value The variable value.
*/
public void setContextVariable(String name, Object value);
/**
* Set the value of the given context variable.
* @param name The variable name.
* @param value The variable value.
*/
public void setContextVariable(String name, Object key, Object value);
/**
* Create a thread event (creation, modification, termination).
*/
public IMonitoringEvent createThreadEvent(String type, ProcessThread thread);
/**
* Create an activity event (start, end).
*/
public IMonitoringEvent createActivityEvent(String type, ProcessThread thread, MActivity activity);
/**
* Get the activity handler for an activity.
* @param actvity The activity.
* @return The activity handler.
*/
public IActivityHandler getActivityHandler(MActivity activity);
/**
* Get the top level thread (is not executed and just acts as top level thread container).
*/
public ProcessThread getTopLevelThread();
/**
* Make a process step, i.e. find the next edge or activity for a just executed thread.
* @param activity The activity to execute.
* @param instance The process instance.
* @param thread The process thread.
*/
public void step(MActivity activity, IInternalAccess instance, ProcessThread thread, Object event);
/**
* Method that should be called, when an activity is finished and the following activity should be scheduled.
* Can safely be called from external threads.
* @param activity The timing event activity.
* @param instance The process instance.
* @param thread The process thread.
* @param event The event that has occurred, if any.
*/
public void notify(final MActivity activity, final ProcessThread thread, final Object event);
/**
* Check if the process is ready, i.e. if at least one process thread can currently execute a step.
* @param pool The pool to be executed or null for any.
* @param lane The lane to be executed or null for any. Nested lanes may be addressed by dot-notation, e.g. 'OuterLane.InnerLane'.
*/
public boolean isReady();
/**
* Check if the process is ready, i.e. if at least one process thread can currently execute a step.
* @param pool The pool to be executed or null for any.
* @param lane The lane to be executed or null for any. Nested lanes may be addressed by dot-notation, e.g. 'OuterLane.InnerLane'.
*/
public boolean isReady(String pool, String lane);
/**
* Check, if the process has terminated.
* @param pool The pool to be executed or null for any.
* @param lane The lane to be executed or null for any. Nested lanes may be addressed by dot-notation, e.g. 'OuterLane.InnerLane'.
* @return True, when the process instance is finished with regards to the specified pool/lane. When both pool and lane are null, true is returned only when all pools/lanes are finished.
*/
public boolean isFinished();
/**
* Check, if the process has terminated.
* @param pool The pool to be executed or null for any.
* @param lane The lane to be executed or null for any. Nested lanes may be addressed by dot-notation, e.g. 'OuterLane.InnerLane'.
* @return True, when the process instance is finished with regards to the specified pool/lane. When both pool and lane are null, true is returned only when all pools/lanes are finished.
*/
public boolean isFinished(String pool, String lane);
/**
* Get the messages.
* @return The messages
*/
public List