Example usage for org.apache.http.impl.nio DefaultHttpServerIODispatch DefaultHttpServerIODispatch

List of usage examples for org.apache.http.impl.nio DefaultHttpServerIODispatch DefaultHttpServerIODispatch

Introduction

In this page you can find the example usage for org.apache.http.impl.nio DefaultHttpServerIODispatch DefaultHttpServerIODispatch.

Prototype

public DefaultHttpServerIODispatch(final NHttpServerEventHandler handler, final ConnectionConfig config) 

Source Link

Usage

From source file:org.apache.synapse.transport.utils.logging.LoggingUtils.java

/**
 * Create a new DefaultHttpServerIODispatch instance using the provided parameters.
 * This method may decorate (wrap) the original arguments with logging-enabled wrappers,
 * depending on the current logging configuration.
 *
 * @param handler An NHttpServerEventHandler instance
 * @param config A ConnectionConfig instance
 * @return A DefaultHttpServerIODispatch instance
 */// w w  w . j  a  v a 2 s .c om
public static DefaultHttpServerIODispatch getServerIODispatch(final NHttpServerEventHandler handler,
        final ConnectionConfig config) {
    return new DefaultHttpServerIODispatch(decorate(handler), new LoggingNHttpServerConnectionFactory(config));
}

From source file:org.apache.synapse.transport.utils.logging.LoggingUtils.java

/**
 * Create a new DefaultHttpServerIODispatch instance using the provided parameters.
 * This method may decorate (wrap) the original arguments with logging-enabled wrappers,
 * depending on the current logging configuration.
 *
 * @param handler An NHttpServerEventHandler instance
 * @param config A ConnectionConfig instance
 * @param sslContext An SSLContext instance to initialize SSL support
 * @param sslSetupHandler An SSLSetupHandler instance
 * @return A DefaultHttpServerIODispatch instance
 *///from  w  ww  .  jav a2s .c o  m
public static DefaultHttpServerIODispatch getServerIODispatch(final NHttpServerEventHandler handler,
        final ConnectionConfig config, final SSLContext sslContext, final SSLSetupHandler sslSetupHandler) {
    return new DefaultHttpServerIODispatch(decorate(handler),
            new LoggingNHttpSSLServerConnectionFactory(config, sslContext, sslSetupHandler));
}