AbstractHandlerContainer (Jetty :: Aggregate :: All core Jetty 7.6.8.v20121106 API)
Date: 2012-11-06

org.eclipse.jetty.server.handler

## Class AbstractHandlerContainer

- java.lang.Object
- - org.eclipse.jetty.util.component.AbstractLifeCycle
  - - org.eclipse.jetty.util.component.AggregateLifeCycle
    - - org.eclipse.jetty.server.handler.AbstractHandler
      - - org.eclipse.jetty.server.handler.AbstractHandlerContainer

- All Implemented Interfaces:
    Handler, HandlerContainer, Destroyable, Dumpable, LifeCycle
  Direct Known Subclasses:
    HandlerCollection, HandlerWrapper, HotSwapHandler

      public abstract class AbstractHandlerContainer
      extends AbstractHandler
      implements HandlerContainer

  Abstract Handler Container. This is the base class for handlers that may contain other handlers.

- - ### Nested Class Summary

    - ### 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

    - ### Fields inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle

      `_listeners, FAILED, RUNNING, STARTED, STARTING, STOPPED, STOPPING`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `AbstractHandlerContainer()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `dump(Appendable out, String indent)`
    `protected Object` | `expandChildren(Object list, Class<?> byClass)`
    `protected Object` | `expandHandler(Handler handler, Object list, Class<Handler> byClass)`
    `static <T extends HandlerContainer> T` | `findContainerOf(HandlerContainer root, Class<T> type, Handler handler)`
    `<T extends Handler> T` | `getChildHandlerByClass(Class<T> byclass)`
    `Handler[]` | `getChildHandlers()`
    `Handler[]` | `getChildHandlersByClass(Class<?> byclass)`

    - ### Methods inherited from class org.eclipse.jetty.server.handler.AbstractHandler

      `destroy, doStart, doStop, dumpThis, getServer, setServer`

    - ### Methods inherited from class org.eclipse.jetty.util.component.AggregateLifeCycle

      `addBean, addBean, contains, dump, dump, dump, dump, dumpObject, dumpStdErr, getBean, getBeans, getBeans, isManaged, manage, removeBean, removeBeans, unmanage`

    - ### Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle

      `addLifeCycleListener, getState, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface org.eclipse.jetty.server.HandlerContainer

      `getHandlers`

    - ### Methods inherited from interface org.eclipse.jetty.util.component.LifeCycle

      `addLifeCycleListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop`

    - ### Methods inherited from interface org.eclipse.jetty.server.Handler

      `handle`

- - ### Constructor Detail

    - #### AbstractHandlerContainer

          public AbstractHandlerContainer()

  - ### Method Detail

    - #### getChildHandlers

          public Handler[] getChildHandlers()

      Specified by:
        `getChildHandlers` in interface `HandlerContainer`
      Returns:
        array of all handlers contained by this handler and it's children

    - #### getChildHandlersByClass

          public Handler[] getChildHandlersByClass(Class<?> byclass)

      Specified by:
        `getChildHandlersByClass` in interface `HandlerContainer`
      Returns:
        array of all handlers contained by this handler and it's children of the passed type.

    - #### getChildHandlerByClass

          public <T extends Handler> T getChildHandlerByClass(Class<T> byclass)

      Specified by:
        `getChildHandlerByClass` in interface `HandlerContainer`
      Returns:
        first handler of all handlers contained by this handler and it's children of the passed type.

    - #### expandChildren

          protected Object expandChildren(Object list,
                              Class<?> byClass)

    - #### expandHandler

          protected Object expandHandler(Handler handler,
                             Object list,
                             Class<Handler> byClass)

    - #### findContainerOf

          public static <T extends HandlerContainer> T findContainerOf(HandlerContainer root,
                                                       Class<T> type,
                                                       Handler handler)

    - #### dump

          public void dump(Appendable out,
                  String indent)
                    throws IOException

      Specified by:
        `dump` in interface `Dumpable`
      Overrides:
        `dump` in class `AggregateLifeCycle`
      Throws:
        `IOException`

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