Package io.vertx.mutiny.ext.web.client
Class WebClientSession
java.lang.Object
io.vertx.mutiny.ext.web.client.WebClient
io.vertx.mutiny.ext.web.client.WebClientSession
- All Implemented Interfaces:
MutinyDelegate
An asynchronous sessions aware HTTP / HTTP/2 client called
WebClientSession.
This client wraps a WebClient and makes it session aware adding features to it:
- Per client headers, to be send with every request
- Per client cookies, to be send with every request
- Automatic storage and sending of cookies received from the server(s)
The client honors the cookies attributes:
- domain
- path
- secure
- max-age and expires
original non Mutiny-ified interface using Vert.x codegen.-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionWebClientSession(io.vertx.ext.web.client.WebClientSession delegate) WebClientSession(Object delegate) -
Method Summary
Modifier and TypeMethodDescriptionaddHeader(CharSequence name, CharSequence value) addHeader(CharSequence name, Iterable<CharSequence> values) io.vertx.ext.web.client.spi.CookieStorestatic WebClientSessionstatic WebClientSessionbooleanio.vertx.ext.web.client.WebClientSessioninthashCode()static WebClientSessionnewInstance(io.vertx.ext.web.client.WebClientSession arg) removeHeader(CharSequence name) removeHeader(String name) toString()Methods inherited from class io.vertx.mutiny.ext.web.client.WebClient
close, create, create, delete, delete, delete, delete, delete, delete, deleteAbs, deleteAbs, get, get, get, get, get, get, getAbs, getAbs, head, head, head, head, head, head, headAbs, headAbs, newInstance, patch, patch, patch, patch, patch, patch, patchAbs, patchAbs, post, post, post, post, post, post, postAbs, postAbs, put, put, put, put, put, put, putAbs, putAbs, request, request, request, request, request, request, request, request, request, request, request, request, request, request, requestAbs, requestAbs, requestAbs, requestAbs, updateSSLOptions, updateSSLOptions, updateSSLOptionsAndAwait, updateSSLOptionsAndAwait, updateSSLOptionsAndForget, updateSSLOptionsAndForget, wrap, wrap
-
Field Details
-
__TYPE_ARG
-
-
Constructor Details
-
WebClientSession
public WebClientSession(io.vertx.ext.web.client.WebClientSession delegate) -
WebClientSession
-
-
Method Details
-
getDelegate
public io.vertx.ext.web.client.WebClientSession getDelegate()- Specified by:
getDelegatein interfaceMutinyDelegate- Overrides:
getDelegatein classWebClient- Returns:
- the delegate used by this Mutiny object of generated type
-
toString
-
equals
-
hashCode
public int hashCode() -
create
- Parameters:
webClient- the web client instance- Returns:
- the created client
-
addHeader
- Parameters:
name- the header namevalue- the header value- Returns:
- a reference to this, so the API can be used fluently
-
removeHeader
- Parameters:
name- the header name- Returns:
- a reference to this, so the API can be used fluently
-
create
public static WebClientSession create(WebClient webClient, io.vertx.ext.web.client.spi.CookieStore cookieStore) - Parameters:
webClient- the web client instancecookieStore-- Returns:
- the created client
-
addHeader
- Parameters:
name- the header namevalue- the header value- Returns:
- a reference to this, so the API can be used fluently
-
addHeader
- Parameters:
name- the header namevalues- the header value- Returns:
- a reference to this, so the API can be used fluently
-
addHeader
- Parameters:
name- the header namevalues- the header value- Returns:
- a reference to this, so the API can be used fluently
-
removeHeader
- Parameters:
name- the header name- Returns:
- a reference to this, so the API can be used fluently
-
cookieStore
public io.vertx.ext.web.client.spi.CookieStore cookieStore()- Returns:
- this client's cookie store
-
newInstance
-