Java源码示例:org.glassfish.jersey.server.ContainerFactory

示例1
/**
 * Creates and starts the {@link HttpServer JDK HttpServer} with the Jersey
 * application deployed on the given {@link URI}, and bind to given address
 */
public static HttpServer createHttpServer(final URI uri, final String bindingHost,
                                          final int corePoolSize, final int maxPoolSize,
                                          final long keepAliveTime, final int maxQueueSize,
                                          final ResourceConfig configuration)
        throws ProcessingException {
    final HttpHandlerContainer handler =
            ContainerFactory.createContainer(HttpHandlerContainer.class, configuration);
    return createHttpServer(uri, bindingHost, handler, corePoolSize, maxPoolSize, keepAliveTime, maxQueueSize);
}