org.primordion.xholon.app
Class Application

java.lang.Object
  extended byorg.primordion.xholon.base.Xholon
      extended byorg.primordion.xholon.app.Application
All Implemented Interfaces:
IApplication, IXholon
Direct Known Subclasses:
App__XholonTemplate__, App09SpatialGames, App1dSimple, AppAntForaging, AppAntTrail, AppBraneCalc, AppBrenda, AppCartCentering, AppCell, AppCellAutop, AppCollisions, AppCombo, AppCtrnn, AppEcj, AppElevator, AppElevator, AppElevator_ShowStates, AppEpo2, AppFibonacci, AppFsm06ex1_Fsm, AppFsm06ex1_Fsm, AppGameOfLife, AppGeneric, AppGravity1, AppHelloWorld, AppHelloWorld_NoXml, AppHelloWorld_TestTime, AppHelloWorld_Vrml, AppHelloWorldTutorial, AppHelloWorldTutorial, AppHelloWorldTutorial, AppHelloWorldTutorial_multiWorld, AppHelloWorldTutorial_multiWorld, AppHelloWorldTutorial_plus, AppHelloWorldTutorial_universe, AppHelloWorldTutorialSysML, AppHex, AppInterest, AppLife, AppMemComp, AppPingPong, AppProvidedRequiredTest, AppRcs_GP_FSM, AppRcs_GP_FSM_Grid, AppRcs_GP_MM, AppRcs_GP_MM_NoSymbols, AppRcs1, AppRcs2, AppSbml, AppStateMachineOnly, AppStopWatch, AppStopWatch_Xhym, AppStupidModel1, AppStupidModel10, AppStupidModel11, AppStupidModel12, AppStupidModel13, AppStupidModel14, AppStupidModel15, AppStupidModel16, AppStupidModel16nl, AppStupidModel2, AppStupidModel3, AppStupidModel4, AppStupidModel5, AppStupidModel5tg, AppStupidModel6, AppStupidModel7, AppStupidModel8, AppStupidModel9, AppTestFsm, AppTestFsm, AppTestFsm, AppTestFsmForkJoin, AppTestFsmHistory, AppTestFsmJunction, AppTestFsmKW, AppTestFsmOrthog, AppTestFsmOrthogKW, AppTestFsmOrthogonal, AppTrain, AppTurtleExample1, AppTutorial4, AppWatch, AppWatch, AppWolfSheepGrass

public abstract class Application
extends Xholon
implements IApplication

This is an abstract class from which all Xholon applications should subclass.

Since:
0.1 (Created on October 13, 2005)
Author:
Ken Webb

Nested Class Summary
 class Application.GridViewerDetails
          An inner class that contains all data required for the viewing of a grid.
 
Field Summary
 
Fields inherited from class org.primordion.xholon.base.Xholon
DEFAULT_LEVEL, interaction, interactionsEnabled
 
Fields inherited from interface org.primordion.xholon.base.IXholon
DEFAULT_SIZE_MSG_Q, NINCLUDE_PSC, NINCLUDE_PSx, NINCLUDE_PxC, NINCLUDE_Pxx, NINCLUDE_xSC, NINCLUDE_xSx, NINCLUDE_xxC, NINCLUDE_xxx
 
Constructor Summary
Application()
          Constructor.
 
Method Summary
 void about()
          Display brief information about Xholon and the application.
static void appMain(java.lang.String[] args, java.lang.String className, java.lang.String defaultConfigFileName)
          Perform most or all of the work required of main() in an Application subclass.
static IApplication getApplication(IXholon xhNode)
          Get the instance of Application that the Xholon node is part of.
 boolean getAppM()
           
 Control getAppRoot()
          Get the application root.
 java.lang.Class getClass(java.lang.String className)
          Return the class given the class name.
 java.lang.String getClassDetailsFile()
           
 java.lang.String getCompositeStructureHierarchyFile()
           
 int getControllerState()
          Get state of the controller.
 java.lang.String getDataPlotterParams()
           
 boolean getErrorM()
           
 java.lang.String getGraphicalNetworkViewerClassName()
          graphicalNetworkViewerClassName
 java.lang.String getGraphicalNetworkViewerParams()
          graphicalNetworkViewerParams
 java.lang.String getGraphicalTreeViewerParams()
           
 java.lang.String getGridPanelClassName()
           
 java.lang.String getHistogramPlotterParams()
           
 boolean getInfoM()
           
 java.lang.String getInformationFile()
           
 java.lang.String getInheritanceHierarchyFile()
           
 java.lang.String getInteractionParams()
           
 java.lang.String getJavaActivityClassName()
           
 java.lang.String getJavaClassName()
           
 java.lang.String getJavaXhClassClassName()
           
 java.lang.String getJavaXhClassName()
           
 int getMaxActivities()
           
 int getMaxPorts()
           
 int getMaxProcessLoops()
           
 int getMaxStateMachineEntities()
           
 int getMaxXholonClasses()
           
 int getMaxXholons()
           
 java.lang.String getModelName()
          Get the model name.
 long getRandomNumberSeed()
           
 IXholon getRoot()
          Get the model root.
 boolean getSaveSnapshots()
           
 int getSizeMessageQueue()
           
 java.lang.String getSnapshotParams()
           
 int getTimeStepInterval()
           
 boolean getTreeNodeFactoryDynamic()
           
 boolean getUseDataPlotter()
           
 boolean getUseGnuplot_Hist()
           
 boolean getUseGnuplot()
           
 boolean getUseGraphicalNetworkViewer()
           
 boolean getUseGraphicalTreeViewer()
           
 boolean getUseGridViewer()
           
 boolean getUseHistogramPlotter()
           
 boolean getUseInteractions()
           
 boolean getUseJFreeChart_Hist()
           
 boolean getUseJFreeChart()
           
 boolean getUseTextTree()
           
 boolean getUseVrml()
           
 java.lang.String getVrmlParams()
           
 java.lang.String getVrmlWriterClassName()
           
 java.lang.String getXhymAgent()
          xhymAgent
 java.lang.String getXincludePath()
           
 void information()
          Display detailed information about the application.
 void initControl()
          Initialize the control aspects of the application.
 void initGui(java.lang.Object gui)
          Initialize the GUI.
 void initialize(java.lang.String configFileName)
          Initialize the application.
 void initViewers()
          Initialize any View tools to be used by the application.
 IViewer invokeDataPlotter()
          Invoke the data plotter.
 IViewer invokeGraphicalNetworkViewer()
          Invoke the graphical network viewer.
 IViewer invokeGraphicalNetworkViewer(IXholon xhStart, java.lang.String graphicalNetworkViewerParams)
          Invoke the graphical network viewer.
 IViewer invokeGraphicalTreeViewer()
          Invoke the graphical tree viewer.
 IViewer invokeGraphicalTreeViewer(IXholon xhStart, java.lang.String graphicalNetworkViewerParams)
          Invoke the graphical tree viewer.
 IViewer invokeHistogramPlotter()
          Invoke the histogram plotter.
 IViewer invokeInteraction()
          Invoke the interaction viewer.
 void process()
          Process time steps during the lifetime of the application.
 void readConfigFromFileXml(java.lang.String fileName)
          Read configuration values from an XML file.
 void resetViewers()
          Reset all viewers to their default values.
 void saveSnapshot()
          Save snapshot of xholon tree.
static void setApplication(IApplication app)
          Set an instance of IApplication.
 void setAppM(boolean appM)
           
 void setClassDetailsFile(java.lang.String classDetailsFile)
           
 void setCompositeStructureHierarchyFile(java.lang.String compositeStructureHierarchyFile)
           
 void setControllerState(int controllerState)
          Set state of the controller for this app.
 void setDataPlotterParams(java.lang.String dataPlotterParams)
          dataPlotterParams
 void setErrorM(boolean errorM)
           
 void setGraphicalNetworkViewerClassName(java.lang.String graphicalNetworkViewerClassName)
          graphicalNetworkViewerClassName
 void setGraphicalNetworkViewerParams(java.lang.String graphicalNetworkViewerParams)
           
 void setGraphicalTreeViewerParams(java.lang.String graphicalTreeViewerParams)
           
 void setGridPanelClassName(java.lang.String gridPanelClassName)
           
 void setGridViewerParams(java.lang.String gridViewerParams)
           
 void setHistogramPlotterParams(java.lang.String histogramPlotterParams)
          histogramPlotterParams
 void setInfoM(boolean infoM)
           
 void setInformationFile(java.lang.String informationFile)
           
 void setInheritanceHierarchyFile(java.lang.String inheritanceHierarchyFile)
           
 void setInteractionParams(java.lang.String interactionParams)
           
 void setJavaActivityClassName(java.lang.String javaActivityClassName)
           
 void setJavaClassName(java.lang.String javaClassName)
           
 void setJavaXhClassClassName(java.lang.String javaXhClassClassName)
           
 void setJavaXhClassName(java.lang.String javaXhClassName)
           
 void setMaxActivities(int maxActivities)
           
 void setMaxPorts(int maxPorts)
          maxPorts
 void setMaxProcessLoops(int maxProcessLoops)
           
 void setMaxStateMachineEntities(int maxStateMachineEntities)
           
 void setMaxXholonClasses(int maxXholonClasses)
           
 void setMaxXholons(int maxXholons)
           
 void setModelName(java.lang.String modelName)
          modelName The modelName to set.
 boolean setParam(java.lang.String pName, java.lang.String pValue)
          Set the value of a parameter.
 void setRandomNumberSeed(long randomNumberSeed)
          randomNumberSeed
 void setSaveSnapshots(boolean saveSnapshots)
           
 void setSizeMessageQueue(int sizeMessageQueue)
          sizeMessageQueue Set the size of the message queue.
 void setSnapshotParams(java.lang.String snapshotParams)
           
 void setTimeStepInterval(int timeStepInterval)
           
 void setTreeNodeFactoryDynamic(boolean treeNodeFactoryDynamic)
          treeNodeFactoryDynamic
 void setUseDataPlotter(java.lang.String useDataPlotter)
           
 void setUseGraphicalNetworkViewer(boolean useGraphicalNetworkViewer)
           
 void setUseGraphicalTreeViewer(boolean useGraphicalTreeViewer)
           
 void setUseGridViewer(boolean useGridViewer)
           
 void setUseHistogramPlotter(java.lang.String useHistogramPlotter)
           
 void setUseInteractions(boolean useInteractions)
           
 void setUseTextTree(boolean useTextTree)
           
 void setUseVrml(boolean useVrml)
           
 void setVrmlParams(java.lang.String vrmlParams)
           
 void setVrmlWriterClassName(java.lang.String vrmlWriterClassName)
           
 void setXhymAgent(java.lang.String xhymAgent)
          xhymAgent
static void setXincludePath(java.lang.String xincludePath)
          xincludePath
 void wrapup()
          Wrapup any unfinished business in the application.
 
Methods inherited from class org.primordion.xholon.base.Xholon
act, appendChild, appendChild, appendChild, cleanup, configure, configure, createStructure, decVal, decVal, depth, draw, getChildNodes, getFirstChild, getFirstSibling, getId, getLastChild, getLastSibling, getName, getNeighbors, getNextId, getNextSibling, getNthChild, getNthSibling, getNumChildren, getNumSiblings, getParentNode, getPort, getPreviousSibling, getRoleName, getRootNode, getSiblings, getSizeMessageQ, getUid, getVal_boolean, getVal_byte, getVal_char, getVal_double, getVal_float, getVal_int, getVal_long, getVal_Object, getVal_short, getVal_String, getVal, getXhc, getXhcId, getXhcName, getXhType, handleNodeSelection, hasAncestor, hasChildNodes, hasChildOrSiblingNodes, hasNextSibling, hasParentNode, height, incVal, incVal, initialize, initStatics, inOrderPrint, insertAfter, insertBefore, insertFirstChild, isActiveObject, isBound, isContainer, isExternal, isInternal, isLeaf, isPassiveObject, isRootNode, performActivity, performActivity, performBooleanActivity, performBooleanActivity, performDoubleActivity, performGuard, performVoidActivity, postAct, postConfigure, postOrderPrint, postReconfigure, preAct, preConfigure, preOrderPrint, preReconfigure, print, println, processMessageQ, processReceivedMessage, reconfigure, remove, removeChild, resetNextId, sendMessage, sendMessage, sendMessage, setAttributeVal, setFactory, setFirstChild, setId, setNextSibling, setParentChildLinks, setParentNode, setParentSiblingLinks, setPorts, setRoleName, setSizeMessageQ, setUid, setVal, setVal, setVal, setVal, setVal, setVal, setVal, setVal, setVal, setVal, setVariableValue, setXhc, swapNode, terminate, toString, treeSize, writeXml
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.primordion.xholon.base.IXholon
act, appendChild, appendChild, appendChild, cleanup, configure, configure, createStructure, decVal, decVal, depth, draw, getChildNodes, getFirstChild, getFirstSibling, getId, getLastChild, getLastSibling, getName, getNeighbors, getNextSibling, getNthChild, getNthSibling, getNumChildren, getNumSiblings, getParentNode, getPort, getPreviousSibling, getRoleName, getRootNode, getSiblings, getUid, getVal_boolean, getVal_byte, getVal_char, getVal_double, getVal_float, getVal_int, getVal_long, getVal_Object, getVal_short, getVal_String, getVal, getXhc, getXhcId, getXhcName, getXhType, handleNodeSelection, hasAncestor, hasChildNodes, hasChildOrSiblingNodes, hasNextSibling, hasParentNode, height, incVal, incVal, initialize, initStatics, inOrderPrint, insertAfter, insertBefore, insertFirstChild, isActiveObject, isBound, isContainer, isExternal, isInternal, isLeaf, isPassiveObject, isRootNode, performActivity, performActivity, performBooleanActivity, performBooleanActivity, performDoubleActivity, performGuard, performVoidActivity, postAct, postConfigure, postOrderPrint, postReconfigure, preAct, preConfigure, preOrderPrint, preReconfigure, print, println, processMessageQ, processReceivedMessage, reconfigure, remove, removeChild, sendMessage, sendMessage, sendMessage, setAttributeVal, setFirstChild, setId, setNextSibling, setParentChildLinks, setParentNode, setParentSiblingLinks, setPorts, setRoleName, setUid, setVal, setVal, setVal, setVal, setVal, setVal, setVal, setVal, setVal, setVal, setVariableValue, setXhc, swapNode, terminate, treeSize, writeXml
 

Constructor Detail

Application

public Application()
Constructor.

Method Detail

setClassDetailsFile

public void setClassDetailsFile(java.lang.String classDetailsFile)
Parameters:
classDetailsFile - The classDetailsFile to set.

setCompositeStructureHierarchyFile

public void setCompositeStructureHierarchyFile(java.lang.String compositeStructureHierarchyFile)
Parameters:
compositeStructureHierarchyFile - The compositeStructureHierarchyFile to set.

setInheritanceHierarchyFile

public void setInheritanceHierarchyFile(java.lang.String inheritanceHierarchyFile)
Parameters:
inheritanceHierarchyFile - The inheritanceHierarchyFile to set.

setInformationFile

public void setInformationFile(java.lang.String informationFile)
Parameters:
informationFile - The informationFile to set.

setMaxProcessLoops

public void setMaxProcessLoops(int maxProcessLoops)
Parameters:
maxProcessLoops - The maxProcessLoops to set.

setTimeStepInterval

public void setTimeStepInterval(int timeStepInterval)
Parameters:
timeStepInterval - The timeStepInterval to set.

setMaxStateMachineEntities

public void setMaxStateMachineEntities(int maxStateMachineEntities)
Parameters:
maxStateMachineEntities - The maxStateMachineEntities to set.

setMaxActivities

public void setMaxActivities(int maxActivities)
Parameters:
maxActivities - The maxActivities to set.

setMaxXholonClasses

public void setMaxXholonClasses(int maxXholonClasses)
Parameters:
maxXholonClasses - The maxXholonClasses to set.

setMaxXholons

public void setMaxXholons(int maxXholons)
Parameters:
maxXholons - The maxXholons to set.

setAppM

public void setAppM(boolean appM)
Parameters:
appM - The appM to set.

setInfoM

public void setInfoM(boolean infoM)
Parameters:
infoM - The infoM to set.

setErrorM

public void setErrorM(boolean errorM)
Parameters:
errorM - The errorM to set.

setUseTextTree

public void setUseTextTree(boolean useTextTree)
Parameters:
useTextTree - The useTextTree to set.

setUseGraphicalTreeViewer

public void setUseGraphicalTreeViewer(boolean useGraphicalTreeViewer)
Parameters:
useGraphicalTreeViewer - The useGraphicalTreeViewer to set.

setGraphicalTreeViewerParams

public void setGraphicalTreeViewerParams(java.lang.String graphicalTreeViewerParams)

setUseGraphicalNetworkViewer

public void setUseGraphicalNetworkViewer(boolean useGraphicalNetworkViewer)
Parameters:
useGraphicalNetworkViewer - The useGraphicalNetworkViewer to set.

setGraphicalNetworkViewerClassName

public void setGraphicalNetworkViewerClassName(java.lang.String graphicalNetworkViewerClassName)
graphicalNetworkViewerClassName


setGraphicalNetworkViewerParams

public void setGraphicalNetworkViewerParams(java.lang.String graphicalNetworkViewerParams)

setUseGridViewer

public void setUseGridViewer(boolean useGridViewer)
Parameters:
useGridViewer - The useGridViewer to set.

setGridPanelClassName

public void setGridPanelClassName(java.lang.String gridPanelClassName)
Parameters:
gridPanelClassName - The name of the GridViewer Panel Java class.

setGridViewerParams

public void setGridViewerParams(java.lang.String gridViewerParams)
Parameters:
gridViewerParams - GridViewer parameters.

setUseDataPlotter

public void setUseDataPlotter(java.lang.String useDataPlotter)
Parameters:
useDataPlotter - The useDataPlotter to set.

setDataPlotterParams

public void setDataPlotterParams(java.lang.String dataPlotterParams)
dataPlotterParams


setUseHistogramPlotter

public void setUseHistogramPlotter(java.lang.String useHistogramPlotter)
Parameters:
useHistogramPlotter - The useHistogramPlotter to set.

setHistogramPlotterParams

public void setHistogramPlotterParams(java.lang.String histogramPlotterParams)
histogramPlotterParams


setUseInteractions

public void setUseInteractions(boolean useInteractions)
Parameters:
useInteractions - The useInteractions to set.

setInteractionParams

public void setInteractionParams(java.lang.String interactionParams)
Parameters:
interactionParams -

setUseVrml

public void setUseVrml(boolean useVrml)
Parameters:
useVrml - The useVrml to set.

setVrmlWriterClassName

public void setVrmlWriterClassName(java.lang.String vrmlWriterClassName)
Parameters:
vrmlWriterClassName -

setVrmlParams

public void setVrmlParams(java.lang.String vrmlParams)
Parameters:
vrmlParams -

setJavaClassName

public void setJavaClassName(java.lang.String javaClassName)
Parameters:
javaClassName - The javaClassName to set.

setJavaXhClassName

public void setJavaXhClassName(java.lang.String javaXhClassName)
Parameters:
javaXhClassName - The javaXhClassName to set.

setJavaXhClassClassName

public void setJavaXhClassClassName(java.lang.String javaXhClassClassName)
Parameters:
javaXhClassClassName - The javaXhClassClassName to set.

setJavaActivityClassName

public void setJavaActivityClassName(java.lang.String javaActivityClassName)
Parameters:
javaActivityClassName -

setSaveSnapshots

public void setSaveSnapshots(boolean saveSnapshots)
Parameters:
saveSnapshots - The saveSnapshots to set.

setSnapshotParams

public void setSnapshotParams(java.lang.String snapshotParams)
Parameters:
snapshotParams -

setModelName

public void setModelName(java.lang.String modelName)
modelName The modelName to set.


setSizeMessageQueue

public void setSizeMessageQueue(int sizeMessageQueue)
sizeMessageQueue Set the size of the message queue.


setTreeNodeFactoryDynamic

public void setTreeNodeFactoryDynamic(boolean treeNodeFactoryDynamic)
treeNodeFactoryDynamic


setRandomNumberSeed

public void setRandomNumberSeed(long randomNumberSeed)
randomNumberSeed


setMaxPorts

public void setMaxPorts(int maxPorts)
maxPorts


setXincludePath

public static void setXincludePath(java.lang.String xincludePath)
xincludePath


setXhymAgent

public void setXhymAgent(java.lang.String xhymAgent)
xhymAgent


getClassDetailsFile

public java.lang.String getClassDetailsFile()
Returns:
Returns the classDetailsFile.

getCompositeStructureHierarchyFile

public java.lang.String getCompositeStructureHierarchyFile()
Returns:
Returns the compositeStructureHierarchyFile.

getInheritanceHierarchyFile

public java.lang.String getInheritanceHierarchyFile()
Returns:
Returns the inheritanceHierarchyFile.

getInformationFile

public java.lang.String getInformationFile()
Returns:
Returns the informationFile.

getMaxProcessLoops

public int getMaxProcessLoops()
Returns:
Returns the maxProcessLoops.

getTimeStepInterval

public int getTimeStepInterval()
Returns:
Returns the timeStepInterval.

getMaxStateMachineEntities

public int getMaxStateMachineEntities()
Returns:
Returns the maxStateMachineEntities.

getMaxActivities

public int getMaxActivities()
Returns:
Returns the maxActivities.

getMaxXholonClasses

public int getMaxXholonClasses()
Returns:
Returns the maxXholonClasses.

getMaxXholons

public int getMaxXholons()
Returns:
Returns the maxXholons.

getAppM

public boolean getAppM()
Returns:
Returns the appM.

getInfoM

public boolean getInfoM()
Returns:
Returns the infoM.

getErrorM

public boolean getErrorM()
Returns:
Returns the errorM.

getUseTextTree

public boolean getUseTextTree()
Returns:
Returns the useTextTree.

getUseGraphicalTreeViewer

public boolean getUseGraphicalTreeViewer()
Returns:
Returns the useGraphicalTreeViewer.

getGraphicalTreeViewerParams

public java.lang.String getGraphicalTreeViewerParams()

getUseGraphicalNetworkViewer

public boolean getUseGraphicalNetworkViewer()
Returns:
Returns the useGraphicalNetworkViewer.

getGraphicalNetworkViewerClassName

public java.lang.String getGraphicalNetworkViewerClassName()
graphicalNetworkViewerClassName


getGraphicalNetworkViewerParams

public java.lang.String getGraphicalNetworkViewerParams()
graphicalNetworkViewerParams


getUseGridViewer

public boolean getUseGridViewer()
Returns:
Returns the useGridViewer.

getGridPanelClassName

public java.lang.String getGridPanelClassName()
Returns:
Returns the gridPanelClassName.

getUseDataPlotter

public boolean getUseDataPlotter()
Returns:
Returns the useDataPlotter.

getUseJFreeChart

public boolean getUseJFreeChart()

getUseGnuplot

public boolean getUseGnuplot()

getDataPlotterParams

public java.lang.String getDataPlotterParams()

getUseHistogramPlotter

public boolean getUseHistogramPlotter()
Returns:
Returns the useHistogramPlotter.

getUseJFreeChart_Hist

public boolean getUseJFreeChart_Hist()

getUseGnuplot_Hist

public boolean getUseGnuplot_Hist()

getHistogramPlotterParams

public java.lang.String getHistogramPlotterParams()

getUseInteractions

public boolean getUseInteractions()
Returns:
Returns the useInteractions.

getInteractionParams

public java.lang.String getInteractionParams()
Returns:
Returns the interactionParams.

getUseVrml

public boolean getUseVrml()
Returns:
Returns the useVrml.

getVrmlWriterClassName

public java.lang.String getVrmlWriterClassName()
Returns:
Returns the name of the VrmlWriter class.

getVrmlParams

public java.lang.String getVrmlParams()
Returns:
vrmlParams

getJavaClassName

public java.lang.String getJavaClassName()
Returns:
Returns the javaClassName.

getJavaXhClassName

public java.lang.String getJavaXhClassName()
Returns:
Returns the javaXhClassName.

getJavaXhClassClassName

public java.lang.String getJavaXhClassClassName()
Returns:
Returns the javaXhClassClassName.

getJavaActivityClassName

public java.lang.String getJavaActivityClassName()
Returns:
Returns the javaActivityClassName.

getSaveSnapshots

public boolean getSaveSnapshots()
Returns:
Returns the saveSnapshots.

getSnapshotParams

public java.lang.String getSnapshotParams()
Returns:
snapshotParams

getModelName

public java.lang.String getModelName()
Description copied from interface: IApplication
Get the model name.

Specified by:
getModelName in interface IApplication
Returns:
Returns the modelName.

getSizeMessageQueue

public int getSizeMessageQueue()
Returns:
Returns the size of the message queue.

getTreeNodeFactoryDynamic

public boolean getTreeNodeFactoryDynamic()
Returns:
Returns whether the factory type is TreeNodeFactoryDynamic.

getRandomNumberSeed

public long getRandomNumberSeed()
Returns:
Random number seed.

getMaxPorts

public int getMaxPorts()
Returns:
Maximum number of ports for any xholon in the model.

getXincludePath

public java.lang.String getXincludePath()
Returns:
XInclude path (for InheritanceHierarchy only; could be different in ContainmentHierarchy.

getXhymAgent

public java.lang.String getXhymAgent()
xhymAgent


getClass

public java.lang.Class getClass(java.lang.String className)
Return the class given the class name.

Parameters:
className - The name of a Java class.
Returns:
The class.

getApplication

public static IApplication getApplication(IXholon xhNode)
Get the instance of Application that the Xholon node is part of.

Parameters:
xhNode - An instance of IXholon.
Returns:
An instance of Application, or null (should never happen).

setApplication

public static void setApplication(IApplication app)
Set an instance of IApplication.

Parameters:
app - An instance of IApplication.

initGui

public void initGui(java.lang.Object gui)
Description copied from interface: IApplication
Initialize the GUI.

Specified by:
initGui in interface IApplication
Parameters:
gui - The JTree gui.

initControl

public void initControl()
Description copied from interface: IApplication
Initialize the control aspects of the application.

Specified by:
initControl in interface IApplication

setControllerState

public void setControllerState(int controllerState)
Description copied from interface: IApplication
Set state of the controller for this app.

Specified by:
setControllerState in interface IApplication
Parameters:
controllerState - The current controller state.

getControllerState

public int getControllerState()
Description copied from interface: IApplication
Get state of the controller.

Specified by:
getControllerState in interface IApplication
Returns:
The current controller state.

getRoot

public IXholon getRoot()
Description copied from interface: IApplication
Get the model root.

Specified by:
getRoot in interface IApplication
Returns:
The model root.

getAppRoot

public Control getAppRoot()
Description copied from interface: IApplication
Get the application root.

Specified by:
getAppRoot in interface IApplication
Returns:
The application root.

initialize

public void initialize(java.lang.String configFileName)
Description copied from interface: IApplication
Initialize the application.

Specified by:
initialize in interface IApplication
Parameters:
configFileName - Name of the configuration file.

process

public void process()
Description copied from interface: IApplication
Process time steps during the lifetime of the application.

Specified by:
process in interface IApplication

wrapup

public void wrapup()
Description copied from interface: IApplication
Wrapup any unfinished business in the application.

Specified by:
wrapup in interface IApplication

readConfigFromFileXml

public void readConfigFromFileXml(java.lang.String fileName)
Description copied from interface: IApplication
Read configuration values from an XML file.

Specified by:
readConfigFromFileXml in interface IApplication
Parameters:
fileName - Name of the configuration file. ex: Config_HelloWorld.xml

setParam

public boolean setParam(java.lang.String pName,
                        java.lang.String pValue)
Description copied from interface: IApplication
Set the value of a parameter.

Specified by:
setParam in interface IApplication
Parameters:
pName - Parameter name.
pValue - Parameter value.

resetViewers

public void resetViewers()
Description copied from interface: IApplication
Reset all viewers to their default values. This should be done when a new model is run after a previous one.

Specified by:
resetViewers in interface IApplication

initViewers

public void initViewers()
Description copied from interface: IApplication
Initialize any View tools to be used by the application.

Specified by:
initViewers in interface IApplication

saveSnapshot

public void saveSnapshot()
Save snapshot of xholon tree.

Specified by:
saveSnapshot in interface IApplication

about

public void about()
Description copied from interface: IApplication
Display brief information about Xholon and the application.

Specified by:
about in interface IApplication

information

public void information()
Description copied from interface: IApplication
Display detailed information about the application.

Specified by:
information in interface IApplication

invokeGraphicalTreeViewer

public IViewer invokeGraphicalTreeViewer(IXholon xhStart,
                                         java.lang.String graphicalNetworkViewerParams)
Description copied from interface: IApplication
Invoke the graphical tree viewer.

Specified by:
invokeGraphicalTreeViewer in interface IApplication
Parameters:
xhStart - The start node whose contents will be graphed.
graphicalNetworkViewerParams - A set of comma-delimited parameters.

invokeGraphicalTreeViewer

public IViewer invokeGraphicalTreeViewer()
Description copied from interface: IApplication
Invoke the graphical tree viewer.

Specified by:
invokeGraphicalTreeViewer in interface IApplication

invokeGraphicalNetworkViewer

public IViewer invokeGraphicalNetworkViewer(IXholon xhStart,
                                            java.lang.String graphicalNetworkViewerParams)
Description copied from interface: IApplication
Invoke the graphical network viewer.

Specified by:
invokeGraphicalNetworkViewer in interface IApplication
Parameters:
xhStart - The start node whose contents will be graphed.
graphicalNetworkViewerParams - A set of comma-delimited parameters.

invokeGraphicalNetworkViewer

public IViewer invokeGraphicalNetworkViewer()
Description copied from interface: IApplication
Invoke the graphical network viewer.

Specified by:
invokeGraphicalNetworkViewer in interface IApplication

invokeDataPlotter

public IViewer invokeDataPlotter()
Description copied from interface: IApplication
Invoke the data plotter.

Specified by:
invokeDataPlotter in interface IApplication

invokeHistogramPlotter

public IViewer invokeHistogramPlotter()
Description copied from interface: IApplication
Invoke the histogram plotter.

Specified by:
invokeHistogramPlotter in interface IApplication

invokeInteraction

public IViewer invokeInteraction()
Description copied from interface: IApplication
Invoke the interaction viewer.

Specified by:
invokeInteraction in interface IApplication

appMain

public static void appMain(java.lang.String[] args,
                           java.lang.String className,
                           java.lang.String defaultConfigFileName)
Perform most or all of the work required of main() in an Application subclass.

Parameters:
args - Arguments passed in from the command line.
className - Name of the Application subclass. ex: AppHelloWorld
defaultConfigFileName - Name and path of a default _xhn.xml configuration file. ex: "./config/HelloWorld/HelloWorld_xhn.xml"