Examples of indexOfType()


Examples of org.glassfish.grizzly.filterchain.FilterChain.indexOfType()

    }


    private void flushOnSSLHandshakeComplete() throws IOException {
        final FilterChain filterChain = context.getFilterChain();
        final int idx = filterChain.indexOfType(SSLFilter.class);
        assert (idx != -1);
        final SSLFilter filter = (SSLFilter) filterChain.get(idx);
        final Connection c = context.getConnection();
        filter.addHandshakeListener(new SSLBaseFilter.HandshakeListener() {
            public void onStart(Connection connection) {
View Full Code Here

Examples of org.glassfish.grizzly.filterchain.FilterChainBuilder.indexOfType()

        // Install the HTTP filter chain.
        //clientTransport.setProcessor(fcb.build());
        FilterChainBuilder nonSecure = FilterChainBuilder.stateless();
        nonSecure.addAll(secure);
        int idx = nonSecure.indexOfType(SSLFilter.class);
        nonSecure.remove(idx);
        final ConnectionPool pool;
        if (providerConfig != null) {
            pool = (ConnectionPool) providerConfig.getProperty(CONNECTION_POOL);
        } else {
View Full Code Here

Examples of org.glassfish.grizzly.filterchain.FilterChainBuilder.indexOfType()

    private FilterChainBuilder createSpdyFilterChain(final FilterChainBuilder fcb, final boolean npnEnabled) {

        FilterChainBuilder spdyFcb = FilterChainBuilder.stateless();
        spdyFcb.addAll(fcb);
        int idx = spdyFcb.indexOfType(SSLFilter.class);
        Filter f = spdyFcb.get(idx);

        // Adjust the SSLFilter to support NPN
        if (npnEnabled) {
            SSLBaseFilter sslBaseFilter = (SSLBaseFilter) f;
View Full Code Here

Examples of org.glassfish.grizzly.filterchain.FilterChainBuilder.indexOfType()

            NextProtoNegSupport.getInstance().configure(sslBaseFilter);
        }

        // Remove the HTTP Client filter - this will be replaced by the
        // SPDY framing and handler filters.
        idx = spdyFcb.indexOfType(HttpClientFilter.class);
        spdyFcb.set(idx, new SpdyFramingFilter());
        final SpdyMode spdyMode = ((npnEnabled) ? SpdyMode.NPN : SpdyMode.PLAIN);
        AsyncSpdyClientEventFilter spdyFilter = new AsyncSpdyClientEventFilter(new EventHandler(clientConfig), spdyMode,
                clientConfig.executorService());
        spdyFilter.setInitialWindowSize(clientConfig.getSpdyInitialWindowSize());
View Full Code Here

Examples of org.glassfish.grizzly.filterchain.FilterChainBuilder.indexOfType()

        spdyFilter.setInitialWindowSize(clientConfig.getSpdyInitialWindowSize());
        spdyFilter.setMaxConcurrentStreams(clientConfig.getSpdyMaxConcurrentStreams());
        spdyFcb.add(idx + 1, spdyFilter);

        // Remove the WebSocket filter - not currently supported.
        idx = spdyFcb.indexOfType(WebSocketClientFilter.class);
        spdyFcb.remove(idx);

        return spdyFcb;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.