org.mortbay.jetty.nio
Class BlockingChannelConnector

java.lang.Object
  extended by org.mortbay.component.AbstractLifeCycle
      extended by org.mortbay.jetty.AbstractConnector
          extended by org.mortbay.jetty.nio.BlockingChannelConnector
All Implemented Interfaces:
LifeCycle, Buffers, Connector

public class BlockingChannelConnector
extends AbstractConnector

Blocking NIO connector. This connector uses efficient NIO buffers with a traditional blocking thread model. Direct NIO buffers are used and a thread is allocated per connections. This connector is best used when there are a few very active connections.

Author:
gregw

Nested Class Summary
private  class BlockingChannelConnector.Connection
           
 
Field Summary
private  ServerSocketChannel _acceptChannel
           
 
Fields inherited from class org.mortbay.jetty.AbstractConnector
_maxIdleTime, _soLingerTime
 
Constructor Summary
BlockingChannelConnector()
          Constructor.
 
Method Summary
 void accept(int acceptorID)
           
 void close()
           
protected  Buffer newBuffer(int size)
           
 void open()
           
 
Methods inherited from class org.mortbay.jetty.AbstractConnector
configure, customize, doStart, doStop, getAcceptors, getAcceptQueueSize, getAddress, getBuffer, getConfidentialPort, getConfidentialScheme, getHeaderBufferSize, getHost, getIntegralPort, getIntegralScheme, getMaxIdleTime, getPort, getRequestBufferSize, getResponseBufferSize, getServer, getSoLingerTime, getThreadPool, isConfidential, isIntegral, join, newContinuation, returnBuffer, setAcceptors, setAcceptQueueSize, setConfidentialPort, setConfidentialScheme, setHeaderBufferSize, setHost, setIntegralPort, setIntegralScheme, setMaxIdleTime, setPort, setRequestBufferSize, setResponseBufferSize, setServer, setSoLingerTime, setThreadPool, toString
 
Methods inherited from class org.mortbay.component.AbstractLifeCycle
isFailed, isRunning, isStarted, isStarting, isStopping, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.mortbay.component.LifeCycle
isFailed, isRunning, isStarted, isStarting, isStopping, start, stop
 

Field Detail

_acceptChannel

private transient ServerSocketChannel _acceptChannel
Constructor Detail

BlockingChannelConnector

public BlockingChannelConnector()
Constructor.

Method Detail

open

public void open()
          throws IOException
Specified by:
open in interface Connector
Specified by:
open in class AbstractConnector
Throws:
IOException

close

public void close()
           throws IOException
Throws:
IOException

accept

public void accept(int acceptorID)
            throws IOException,
                   InterruptedException
Specified by:
accept in class AbstractConnector
Throws:
IOException
InterruptedException

newBuffer

protected Buffer newBuffer(int size)
Specified by:
newBuffer in class AbstractConnector