All Packages Class Hierarchy This Package Previous Next Index
Class uhr.core.cell.NodeCreator
java.lang.Object
|
+----uhr.core.cell.NodeCreator
- public class NodeCreator
- extends Object
- implements ServiceHost,
UF_StringArray
This class creates new System Tree container nodes. The cases of
root nodes and "subnodes" are handled, plus convenience methods
for the system startup Use Case.
Currently this only creates container nodes. Leaf nodes are
created elsewhere. It's conceivable that responsiblity will move
to this class.
Later we can make this ParamDriven.
-
NodeCreator()
-
-
createAndStartSystem(String)
- Creates and starts a system using the rootDK_URL.
-
createRootNode()
- Creates a root cell node with no parent node.
-
createSubcellNode(Container,
String)
- Creates a subcell node as a child of the parentNode, which must
be a cell node itself.
-
createSystem(String)
- Creates a system using the rootDK_URL.
-
get()
- This uniface returns the command line args or null if none.
-
getServiceHostAide()
- Returns the aide handling the ServiceHost's attractor work.
-
setCommandLineArgs(String[])
- Sets the command line args for this system.
NodeCreator
public NodeCreator()
getServiceHostAide
public ServiceHostAide getServiceHostAide()
- Returns the aide handling the ServiceHost's attractor work.
My ServiceItems are:
Type: uhr.uniface.UF_StringArray
ServiceID: uhr.core.GetCommandLineArgs
- Returns:
- the aide.
get
public String[] get()
- This uniface returns the command line args or null if none.
- Returns:
- the command line args in a String array, or null if none.
createAndStartSystem
public Container createAndStartSystem(String rootDK_URL)
- Creates and starts a system using the rootDK_URL. This is
intended to be the one line of code that's used to start the
average system.
- Parameters:
- rootDK_URL - the dk url defining the root cell's domain
parts. If null then the system contains
no domain parts.
- Returns:
- the root node of the started system, named "Root".
createSystem
public Container createSystem(String rootDK_URL)
- Creates a system using the rootDK_URL. This is
intended to be used by tools
- Parameters:
- rootDK_URL - the dk url defining the root cell's domain
parts. If null then the system contains
no domain parts.
- Returns:
- the root node of the system, named "Root".
createRootNode
public Container createRootNode()
- Creates a root cell node with no parent node.
Self-referential systems have serious design issues involving
the root node and cell, because they have no parent to handle
certain responsibilities. This means that root nodes and cells
are treated differently from nodes and cells with parents.
To avoid this differential behavior from destroying the integrity
of a system design, some such differential work is done here.
Ideally all of it would be here, but that design eludes us.
- Parameters:
- parentNode - the parent node of the cell node to be
created or null if no parent.
- Returns:
- the new cell node. If a subcell, no name. If a root
then the default name "Root" is set.
createSubcellNode
public Container createSubcellNode(Container parentNode,
String partName)
- Creates a subcell node as a child of the parentNode, which must
be a cell node itself. A cell node with a parent is called a
subcell node.
- Parameters:
- parentNode - the parent node of the node to be created.
- partName - the name of the new node.
- Returns:
- the new cell node.
setCommandLineArgs
public void setCommandLineArgs(String args[])
- Sets the command line args for this system. The purpose is to
make them available for system parts. If there are none, then
this method need not be called, or null can be used for args.
- Parameters:
- args - the command line args.
All Packages Class Hierarchy This Package Previous Next Index