Class ClientH2StreamMultiplexer

java.lang.Object
org.apache.hc.core5.http2.impl.nio.ClientH2StreamMultiplexer
All Implemented Interfaces:
Closeable, AutoCloseable, org.apache.hc.core5.http.HttpConnection, org.apache.hc.core5.http.SocketModalCloseable, org.apache.hc.core5.io.ModalCloseable, org.apache.hc.core5.util.Identifiable

@Internal public class ClientH2StreamMultiplexer extends Object
I/O event handler for events fired by ProtocolIOSession that implements client side HTTP/2 messaging protocol with full support for multiplexed message transmission.
Since:
5.0
  • Constructor Summary

    Constructors
    Constructor
    Description
    ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig)
     
    ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig)
     
    ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, FrameFactory frameFactory, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig, H2StreamListener streamListener)
     
    ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, FrameFactory frameFactory, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig, H2StreamListener streamListener, org.apache.hc.core5.util.Timeout validateAfterInactivity)
     
    ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, FrameFactory frameFactory, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig, H2StreamListener streamListener, org.apache.hc.core5.util.Timeout validateAfterInactivity, org.apache.hc.core5.util.Timeout pingAckTimeout)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
     
    void
    close(org.apache.hc.core5.io.CloseMode closeMode)
     
    org.apache.hc.core5.http.EndpointDetails
     
     
     
    org.apache.hc.core5.http.ProtocolVersion
     
     
    org.apache.hc.core5.util.Timeout
     
     
    boolean
     
    final void
     
    final void
     
    final void
     
    final void
     
    final void
     
    final void
    onTimeout(org.apache.hc.core5.util.Timeout timeout)
     
    void
    setSocketTimeout(org.apache.hc.core5.util.Timeout timeout)
     
    int
     
     

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.apache.hc.core5.http.HttpConnection

    isIdle
  • Constructor Details

    • ClientH2StreamMultiplexer

      public ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, FrameFactory frameFactory, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig, H2StreamListener streamListener, org.apache.hc.core5.util.Timeout validateAfterInactivity, org.apache.hc.core5.util.Timeout pingAckTimeout)
      Since:
      5.5
    • ClientH2StreamMultiplexer

      public ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, FrameFactory frameFactory, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig, H2StreamListener streamListener, org.apache.hc.core5.util.Timeout validateAfterInactivity)
    • ClientH2StreamMultiplexer

      public ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, FrameFactory frameFactory, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig, H2StreamListener streamListener)
    • ClientH2StreamMultiplexer

      public ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, org.apache.hc.core5.http.nio.HandlerFactory<org.apache.hc.core5.http.nio.AsyncPushConsumer> pushHandlerFactory, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig)
    • ClientH2StreamMultiplexer

      public ClientH2StreamMultiplexer(org.apache.hc.core5.reactor.ProtocolIOSession ioSession, org.apache.hc.core5.http.protocol.HttpProcessor httpProcessor, H2Config h2Config, org.apache.hc.core5.http.config.CharCodingConfig charCodingConfig)
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getId

      public String getId()
      Specified by:
      getId in interface org.apache.hc.core5.util.Identifiable
    • onConnect

      public final void onConnect() throws org.apache.hc.core5.http.HttpException, IOException
      Throws:
      org.apache.hc.core5.http.HttpException
      IOException
    • onInput

      public final void onInput(ByteBuffer src) throws org.apache.hc.core5.http.HttpException, IOException
      Throws:
      org.apache.hc.core5.http.HttpException
      IOException
    • onOutput

      public final void onOutput() throws org.apache.hc.core5.http.HttpException, IOException
      Throws:
      org.apache.hc.core5.http.HttpException
      IOException
    • onTimeout

      public final void onTimeout(org.apache.hc.core5.util.Timeout timeout) throws org.apache.hc.core5.http.HttpException, IOException
      Throws:
      org.apache.hc.core5.http.HttpException
      IOException
    • onDisconnect

      public final void onDisconnect()
    • onException

      public final void onException(Exception cause)
    • streamCount

      public int streamCount()
      Since:
      5.5
    • close

      public void close() throws IOException
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
      Specified by:
      close in interface org.apache.hc.core5.http.HttpConnection
      Throws:
      IOException
    • close

      public void close(org.apache.hc.core5.io.CloseMode closeMode)
      Specified by:
      close in interface org.apache.hc.core5.io.ModalCloseable
    • isOpen

      public boolean isOpen()
      Specified by:
      isOpen in interface org.apache.hc.core5.http.HttpConnection
    • setSocketTimeout

      public void setSocketTimeout(org.apache.hc.core5.util.Timeout timeout)
      Specified by:
      setSocketTimeout in interface org.apache.hc.core5.http.SocketModalCloseable
    • getSSLSession

      public SSLSession getSSLSession()
      Specified by:
      getSSLSession in interface org.apache.hc.core5.http.HttpConnection
    • getEndpointDetails

      public org.apache.hc.core5.http.EndpointDetails getEndpointDetails()
      Specified by:
      getEndpointDetails in interface org.apache.hc.core5.http.HttpConnection
    • getSocketTimeout

      public org.apache.hc.core5.util.Timeout getSocketTimeout()
      Specified by:
      getSocketTimeout in interface org.apache.hc.core5.http.SocketModalCloseable
    • getProtocolVersion

      public org.apache.hc.core5.http.ProtocolVersion getProtocolVersion()
      Specified by:
      getProtocolVersion in interface org.apache.hc.core5.http.HttpConnection
    • getRemoteAddress

      public SocketAddress getRemoteAddress()
      Specified by:
      getRemoteAddress in interface org.apache.hc.core5.http.HttpConnection
    • getLocalAddress

      public SocketAddress getLocalAddress()
      Specified by:
      getLocalAddress in interface org.apache.hc.core5.http.HttpConnection