org.primordion.xholon.base
Interface ITreeNodeFactory

All Superinterfaces:
IXholon
All Known Implementing Classes:
TreeNodeFactoryDynamic, TreeNodeFactoryStatic

public interface ITreeNodeFactory
extends IXholon

A tree node factory creates and manages Xholon tree nodes.

Since:
0.3 (Created on Feb 15, 2006)
Author:
Ken Webb

Field Summary
 
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
 
Method Summary
 Activity getActivityNode()
          Deprecated. use implName attribute in the ClassDetails.xml file instead
 AbstractGrid getGridEntityNode()
          Deprecated. use implName attribute in the ClassDetails.xml file instead
 IXholon getNode(java.lang.Class xholonSubclass)
          Get a node instance of the specified Java class.
 IXholon getNode(int xhType)
          Get a node instance of the specified Xholon Type.
 int getNumAvailNodes(int resourceType)
          Get number of treeNodes available for use.
 StateMachineEntity getStateMachineEntityNode()
          Deprecated. use implName attribute in the ClassDetails.xml file instead
 IXholonClass getXholonClassNode()
          Get a XholonClass instance from the factory.
 IXholon getXholonNode()
          Get a Xholon instance from the factory.
 IXholon getXholonNode(java.lang.String implName)
          Get a Xholon instance from the factory, based on its full package name.
 void returnTreeNode(IXholon node)
          Return a TreeNode to the factory.
 
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
 

Method Detail

getNumAvailNodes

public int getNumAvailNodes(int resourceType)
Get number of treeNodes available for use.

Parameters:
resourceType - The type of node: Xholon, XholonClass, StateMachineEntity, or Activity.
Returns:
Number of available nodes.

getNode

public IXholon getNode(java.lang.Class xholonSubclass)
Get a node instance of the specified Java class.

Parameters:
xholonSubclass -
Returns:
An IXholon instance.

getNode

public IXholon getNode(int xhType)
Get a node instance of the specified Xholon Type.

Parameters:
xhType -
Returns:
An IXholon instance.

getXholonNode

public IXholon getXholonNode()
Get a Xholon instance from the factory.

Returns:
The next available instance, or null. TODO Need to handle null (Q_EMPTY) condition gracefully.

getXholonNode

public IXholon getXholonNode(java.lang.String implName)
Get a Xholon instance from the factory, based on its full package name.

Parameters:
implName - The name of a Java class.
Returns:
An instance of that class, or null.

getXholonClassNode

public IXholonClass getXholonClassNode()
Get a XholonClass instance from the factory.

Returns:
The next available instance, or null.

getActivityNode

public Activity getActivityNode()
Deprecated. use implName attribute in the ClassDetails.xml file instead

Get a Activity node from the factory.

Returns:
The next available instance, or null.

getStateMachineEntityNode

public StateMachineEntity getStateMachineEntityNode()
Deprecated. use implName attribute in the ClassDetails.xml file instead

Get a StateMaqchineEntity node from the factory.

Returns:
The next available instance, or null.

getGridEntityNode

public AbstractGrid getGridEntityNode()
Deprecated. use implName attribute in the ClassDetails.xml file instead

Get a GridEntity node from the factory.

Returns:
The next available instance, or null.

returnTreeNode

public void returnTreeNode(IXholon node)
Return a TreeNode to the factory.

Parameters:
node - The TreeNode being returned.