Package org.eclipse.jetty.client
Class HttpProxy.ProxyConnection
- java.lang.Object
-
- org.eclipse.jetty.client.HttpProxy.ProxyConnection
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
,Connection
- Enclosing class:
- HttpProxy
private static class HttpProxy.ProxyConnection extends java.lang.Object implements Connection
-
-
Field Summary
Fields Modifier and Type Field Description private Connection
connection
private Destination
destination
private Promise<Connection>
promise
-
Constructor Summary
Constructors Modifier Constructor Description private
ProxyConnection(Destination destination, Connection connection, Promise<Connection> promise)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
boolean
isClosed()
void
send(Request request, Response.CompleteListener listener)
Sends a request with an associated response listener.
-
-
-
Field Detail
-
destination
private final Destination destination
-
connection
private final Connection connection
-
promise
private final Promise<Connection> promise
-
-
Constructor Detail
-
ProxyConnection
private ProxyConnection(Destination destination, Connection connection, Promise<Connection> promise)
-
-
Method Detail
-
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 interfaceConnection
- Parameters:
request
- the request to sendlistener
- the response listener
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
- Specified by:
close
in interfaceConnection
-
isClosed
public boolean isClosed()
- Specified by:
isClosed
in interfaceConnection
- Returns:
- whether this connection has been closed
- See Also:
Connection.close()
-
-