DefaultHttp2RemoteFlowController implements Http2RemoteFlowController { @Override public void incrementWindowSize(Http2Stream stream, int delta) throws Http2Exception { assert ctx == null || ctx.executor().inEventLoop(); monitor.incrementWindowSize(state(stream), delta); } DefaultHttp2RemoteFlowController(Http2Connection connection);  DefaultHttp2RemoteFlowController(Http2Connection connection,
                                            StreamByteDistributor streamByteDistributor);  DefaultHttp2RemoteFlowController(Http2Connection connection, final Listener listener);  DefaultHttp2RemoteFlowController(Http2Connection connection,
                                            StreamByteDistributor streamByteDistributor,
                                            final Listener listener); @Override void channelHandlerContext(ChannelHandlerContext ctx); @Override ChannelHandlerContext channelHandlerContext(); @Override void initialWindowSize(int newWindowSize); @Override int initialWindowSize(); @Override int windowSize(Http2Stream stream); @Override boolean isWritable(Http2Stream stream); @Override void channelWritabilityChanged(); @Override void listener(Listener listener); @Override int initialWindowSize(Http2Stream stream); @Override void incrementWindowSize(Http2Stream stream, int delta); @Override void addFlowControlled(Http2Stream stream, FlowControlled frame); @Override void writePendingBytes();  }
@Test public void windowUpdateShouldChangeConnectionWindow() throws Http2Exception { incrementWindowSize(CONNECTION_STREAM_ID, 100); assertEquals(DEFAULT_WINDOW_SIZE + 100, window(CONNECTION_STREAM_ID)); assertEquals(DEFAULT_WINDOW_SIZE, window(STREAM_A)); assertEquals(DEFAULT_WINDOW_SIZE, window(STREAM_B)); assertEquals(DEFAULT_WINDOW_SIZE, window(STREAM_C)); assertEquals(DEFAULT_WINDOW_SIZE, window(STREAM_D)); verifyZeroInteractions(listener); }
@Test public void windowUpdateShouldChangeStreamWindow() throws Http2Exception { incrementWindowSize(STREAM_A, 100); assertEquals(DEFAULT_WINDOW_SIZE, window(CONNECTION_STREAM_ID)); assertEquals(DEFAULT_WINDOW_SIZE + 100, window(STREAM_A)); assertEquals(DEFAULT_WINDOW_SIZE, window(STREAM_B)); assertEquals(DEFAULT_WINDOW_SIZE, window(STREAM_C)); assertEquals(DEFAULT_WINDOW_SIZE, window(STREAM_D)); verifyZeroInteractions(listener); }