## org.apache.http.impl.nio.pool
Class BasicNIOConnFactory

    java.lang.Object
      org.apache.http.impl.nio.pool.BasicNIOConnFactory

All Implemented Interfaces:
  NIOConnFactory<HttpHost,NHttpClientConnection>

    @Immutable
    public class BasicNIOConnFactory

extends Object
implements NIOConnFactory<HttpHost,NHttpClientConnection>

A basic `NIOConnFactory` implementation that creates `NHttpClientConnection` instances given a `HttpHost` instance.

The following parameters can be used to customize the behavior of this class:

- `CoreProtocolPNames.HTTP_ELEMENT_CHARSET`
- `CoreConnectionPNames.SOCKET_BUFFER_SIZE`
- `CoreConnectionPNames.MAX_HEADER_COUNT`
- `CoreConnectionPNames.MAX_LINE_LENGTH`

Since:
  4.2

Constructor Summary
`BasicNIOConnFactory(HttpParams params)`
`BasicNIOConnFactory(NHttpConnectionFactory<? extends NHttpClientConnection> plainFactory)`
`BasicNIOConnFactory(NHttpConnectionFactory<? extends NHttpClientConnection> plainFactory, NHttpConnectionFactory<? extends NHttpClientConnection> sslFactory)`
`BasicNIOConnFactory(SSLContext sslcontext, SSLSetupHandler sslHandler, HttpParams params)`
`BasicNIOConnFactory(SSLContext sslcontext, SSLSetupHandler sslHandler, HttpResponseFactory responseFactory, ByteBufferAllocator allocator, HttpParams params)`

Method Summary
`NHttpClientConnection` `create(HttpHost route, IOSession session)`

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

Constructor Detail

### BasicNIOConnFactory

    public BasicNIOConnFactory(NHttpConnectionFactory<? extends NHttpClientConnection> plainFactory,
                               NHttpConnectionFactory<? extends NHttpClientConnection> sslFactory)

### BasicNIOConnFactory

    public BasicNIOConnFactory(NHttpConnectionFactory<? extends NHttpClientConnection> plainFactory)

### BasicNIOConnFactory

    public BasicNIOConnFactory(SSLContext sslcontext,
                               SSLSetupHandler sslHandler,
                               HttpResponseFactory responseFactory,
                               ByteBufferAllocator allocator,
                               HttpParams params)

### BasicNIOConnFactory

    public BasicNIOConnFactory(SSLContext sslcontext,
                               SSLSetupHandler sslHandler,
                               HttpParams params)

### BasicNIOConnFactory

    public BasicNIOConnFactory(HttpParams params)

Method Detail

### create

    public NHttpClientConnection create(HttpHost route,
                                        IOSession session)
                                 throws IOException

  Specified by:
    `create` in interface `NIOConnFactory<HttpHost,NHttpClientConnection>`
  Throws:
    `IOException`

Copyright © 2005-2013 The Apache Software Foundation. All Rights Reserved.