org.apache.jetspeed.engine
Interface Engine

All Superinterfaces:
org.apache.pluto.services.ContainerService, org.apache.pluto.services.factory.FactoryManagerService, org.apache.jetspeed.engine.JetspeedEngineConstants, org.apache.pluto.services.PortletContainerEnvironment
All Known Implementing Classes:
JetspeedEngine

public interface Engine
extends org.apache.jetspeed.engine.JetspeedEngineConstants, org.apache.pluto.services.factory.FactoryManagerService, org.apache.pluto.services.PortletContainerEnvironment

Engine Abstraction - to run from both unit tests and servlet

Version:
$Id: Engine.java 187178 2004-08-02 19:00:15Z weaver $
Author:
David Sean Taylor

Field Summary
 
Fields inherited from interface org.apache.jetspeed.engine.JetspeedEngineConstants
APPLICATION_ROOT_DEFAULT, APPLICATION_ROOT_KEY, CONFIG_NAMESPACE, CONSOLE_LOGGER, DEFAULT_LOGGER, JETSPEED_CONFIGURATION_DEFAULT, JETSPEED_CONFIGURATION_KEY, JETSPEED_PROPERTIES_DEFAULT, JETSPEED_PROPERTIES_KEY, LOG4J_CONFIG_FILE, LOG4J_CONFIG_FILE_DEFAULT, LOGGING_ROOT, LOGGING_ROOT_DEFAULT, MAIL_SERVER_KEY, PIPELINE_CLASS, PIPELINE_DEFAULT, PIPELINE_DIRECTORY, PREFERENCES_FACTORY, PREFERENCES_FACTORY_DEFAULT, SCHEDULER_LOG_FACILITY, WEB_CONTEXT, WEBAPP_ROOT_KEY
 
Method Summary
 org.apache.jetspeed.components.ComponentManager getComponentManager()
           
 PortalContext getContext()
          Get the Portal Context associated with running thread of the engine
 org.apache.jetspeed.request.RequestContext getCurrentRequestContext()
          Returns the the RequestContext associated with the current thread.
 Pipeline getPipeline()
          Gets the engine's request default pipeline.
 Pipeline getPipeline(String pipelineName)
          Gets the specified engine's request pipeline.
 String getRealPath(String path)
          Gets the real path to an application relative resource
 javax.servlet.ServletConfig getServletConfig()
          Get the servlet configuration if this engine is running under a servlet container.
 void service(org.apache.jetspeed.request.RequestContext context)
          Makes a service request to the engine.
 void shutdown()
          Shuts down the Jetspeed engine and all associated services
 void start()
          Initializes the engine with a commons configuration, starting all early initable services.
 
Methods inherited from interface org.apache.pluto.services.factory.FactoryManagerService
getFactory
 
Methods inherited from interface org.apache.pluto.services.PortletContainerEnvironment
getContainerService
 

Method Detail

start

public void start()
           throws org.apache.jetspeed.exception.JetspeedException
Initializes the engine with a commons configuration, starting all early initable services.

Throws:
org.apache.jetspeed.exception.JetspeedException - when the engine fails to initilialize

shutdown

public void shutdown()
              throws org.apache.jetspeed.exception.JetspeedException
Shuts down the Jetspeed engine and all associated services

Throws:
org.apache.jetspeed.exception.JetspeedException - when the engine fails to shutdown

service

public void service(org.apache.jetspeed.request.RequestContext context)
             throws org.apache.jetspeed.exception.JetspeedException
Makes a service request to the engine.

Parameters:
context - a RequestContext with the state of the request.
Throws:
org.apache.jetspeed.exception.JetspeedException - when the engine fails to initilialize

getPipeline

public Pipeline getPipeline()
Gets the engine's request default pipeline.

Returns:
Pipeline The engine's request pipeline.

getPipeline

public Pipeline getPipeline(String pipelineName)
Gets the specified engine's request pipeline.

Returns:
Pipeline A specific request pipeline.

getContext

public PortalContext getContext()
Get the Portal Context associated with running thread of the engine

Returns:
PortalContext associated with this engine's thread

getRealPath

public String getRealPath(String path)
Gets the real path to an application relative resource

Parameters:
path - The application relative resource
Returns:
String The real path to that resource

getServletConfig

public javax.servlet.ServletConfig getServletConfig()
Get the servlet configuration if this engine is running under a servlet container.

Returns:
config The servlet configuration

getCurrentRequestContext

public org.apache.jetspeed.request.RequestContext getCurrentRequestContext()
Returns the the RequestContext associated with the current thread. This can be accessed throught org.apache.jetspeed.Jetspeed environment class.

Returns:
RequestContext associated with the current thread.

getComponentManager

public org.apache.jetspeed.components.ComponentManager getComponentManager()


Copyright © 1999-2005 Apache Software Foundation. All Rights Reserved.