com.applino
Class ApplinoContext

java.lang.Object
  extended by org.mortbay.component.AbstractLifeCycle
      extended by org.mortbay.jetty.handler.AbstractHandler
          extended by org.mortbay.jetty.handler.AbstractHandlerContainer
              extended by org.mortbay.jetty.handler.HandlerWrapper
                  extended by org.mortbay.jetty.handler.ContextHandler
                      extended by org.mortbay.jetty.servlet.Context
                          extended by org.mortbay.jetty.webapp.WebAppContext
                              extended by com.applino.ApplinoContext
All Implemented Interfaces:
org.mortbay.component.LifeCycle, org.mortbay.jetty.Handler, org.mortbay.jetty.HandlerContainer, org.mortbay.jetty.Server.Graceful, org.mortbay.util.Attributes

public class ApplinoContext
extends org.mortbay.jetty.webapp.WebAppContext

An ApplinoContext is simply an extension of a Jetty WebAppContext which also deals with updating the task tray icon when Applini are started and stopped. In addition it frees any resources associated with an Applino when it is stopped and creates an ApplinoFrame for the Applino to use for displaying any graphical output.


Nested Class Summary
 
Nested classes/interfaces inherited from class org.mortbay.jetty.servlet.Context
org.mortbay.jetty.servlet.Context.SContext
 
Field Summary
 
Fields inherited from class org.mortbay.jetty.webapp.WebAppContext
ERROR_PAGE, WEB_DEFAULTS_XML
 
Fields inherited from class org.mortbay.jetty.servlet.Context
_securityHandler, _servletHandler, _sessionHandler, NO_SECURITY, NO_SESSIONS, SECURITY, SESSIONS
 
Fields inherited from class org.mortbay.jetty.handler.ContextHandler
_scontext
 
Fields inherited from class org.mortbay.jetty.handler.AbstractHandler
_string
 
Fields inherited from interface org.mortbay.jetty.Handler
ALL, DEFAULT, ERROR, FORWARD, INCLUDE, REQUEST
 
Constructor Summary
ApplinoContext()
           
 
Method Summary
 java.awt.MenuItem getMenuItem()
           
 void setMenuItem(java.awt.MenuItem menuItem)
          The ApplinoContext needs to have access to the corresponding MenuItem so that it can change the displayed status whenever the applino is started or stopped.
 void startApplino()
          Method to stop a running Applino context.
 void stopApplino()
           
 
Methods inherited from class org.mortbay.jetty.webapp.WebAppContext
addEventListener, addWebApplications, addWebApplications, addWebApplications, addWebApplications, doStart, doStop, dumpUrl, getConfigurationClasses, getConfigurations, getCurrentWebAppContext, getDefaultsDescriptor, getDescriptor, getExtraClasspath, getOverrideDescriptor, getPermissions, getResource, getResourceAlias, getResourceAliases, getServerClasses, getSystemClasses, getTempDirectory, getWar, getWebInf, handle, isCopyWebDir, isDistributable, isExtractWAR, isLogUrlOnStart, isParentLoaderPriority, isProtectedTarget, isTempWorkDirectory, loadConfigurations, removeResourceAlias, resolveWebApp, setClassLoader, setConfigurationClasses, setConfigurations, setCopyWebDir, setDefaultsDescriptor, setDescriptor, setDistributable, setEventListeners, setExtraClasspath, setExtractWAR, setLogUrlOnStart, setOverrideDescriptor, setParentLoaderPriority, setPermissions, setResourceAlias, setResourceAliases, setServerClasses, setSystemClasses, setTempDirectory, setWar, startContext, toString
 
Methods inherited from class org.mortbay.jetty.servlet.Context
addFilter, addFilter, addFilter, addServlet, addServlet, addServlet, getSecurityHandler, getServletHandler, getSessionHandler, setSecurityHandler, setServletHandler, setSessionHandler
 
Methods inherited from class org.mortbay.jetty.handler.ContextHandler
addLocaleEncoding, clearAttributes, getAllowNullPathInfo, getAttribute, getAttributeNames, getAttributes, getBaseResource, getClassLoader, getClassPath, getConnectorNames, getContextPath, getCurrentContext, getDisplayName, getErrorHandler, getEventListeners, getHosts, getInitParameter, getInitParameterNames, getInitParams, getLocaleEncoding, getMaxFormContentSize, getMimeTypes, getResourceBase, getResourcePaths, getServletContext, getVirtualHosts, getWelcomeFiles, isCompactPath, isShutdown, loadClass, removeAttribute, setAllowNullPathInfo, setAttribute, setAttributes, setBaseResource, setCompactPath, setConnectorNames, setContextPath, setDisplayName, setErrorHandler, setHosts, setInitParams, setMaxFormContentSize, setMimeTypes, setResourceBase, setServer, setShutdown, setVirtualHosts, setWelcomeFiles
 
Methods inherited from class org.mortbay.jetty.handler.HandlerWrapper
addHandler, expandChildren, getHandler, setHandler
 
Methods inherited from class org.mortbay.jetty.handler.AbstractHandlerContainer
expandHandler, getChildHandlerByClass, getChildHandlers, getChildHandlersByClass
 
Methods inherited from class org.mortbay.jetty.handler.AbstractHandler
destroy, getServer
 
Methods inherited from class org.mortbay.component.AbstractLifeCycle
isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.mortbay.component.LifeCycle
isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, start, stop
 

Constructor Detail

ApplinoContext

public ApplinoContext()
Method Detail

getMenuItem

public java.awt.MenuItem getMenuItem()

setMenuItem

public void setMenuItem(java.awt.MenuItem menuItem)
The ApplinoContext needs to have access to the corresponding MenuItem so that it can change the displayed status whenever the applino is started or stopped.

Parameters:
menuItem - The menu item corresponding to this Applino context.

startApplino

public void startApplino()
Method to stop a running Applino context. Is typically called from the StartApplinoListner in the ApplinoDeployer and from the "Window Closed" and "Exit" listeners in ApplinoFrame.

See Also:
ApplinoDeployer.StartApplinoListner, ApplinoFrame.windowCloseListener, ApplinoFrame.exitListener

stopApplino

public void stopApplino()