Package com.twitter.hpack

Examples of com.twitter.hpack.Encoder$HeaderEntry


    public DefaultHttp2HeadersEncoder() {
        this(DEFAULT_HEADER_TABLE_SIZE, Collections.<String>emptySet());
    }

    public DefaultHttp2HeadersEncoder(int maxHeaderTableSize, Set<String> sensitiveHeaders) {
        encoder = new Encoder(maxHeaderTableSize);
        this.sensitiveHeaders.addAll(sensitiveHeaders);
    }
View Full Code Here


    private static byte[] b(String string) {
        return string.getBytes(UTF_8);
    }

    private static ByteBuf encode(byte[]... entries) throws Exception {
        Encoder encoder = new Encoder();
        ByteArrayOutputStream stream = new ByteArrayOutputStream();
        for (int ix = 0; ix < entries.length;) {
            byte[] key = entries[ix++];
            byte[] value = entries[ix++];
            encoder.encodeHeader(stream, key, value, false);
        }
        return Unpooled.wrappedBuffer(stream.toByteArray());
    }
View Full Code Here

    public DefaultHttp2HeadersEncoder() {
        this(DEFAULT_HEADER_TABLE_SIZE, Collections.<String>emptySet());
    }

    public DefaultHttp2HeadersEncoder(int maxHeaderTableSize, Set<String> sensitiveHeaders) {
        encoder = new Encoder(maxHeaderTableSize);
        this.sensitiveHeaders.addAll(sensitiveHeaders);
        headerTable = new Http2HeaderTableEncoder();
    }
View Full Code Here

TOP

Related Classes of com.twitter.hpack.Encoder$HeaderEntry

Copyright © 2018 www.massapicom. 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.