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

## php.java.bridge.http
Class PipeContextServer

    java.lang.Object
      php.java.bridge.http.PipeContextServer

All Implemented Interfaces:
  IContextServer

Direct Known Subclasses:
  SocketContextServer

    public class PipeContextServer

extends java.lang.Object
implements IContextServer

This class manages the ContextRunners. It pulls a ContextRunner from the list of available runners and invokes it. We currently check only if the number of runners requested is less than or equal to the number of runners created by the servlet requests.

Nested Class Summary

Nested classes/interfaces inherited from interface php.java.bridge.http.IContextServer
`IContextServer.ChannelName`

Constructor Summary
`PipeContextServer(ContextServer contextServer, ThreadPool threadPool)` Create a new ContextServer using the ThreadPool.

Method Summary
`void` | `destroy()` Destroy the server
`boolean` | `isAvailable()` Check if the ContextServer is ready
`java.lang.String` | `schedule(IContextServer.ChannelName channelName)` Check if there's a persistent ContextRunner available for the kontext.
`boolean` | `start(IContextServer.ChannelName channelName)` Start the runner.

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

Constructor Detail

### PipeContextServer

    public PipeContextServer(ContextServer contextServer,
                             ThreadPool threadPool)

  Create a new ContextServer using the ThreadPool.

  Parameters:
    `threadPool` - Obtain runnables from this pool. If null, new threads will be created.

Method Detail

### schedule

    public java.lang.String schedule(IContextServer.ChannelName channelName)

  Description copied from interface: `IContextServer`
  Check if there's a persistent ContextRunner available for the kontext.

  Specified by:
    `schedule` in interface `IContextServer`
  Returns:
    the default name or null.
  See Also:
    `IContextServer.ChannelName.schedule()`

### start

    public boolean start(IContextServer.ChannelName channelName)

  Description copied from interface: `IContextServer`
  Start the runner.

  Specified by:
    `start` in interface `IContextServer`
  Parameters:
    `channelName` - The channel name

### destroy

    public void destroy()

  Destroy the server

  Specified by:
    `destroy` in interface `IContextServer`

### isAvailable

    public boolean isAvailable()

  Check if the ContextServer is ready

  Specified by:
    `isAvailable` in interface `IContextServer`
  Returns:
    true, if the server is available

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