org.apache.beehive.controls.runtime.servlet
Class ServletBeanContext

Object
  extended by BeanContextChildSupport
      extended by BeanContextSupport
          extended by BeanContextServicesSupport
              extended by ControlBeanContext
                  extended by ControlContainerContext
                      extended by ServletBeanContext
All Implemented Interfaces:
BeanContext, BeanContextChild, BeanContextServiceRevokedListener, BeanContextServices, BeanContextServicesListener, DesignMode, PropertyChangeListener, VetoableChangeListener, Visibility, Serializable, Iterable, Collection, EventListener, ControlBeanContext, ControlContainerContext, EventDispatcher

public class ServletBeanContext
extends ControlContainerContext

The ServletBeanContext provides a ControlBeanContext implementation that offers services and a resource management context that is appropriate to web tier usage of controls.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class BeanContextServicesSupport
BeanContextServicesSupport.BCSSChild, BeanContextServicesSupport.BCSSProxyServiceProvider, BeanContextServicesSupport.BCSSServiceProvider
 
Nested classes/interfaces inherited from class BeanContextSupport
BeanContextSupport.BCSChild, BeanContextSupport.BCSIterator
 
Nested classes/interfaces inherited from interface ControlBeanContext
ControlBeanContext.LifeCycle
 
Field Summary
 
Fields inherited from class ControlBeanContext
INTERCEPTOR_CONFIG_FILE
 
Fields inherited from class BeanContextServicesSupport
bcsListeners, proxy, serializable, services
 
Fields inherited from class BeanContextSupport
bcmListeners, children, designTime, locale, okToUseGui
 
Fields inherited from class BeanContextChildSupport
beanContext, beanContextChildPeer, pcSupport, rejectedSetBCOnce, vcSupport
 
Fields inherited from interface BeanContext
globalHierarchyLock
 
Fields inherited from interface DesignMode
PROPERTYNAME
 
Constructor Summary
ServletBeanContext()
           
 
Method Summary
 void beginContext(ServletContext context, ServletRequest req, ServletResponse resp)
          Begins a new execution context, associated with a specific ServletRequest
 void endContext()
          Ends the current execution context, and resetes the current active ServletRequest.
 ServletContext getServletContext()
          Returns the ServletContext associated with this context (or null if not currently processing a request)
 ServletRequest getServletRequest()
          Returns the ServletRequest associated with this context (or null if not currently processing a request)
 ServletResponse getServletResponse()
          Returns the ServletResponse associated with this context (or null if not currently processing a request)
 void initialize()
          Called by BeanContextSupport superclass during construction and deserialization to initialize subclass transient state
 void setWrappers(boolean useWrappers)
          Enables/disable the use of request/response wrappers for this context.
protected  boolean useWrappers()
           
 
Methods inherited from class ControlContainerContext
addResourceContext, beginContext, dispatchEvent, getControlHandle, isSingleThreadedContainer, releaseResources, removeResourceContext
 
Methods inherited from class ControlBeanContext
add, addLifeCycleListener, generateUniqueID, getAnnotationMap, getBean, getBeanAnnotationMap, getClassLoader, getControlBean, getControlHandle, getControlInterface, getControlPropertyMap, getControlPropertySet, getDefaultControlBinding, getMethodPropertySet, getParameterNames, getParameterPropertySet, getParameterValue, getService, hasSingleThreadedParent, initializeControl, prioritizeInterceptors, propertyChange, remove, removeLifeCycleListener, resolveDefaultBinding, serviceRevoked, setBeanContext, setDelegateMap, vetoableChange
 
Methods inherited from class BeanContextServicesSupport
addBeanContextServicesListener, addService, addService, bcsPreDeserializationHook, bcsPreSerializationHook, childJustRemovedHook, createBCSChild, createBCSSServiceProvider, fireServiceAdded, fireServiceAdded, fireServiceRevoked, fireServiceRevoked, getBeanContextServicesPeer, getChildBeanContextServicesListener, getCurrentServiceClasses, getCurrentServiceSelectors, getService, hasService, initializeBeanContextResources, releaseBeanContextResources, releaseService, removeBeanContextServicesListener, revokeService, serviceAvailable
 
Methods inherited from class BeanContextSupport
addAll, addBeanContextMembershipListener, avoidingGui, bcsChildren, childDeserializedHook, childJustAddedHook, classEquals, clear, contains, containsAll, containsKey, copyChildren, deserialize, dontUseGui, fireChildrenAdded, fireChildrenRemoved, getBeanContextPeer, getChildBeanContextChild, getChildBeanContextMembershipListener, getChildPropertyChangeListener, getChildSerializable, getChildVetoableChangeListener, getChildVisibility, getLocale, getResource, getResourceAsStream, instantiateChild, isDesignTime, isEmpty, isSerializing, iterator, needsGui, okToUseGui, readChildren, remove, removeAll, removeBeanContextMembershipListener, retainAll, serialize, setDesignTime, setLocale, size, toArray, toArray, validatePendingAdd, validatePendingRemove, writeChildren
 
Methods inherited from class BeanContextChildSupport
addPropertyChangeListener, addVetoableChangeListener, firePropertyChange, fireVetoableChange, getBeanContext, getBeanContextChildPeer, isDelegated, removePropertyChangeListener, removeVetoableChangeListener, validatePendingSetBeanContext
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface ControlBeanContext
addLifeCycleListener, getAnnotationMap, getBean, getClassLoader, getControlBean, getControlHandle, getControlInterface, getControlPropertyMap, getControlPropertySet, getMethodPropertySet, getParameterNames, getParameterPropertySet, getParameterValue, getService, removeLifeCycleListener
 
Methods inherited from interface BeanContextServices
addBeanContextServicesListener, addService, getCurrentServiceClasses, getCurrentServiceSelectors, getService, hasService, releaseService, removeBeanContextServicesListener, revokeService
 
Methods inherited from interface BeanContext
addBeanContextMembershipListener, getResource, getResourceAsStream, instantiateChild, removeBeanContextMembershipListener
 
Methods inherited from interface BeanContextChild
addPropertyChangeListener, addVetoableChangeListener, getBeanContext, removePropertyChangeListener, removeVetoableChangeListener, setBeanContext
 
Methods inherited from interface Collection
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray
 
Methods inherited from interface DesignMode
isDesignTime, setDesignTime
 
Methods inherited from interface Visibility
avoidingGui, dontUseGui, needsGui, okToUseGui
 
Methods inherited from interface BeanContextServicesListener
serviceAvailable
 
Methods inherited from interface BeanContextServiceRevokedListener
serviceRevoked
 

Constructor Detail

ServletBeanContext

public ServletBeanContext()
Method Detail

initialize

public void initialize()
Called by BeanContextSupport superclass during construction and deserialization to initialize subclass transient state

Overrides:
initialize in class ControlContainerContext

beginContext

public void beginContext(ServletContext context,
                         ServletRequest req,
                         ServletResponse resp)
Begins a new execution context, associated with a specific ServletRequest


endContext

public void endContext()
Ends the current execution context, and resetes the current active ServletRequest.

Specified by:
endContext in interface ControlContainerContext
Overrides:
endContext in class ControlContainerContext

getServletContext

public ServletContext getServletContext()
Returns the ServletContext associated with this context (or null if not currently processing a request)


getServletRequest

public ServletRequest getServletRequest()
Returns the ServletRequest associated with this context (or null if not currently processing a request)


getServletResponse

public ServletResponse getServletResponse()
Returns the ServletResponse associated with this context (or null if not currently processing a request)


setWrappers

public void setWrappers(boolean useWrappers)
Enables/disable the use of request/response wrappers for this context. By default, wrappers are enabled if this API is not invoked.


useWrappers

protected boolean useWrappers()