Package io.undertow.client.http2
Class Http2ClientExchange
java.lang.Object
io.undertow.util.AbstractAttachable
io.undertow.client.http2.Http2ClientExchange
- All Implemented Interfaces:
ClientExchange
,Attachable
- Author:
- Stuart Douglas
-
Constructor Summary
ConstructorsConstructorDescriptionHttp2ClientExchange
(ClientConnection clientConnection, Http2StreamSinkChannel request, ClientRequest clientRequest) -
Method Summary
Modifier and TypeMethodDescriptionorg.xnio.channels.StreamSinkChannel
Returns the request channel that can be used to send data to the server.org.xnio.channels.StreamSourceChannel
Returns the response channel that can be used to read data from the target server.void
setContinueHandler
(ContinueNotification continueHandler) void
setPushHandler
(PushCallback pushCallback) void
setResponseListener
(ClientCallback<ClientExchange> responseListener) Methods inherited from class io.undertow.util.AbstractAttachable
addToAttachmentList, createAttachmentMap, getAttachment, getAttachmentList, putAttachment, removeAttachment
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.undertow.util.Attachable
addToAttachmentList, getAttachment, getAttachmentList, putAttachment, removeAttachment
-
Constructor Details
-
Http2ClientExchange
public Http2ClientExchange(ClientConnection clientConnection, Http2StreamSinkChannel request, ClientRequest clientRequest)
-
-
Method Details
-
setResponseListener
- Specified by:
setResponseListener
in interfaceClientExchange
-
setContinueHandler
- Specified by:
setContinueHandler
in interfaceClientExchange
-
setPushHandler
- Specified by:
setPushHandler
in interfaceClientExchange
-
getRequestChannel
public org.xnio.channels.StreamSinkChannel getRequestChannel()Description copied from interface:ClientExchange
Returns the request channel that can be used to send data to the server.- Specified by:
getRequestChannel
in interfaceClientExchange
- Returns:
- The request channel
-
getResponseChannel
public org.xnio.channels.StreamSourceChannel getResponseChannel()Description copied from interface:ClientExchange
Returns the response channel that can be used to read data from the target server.- Specified by:
getResponseChannel
in interfaceClientExchange
- Returns:
- The response channel
-
getRequest
- Specified by:
getRequest
in interfaceClientExchange
-
getResponse
- Specified by:
getResponse
in interfaceClientExchange
- Returns:
- The client response, or null if it has not been received yet
-
getContinueResponse
- Specified by:
getContinueResponse
in interfaceClientExchange
- Returns:
- the result of a HTTP 100-continue response
-
getConnection
- Specified by:
getConnection
in interfaceClientExchange
- Returns:
- The underlying connection
-