DefaultHttp2FrameReader implements Http2FrameReader, Http2FrameSizePolicy, Configuration { private void readPriorityFrame(ChannelHandlerContext ctx, ByteBuf payload, Http2FrameListener listener) throws Http2Exception { long word1 = payload.readUnsignedInt(); boolean exclusive = (word1 & 0x80000000L) != 0; int streamDependency = (int) (word1 & 0x7FFFFFFFL); if (streamDependency == streamId) { throw streamError(streamId, PROTOCOL_ERROR, "A stream cannot depend on itself."); } short weight = (short) (payload.readUnsignedByte() + 1); listener.onPriorityRead(ctx, streamId, streamDependency, weight, exclusive); } DefaultHttp2FrameReader();  DefaultHttp2FrameReader(boolean validateHeaders);  DefaultHttp2FrameReader(Http2HeadersDecoder headersDecoder); @Override Http2HeadersDecoder.Configuration headersConfiguration(); @Override Configuration configuration(); @Override Http2FrameSizePolicy frameSizePolicy(); @Override void maxFrameSize(int max); @Override int maxFrameSize(); @Override void close(); @Override void readFrame(ChannelHandlerContext ctx, ByteBuf input, Http2FrameListener listener);  }
@Test public void readPriorityFrame() throws Http2Exception { ByteBuf input = Unpooled.buffer(); try { writePriorityFrame(input, 1, 0, 10); frameReader.readFrame(ctx, input, listener); } finally { input.release(); } }