consciouscode.seedling.tree
Class StandardRoot

java.lang.Object
  extended by consciouscode.seedling.tree.GenericNode
      extended by consciouscode.seedling.tree.GenericBranch
          extended by consciouscode.seedling.tree.StandardBranch
              extended by consciouscode.seedling.tree.StandardRoot
All Implemented Interfaces:
BranchingBranch, BranchNode, EventfulBranch, GrowingBranch, LocatableNode, RootNode, ServiceNode

public class StandardRoot
extends StandardBranch
implements RootNode, ServiceNode

The global root of a Seedling application tree.

Applications generally don't need to directly instantiate a Root; instead, they should use the Seedling facade.


Field Summary
 
Fields inherited from class consciouscode.seedling.tree.StandardBranch
myNodeProvider
 
Constructor Summary
StandardRoot(NodeProvider nodeProvider, boolean debug)
          Creates a new Seedling root, potentially logging debug messages.
 
Method Summary
 Object getGlobalMonitor()
          NOT SUPPORTED FOR APPLICATION USE.
 String getScopeTag()
          NOT SUPPORTED FOR APPLICATION USE.
 String getShutdownNodePath()
           
 Object getStartupNode()
          Get a reference to the startup node that was automatically installed when this root was started.
 String getStartupNodePath()
           
 void setShutdownNodePath(String path)
           
 void setStartupNodePath(String path)
           
 void shutdown()
           
 void startService()
          Start the entire Seedling by loading the startup node.
 
Methods inherited from class consciouscode.seedling.tree.StandardBranch
availableChildNames, constructChildBranch, getNodeProvider, nodeInstalled, provisionChild
 
Methods inherited from class consciouscode.seedling.tree.GenericBranch
addBranchChangeListener, availableChild, createChild, fireChildInstalled, fireChildUninstalled, getChild, getInstalledNode, getLocalPathForChild, getLocalRoot, getNode, installChild, installedChild, installedChildNames, provisionChildBranch, stopService, uninstallChild
 
Methods inherited from class consciouscode.seedling.tree.GenericNode
getLog, getNodeLocation, getNodeName, getParentBranch, isLoggingDebug, setLog, setLoggingDebug
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface consciouscode.seedling.EventfulBranch
addBranchChangeListener
 
Methods inherited from interface consciouscode.seedling.BranchNode
availableChild, availableChildNames, getChild, getInstalledNode, getLocalRoot, getLog, getNode, installedChild, installedChildNames
 
Methods inherited from interface consciouscode.seedling.LocatableNode
getNodeLocation, nodeInstalled
 
Methods inherited from interface consciouscode.seedling.ServiceNode
stopService
 
Methods inherited from interface consciouscode.seedling.BranchingBranch
provisionChildBranch
 
Methods inherited from interface consciouscode.seedling.GrowingBranch
installChild, uninstallChild
 

Constructor Detail

StandardRoot

public StandardRoot(NodeProvider nodeProvider,
                    boolean debug)
             throws NodeProvisioningException
Creates a new Seedling root, potentially logging debug messages.

POSTCONDITION: (getNodeName() != null)

Throws:
NodeProvisioningException - if there is a problem with the root configuration.
Method Detail

getScopeTag

public String getScopeTag()
Description copied from interface: RootNode
NOT SUPPORTED FOR APPLICATION USE. Returns the tag identifying this root's scope.

Specified by:
getScopeTag in interface RootNode

setStartupNodePath

public void setStartupNodePath(String path)

getStartupNodePath

public String getStartupNodePath()

setShutdownNodePath

public void setShutdownNodePath(String path)

getShutdownNodePath

public String getShutdownNodePath()

getStartupNode

public Object getStartupNode()
Get a reference to the startup node that was automatically installed when this root was started.

See Also:
startService()

shutdown

public void shutdown()

getGlobalMonitor

public final Object getGlobalMonitor()
Description copied from interface: RootNode
NOT SUPPORTED FOR APPLICATION USE.

Specified by:
getGlobalMonitor in interface RootNode

startService

public void startService()
                  throws NodeProvisioningException
Start the entire Seedling by loading the startup node. If the startup node is not configured, an error is logged. After calling this method, the installed node can be accessed via getStartupNode().

Specified by:
startService in interface ServiceNode
Overrides:
startService in class GenericBranch
Throws:
NodeInstantiationException - if there is a problem installing the startup node.
NodeProvisioningException
See Also:
SeedlingConstants.STARTUP_NODE


Copyright © 2001–2012 Todd V. Jonker. All Rights Reserved.