Class HttpConnectionOverHTTP

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable, Connection, IConnection, org.eclipse.jetty.io.Connection, org.eclipse.jetty.io.Connection.UpgradeFrom, org.eclipse.jetty.util.Attachable, org.eclipse.jetty.util.thread.Sweeper.Sweepable

    public class HttpConnectionOverHTTP
    extends org.eclipse.jetty.io.AbstractConnection
    implements IConnection, org.eclipse.jetty.io.Connection.UpgradeFrom, org.eclipse.jetty.util.thread.Sweeper.Sweepable, org.eclipse.jetty.util.Attachable
    • Constructor Detail

      • HttpConnectionOverHTTP

        public HttpConnectionOverHTTP​(org.eclipse.jetty.io.EndPoint endPoint,
                                      java.util.Map<java.lang.String,​java.lang.Object> context)
      • HttpConnectionOverHTTP

        public HttpConnectionOverHTTP​(org.eclipse.jetty.io.EndPoint endPoint,
                                      HttpDestination destination,
                                      org.eclipse.jetty.util.Promise<Connection> promise)
    • Method Detail

      • getBytesIn

        public long getBytesIn()
        Specified by:
        getBytesIn in interface org.eclipse.jetty.io.Connection
        Overrides:
        getBytesIn in class org.eclipse.jetty.io.AbstractConnection
      • addBytesIn

        protected void addBytesIn​(long bytesIn)
      • getBytesOut

        public long getBytesOut()
        Specified by:
        getBytesOut in interface org.eclipse.jetty.io.Connection
        Overrides:
        getBytesOut in class org.eclipse.jetty.io.AbstractConnection
      • addBytesOut

        protected void addBytesOut​(long bytesOut)
      • getMessagesIn

        public long getMessagesIn()
        Specified by:
        getMessagesIn in interface org.eclipse.jetty.io.Connection
        Overrides:
        getMessagesIn in class org.eclipse.jetty.io.AbstractConnection
      • getMessagesOut

        public long getMessagesOut()
        Specified by:
        getMessagesOut in interface org.eclipse.jetty.io.Connection
        Overrides:
        getMessagesOut in class org.eclipse.jetty.io.AbstractConnection
      • send

        public void send​(Request request,
                         Response.CompleteListener listener)
        Description copied from interface: Connection
        Sends a request with an associated response listener.

        Request.send(Response.CompleteListener) will eventually call this method to send the request. It is exposed to allow applications to send requests via unpooled connections.

        Specified by:
        send in interface Connection
        Parameters:
        request - the request to send
        listener - the response listener
      • onOpen

        public void onOpen()
        Specified by:
        onOpen in interface org.eclipse.jetty.io.Connection
        Overrides:
        onOpen in class org.eclipse.jetty.io.AbstractConnection
      • setAttachment

        public void setAttachment​(java.lang.Object obj)
        Specified by:
        setAttachment in interface org.eclipse.jetty.util.Attachable
      • getAttachment

        public java.lang.Object getAttachment()
        Specified by:
        getAttachment in interface org.eclipse.jetty.util.Attachable
      • onIdleExpired

        public boolean onIdleExpired()
        Specified by:
        onIdleExpired in interface org.eclipse.jetty.io.Connection
        Overrides:
        onIdleExpired in class org.eclipse.jetty.io.AbstractConnection
      • onIdleTimeout

        protected boolean onIdleTimeout​(long idleTimeout)
      • onFillable

        public void onFillable()
        Specified by:
        onFillable in class org.eclipse.jetty.io.AbstractConnection
      • onUpgradeFrom

        public java.nio.ByteBuffer onUpgradeFrom()
        Specified by:
        onUpgradeFrom in interface org.eclipse.jetty.io.Connection.UpgradeFrom
      • release

        public void release()
      • close

        public void close()
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable
        Specified by:
        close in interface Connection
        Specified by:
        close in interface org.eclipse.jetty.io.Connection
        Overrides:
        close in class org.eclipse.jetty.io.AbstractConnection
      • close

        protected void close​(java.lang.Throwable failure)
      • abort

        protected boolean abort​(java.lang.Throwable failure)
      • sweep

        public boolean sweep()
        Specified by:
        sweep in interface org.eclipse.jetty.util.thread.Sweeper.Sweepable
      • remove

        public void remove()
      • toConnectionString

        public java.lang.String toConnectionString()
        Overrides:
        toConnectionString in class org.eclipse.jetty.io.AbstractConnection