Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.eclipse.jetty.servlet
Class Holder<T>

    java.lang.Object
      org.eclipse.jetty.util.component.AbstractLifeCycle
          org.eclipse.jetty.servlet.Holder<T>

All Implemented Interfaces:
  LifeCycle

Direct Known Subclasses:
  FilterHolder, ServletHolder

    public class Holder<T>

extends AbstractLifeCycle

Nested Class Summary
`protected class` | `Holder.HolderConfig`
`protected class` | `Holder.HolderRegistration`
`static class` | `Holder.Source`

Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
`AbstractLifeCycle.AbstractLifeCycleListener`

Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.LifeCycle
`LifeCycle.Listener`

Field Summary
`protected boolean` | `_asyncSupported`
`protected java.lang.Class<? extends T>` | `_class`
`protected java.lang.String` | `_className`
`protected java.lang.String` | `_displayName`
`protected boolean` | `_extInstance`
`protected java.util.Map<java.lang.String,java.lang.String>` | `_initParams`
`protected java.lang.String` | `_name`
`protected ServletHandler` | `_servletHandler`

Fields inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
`_listeners, FAILED, RUNNING, STARTED, STARTING, STOPPED, STOPPING`

Constructor Summary
`protected` | `Holder(Holder.Source source)`

Method Summary
`void` | `destroyInstance(java.lang.Object instance)`
`void` | `doStart()`
`void` | `doStop()`
`java.lang.String` | `getClassName()`
`java.lang.String` | `getDisplayName()`
`java.lang.Class<? extends T>` | `getHeldClass()`
`java.lang.String` | `getInitParameter(java.lang.String param)`
`java.util.Enumeration` | `getInitParameterNames()`
`java.util.Map<java.lang.String,java.lang.String>` | `getInitParameters()`
`java.lang.String` | `getName()`
`ServletHandler` | `getServletHandler()`
`Holder.Source` | `getSource()`
`protected void` | `illegalStateIfContextStarted()`
`boolean` | `isAsyncSupported()`
`boolean` | `isInstance()`
`void` | `setAsyncSupported(boolean suspendable)`
`void` | `setClassName(java.lang.String className)`
`void` | `setDisplayName(java.lang.String name)`
`void` | `setHeldClass(java.lang.Class<? extends T> held)`
`void` | `setInitParameter(java.lang.String param, java.lang.String value)`
`void` | `setInitParameters(java.util.Map<java.lang.String,java.lang.String> map)`
`void` | `setName(java.lang.String name)` The name is a primary key for the held object.
`void` | `setServletHandler(ServletHandler servletHandler)`
`java.lang.String` | `toString()`

Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
`addLifeCycleListener, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### _class

    protected transient java.lang.Class<? extends T> _class

### _initParams

    protected final java.util.Map<java.lang.String,java.lang.String> _initParams

### _className

    protected java.lang.String _className

### _displayName

    protected java.lang.String _displayName

### _extInstance

    protected boolean _extInstance

### _asyncSupported

    protected boolean _asyncSupported

### _name

    protected java.lang.String _name

### _servletHandler

    protected ServletHandler _servletHandler

Constructor Detail

### Holder

    protected Holder(Holder.Source source)

Method Detail

### getSource

    public Holder.Source getSource()

### isInstance

    public boolean isInstance()

  Returns:
    True if this holder was created for a specific instance.

### doStart

    public void doStart()
                 throws java.lang.Exception

  Overrides:
    `doStart` in class `AbstractLifeCycle`
  Throws:
    `java.lang.Exception`

### doStop

    public void doStop()
                throws java.lang.Exception

  Overrides:
    `doStop` in class `AbstractLifeCycle`
  Throws:
    `java.lang.Exception`

### getClassName

    public java.lang.String getClassName()

### getHeldClass

    public java.lang.Class<? extends T> getHeldClass()

### getDisplayName

    public java.lang.String getDisplayName()

### getInitParameter

    public java.lang.String getInitParameter(java.lang.String param)

### getInitParameterNames

    public java.util.Enumeration getInitParameterNames()

### getInitParameters

    public java.util.Map<java.lang.String,java.lang.String> getInitParameters()

### getName

    public java.lang.String getName()

### getServletHandler

    public ServletHandler getServletHandler()

  Returns:
    Returns the servletHandler.

### destroyInstance

    public void destroyInstance(java.lang.Object instance)
                         throws java.lang.Exception

  Throws:
    `java.lang.Exception`

### setClassName

    public void setClassName(java.lang.String className)

  Parameters:
    `className` - The className to set.

### setHeldClass

    public void setHeldClass(java.lang.Class<? extends T> held)

  Parameters:
    `held` - The class to hold

### setDisplayName

    public void setDisplayName(java.lang.String name)

### setInitParameter

    public void setInitParameter(java.lang.String param,
                                 java.lang.String value)

### setInitParameters

    public void setInitParameters(java.util.Map<java.lang.String,java.lang.String> map)

### setName

    public void setName(java.lang.String name)

  The name is a primary key for the held object. Ensure that the name is set BEFORE adding a Holder (eg ServletHolder or FilterHolder) to a ServletHandler.

  Parameters:
    `name` - The name to set.

### setServletHandler

    public void setServletHandler(ServletHandler servletHandler)

  Parameters:
    `servletHandler` - The `ServletHandler` that will handle requests dispatched to this servlet.

### setAsyncSupported

    public void setAsyncSupported(boolean suspendable)

### isAsyncSupported

    public boolean isAsyncSupported()

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

### illegalStateIfContextStarted

    protected void illegalStateIfContextStarted()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 1995-2010 Mort Bay Consulting. All Rights Reserved.