org.concord.pedagogica.engine
Class ActivityNode

java.lang.Object
  |
  +--org.concord.pedagogica.engine.ActivityScript
        |
        +--org.concord.pedagogica.engine.ActivityNode
All Implemented Interfaces:
java.lang.Runnable, ScriptError
Direct Known Subclasses:
Activity

public class ActivityNode
extends ActivityScript

The ActivityNode is the state object of the state machine controlled by the Activity object. Each Activity node has its own script that implements an "enter" method and an "exit" method. Each Activity node also has a list of variables that contain the stae of the node. It is these variables that are operated on by both the node script and the arc scripts.


Field Summary
protected  int enterCount
           
protected  java.util.Vector inArcs
           
protected  java.lang.Thread initializer
           
protected  java.lang.String nodeName
           
protected  ScriptThread nodeThread
           
protected  java.util.Vector outArcs
           
protected  java.util.Vector questions
           
protected  java.util.Stack returnNode
           
 
Fields inherited from class org.concord.pedagogica.engine.ActivityScript
errorHandler, ext, lastError, name, nodeAccess, parent, root, runtime, script, scriptFile, scriptText, scriptThread, scriptType, state, synchronizer, textSelection, tryName, viewText
 
Constructor Summary
ActivityNode()
           
ActivityNode(Activity parent)
           
 
Method Summary
 void addQuestion(QuestionForm question)
           
 boolean back()
           
 void delete()
           
 void done()
           
 void enter()
           
 void exit()
           
 int getEnterCount()
           
 java.lang.Object getViewObject(java.lang.String objectName)
           
 boolean isActivity()
           
 boolean next()
           
 ActivityNode popReturnNode()
           
 void pushReturnNode(ActivityNode node)
           
 void removeQuestion(QuestionForm question)
           
 void setEnterCount(int count)
           
 void setStartNode()
           
 boolean test()
           
 
Methods inherited from class org.concord.pedagogica.engine.ActivityScript
addStateVariable, clearLastError, getLastError, getLevel, getLogging, getName, getNodeAccess, getParent, getPath, getRoot, getScript, getScriptType, getState, getText, getTextSelection, getViewText, initialize, load, load, parseError, readText, removeStateVariable, run, runError, setErrorHandler, setLastError, setName, setNodeAccess, setScriptType, setText, setText, setViewText, showError, startEventProcessing, stopEventProcessing, writeText
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

inArcs

protected java.util.Vector inArcs

outArcs

protected java.util.Vector outArcs

nodeName

protected java.lang.String nodeName

nodeThread

protected ScriptThread nodeThread

returnNode

protected java.util.Stack returnNode

initializer

protected java.lang.Thread initializer

enterCount

protected int enterCount

questions

protected java.util.Vector questions
Constructor Detail

ActivityNode

public ActivityNode()

ActivityNode

public ActivityNode(Activity parent)
Method Detail

delete

public void delete()
Overrides:
delete in class ActivityScript

isActivity

public boolean isActivity()

setStartNode

public void setStartNode()

pushReturnNode

public void pushReturnNode(ActivityNode node)

popReturnNode

public ActivityNode popReturnNode()

addQuestion

public void addQuestion(QuestionForm question)

removeQuestion

public void removeQuestion(QuestionForm question)

getViewObject

public java.lang.Object getViewObject(java.lang.String objectName)

getEnterCount

public int getEnterCount()

setEnterCount

public void setEnterCount(int count)

test

public boolean test()

next

public boolean next()

back

public boolean back()

enter

public void enter()

exit

public void exit()

done

public void done()