Class HttpProxy.ProxyConnection
java.lang.Object
org.eclipse.jetty.client.HttpProxy.ProxyConnection
- All Implemented Interfaces:
Closeable, AutoCloseable, Connection, Attachable
- Enclosing class:
HttpProxy
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Objectprivate final Connectionprivate final Destinationprivate final Promise<Connection> -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateProxyConnection(Destination destination, Connection connection, Promise<Connection> promise) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()booleanisClosed()voidsend(Request request, Response.CompleteListener listener) Sends a request with an associated response listener.voidsetAttachment(Object obj) Attaches the given object to this stream for later retrieval.
-
Field Details
-
destination
-
connection
-
promise
-
attachment
-
-
Constructor Details
-
ProxyConnection
private ProxyConnection(Destination destination, Connection connection, Promise<Connection> promise)
-
-
Method Details
-
send
Description copied from interface:ConnectionSends 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:
sendin interfaceConnection- Parameters:
request- the request to sendlistener- the response listener
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceConnection
-
isClosed
public boolean isClosed()- Specified by:
isClosedin interfaceConnection- Returns:
- whether this connection has been closed
- See Also:
-
setAttachment
Description copied from interface:AttachableAttaches the given object to this stream for later retrieval.- Specified by:
setAttachmentin interfaceAttachable- Parameters:
obj- the object to attach to this instance
-
getAttachment
- Specified by:
getAttachmentin interfaceAttachable- Returns:
- the object attached to this instance
- See Also:
-