org.apache.agila.model
Interface Node

All Known Implementing Classes:
AndJoinNode, BaseNodeImpl, DelayNode, ForkNode, HelloWorldActivity, LeaveApplicationTask, LeaveApprovalTask, SimpleDecision, StartNode, StopNode, TestNotification, TestTaskNode

public interface Node

Interface representing a node in a workflow graph. Nodes are required to be stateless and reentrant, as a given node in a graph will be shared by mutliple execution instances.

Version:
$Id: $
Author:
Geir Magnusson Jr.

Method Summary
 void addActor(Actor actor)
           
 void addBinding(Binding binding)
           
 void addInboundConnection(Connection conn)
           
 void addOutboundConnection(Connection conn)
           
 Connection[] doEnd(NodeContext ctx)
          Second 'work method' for a node, called after doStart().
 boolean doStart(NodeContext ctx)
          First 'work method' for a node.
 Actor[] getActors()
           
 java.util.Map getBindings()
           
 java.lang.String getDisplayName()
           
 Connection[] getInboundConnections()
           
 NodeID getNodeId()
           
 Connection[] getOutboundConnections()
           
 void setDisplayName(java.lang.String name)
           
 void setInboundConnections(Connection[] list)
           
 void setNodeId(NodeID id)
           
 void setOutboundConnections(Connection[] list)
           
 

Method Detail

doStart

boolean doStart(NodeContext ctx)
First 'work method' for a node. This is called upon entry of a token from a connection. This method should do any work needed, such as assigning a task, etc. The method returns true if processing is to immediately continue, or false if processing should stop and an external action, such as a timer or a completed task by a human, will continue the execution.

Parameters:
ctx - execution context for this node
Returns:
true if MessageProcess automatically continues exection of the instance, or false if not

doEnd

Connection[] doEnd(NodeContext ctx)
Second 'work method' for a node, called after doStart(). This method should do any post action (task, timer, etc) cleanup and then make a decision among the possible connections which connection (or connections, in the case of a node that forks) should be transversed.

Parameters:
ctx -
Returns:
one or more connections to transverse, or null if processing for this instance should stop

setInboundConnections

void setInboundConnections(Connection[] list)

setOutboundConnections

void setOutboundConnections(Connection[] list)

addOutboundConnection

void addOutboundConnection(Connection conn)

addInboundConnection

void addInboundConnection(Connection conn)

getInboundConnections

Connection[] getInboundConnections()

getOutboundConnections

Connection[] getOutboundConnections()

setNodeId

void setNodeId(NodeID id)

getNodeId

NodeID getNodeId()

getDisplayName

java.lang.String getDisplayName()

setDisplayName

void setDisplayName(java.lang.String name)

addActor

void addActor(Actor actor)

getActors

Actor[] getActors()

addBinding

void addBinding(Binding binding)

getBindings

java.util.Map getBindings()


Copyright © 2004-2005 The Apache Software Foundation. All Rights Reserved.