class HttpClient extends Measured
An asynchronous HTTP client.
It allows you to make requests to HTTP servers, and a single client can make requests to any server.
It also allows you to open WebSockets to servers.
The client can also pool HTTP connections.
For pooling to occur, keep-alive must be true on the HttpClientOptions (default is true). In this case connections will be pooled and re-used if there are pending HTTP requests waiting to get a connection, otherwise they will be closed.
This gives the benefits of keep alive when the client is loaded but means we don't keep connections hanging around unnecessarily when there would be no benefits anyway.
The client also supports pipe-lining of requests. Pipe-lining means another request is sent on the same connection before the response from the preceding one has returned. Pipe-lining is not appropriate for all requests.
To enable pipe-lining, it must be enabled on the HttpClientOptions (default is false).
When pipe-lining is enabled the connection will be automatically closed when all in-flight responses have returned and there are no outstanding pending requests to write.
The client is designed to be reused between requests.
- Alphabetic
- By Inheritance
- HttpClient
- Measured
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new HttpClient(_asJava: AnyRef)
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
asJava: AnyRef
- Definition Classes
- HttpClient → Measured
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
def
close(): Unit
Close the client.
Close the client. Closing will close down any pooled connections. Clients should always be closed after use.
-
def
delete(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP DELETE request to send to the server at the default host and port, specifying a response handler to receive the response
Create an HTTP DELETE request to send to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
delete(requestURI: String): HttpClientRequest
Create an HTTP DELETE request to send to the server at the default host and port.
Create an HTTP DELETE request to send to the server at the default host and port.
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
delete(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP DELETE request to send to the server at the specified host and default port, specifying a response handler to receive the response
Create an HTTP DELETE request to send to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
delete(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP DELETE request to send to the server at the specified host and port, specifying a response handler to receive the response
Create an HTTP DELETE request to send to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
delete(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP DELETE request to send to the server with the specified options, specifying a response handler to receive the response
Create an HTTP DELETE request to send to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
delete(host: String, requestURI: String): HttpClientRequest
Create an HTTP DELETE request to send to the server at the specified host and default port.
Create an HTTP DELETE request to send to the server at the specified host and default port.
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
delete(port: Int, host: String, requestURI: String): HttpClientRequest
Create an HTTP DELETE request to send to the server at the specified host and port.
Create an HTTP DELETE request to send to the server at the specified host and port.
- port
the port
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
delete(options: RequestOptions): HttpClientRequest
Create an HTTP DELETE request to send to the server with the specified options.
Create an HTTP DELETE request to send to the server with the specified options.
- options
the request optionssee RequestOptions
- returns
an HTTP client request object
-
def
deleteAbs(absoluteURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP DELETE request to send to the server using an absolute URI, specifying a response handler to receive the response
Create an HTTP DELETE request to send to the server using an absolute URI, specifying a response handler to receive the response
- absoluteURI
the absolute URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
deleteAbs(absoluteURI: String): HttpClientRequest
Create an HTTP DELETE request to send to the server using an absolute URI
Create an HTTP DELETE request to send to the server using an absolute URI
- absoluteURI
the absolute URI
- returns
an HTTP client request object
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
def
get(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP GET request to send to the server at the default host and port, specifying a response handler to receive the response
Create an HTTP GET request to send to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
get(requestURI: String): HttpClientRequest
Create an HTTP GET request to send to the server at the default host and port.
Create an HTTP GET request to send to the server at the default host and port.
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
get(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP GET request to send to the server at the specified host and default port, specifying a response handler to receive the response
Create an HTTP GET request to send to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
get(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP GET request to send to the server at the specified host and port, specifying a response handler to receive the response
Create an HTTP GET request to send to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
get(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP GET request to send to the server with the specified options, specifying a response handler to receive the response
Create an HTTP GET request to send to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
get(host: String, requestURI: String): HttpClientRequest
Create an HTTP GET request to send to the server at the specified host and default port.
Create an HTTP GET request to send to the server at the specified host and default port.
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
get(port: Int, host: String, requestURI: String): HttpClientRequest
Create an HTTP GET request to send to the server at the specified host and port.
Create an HTTP GET request to send to the server at the specified host and port.
- port
the port
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
get(options: RequestOptions): HttpClientRequest
Create an HTTP GET request to send to the server with the specified options.
Create an HTTP GET request to send to the server with the specified options.
- options
the request optionssee RequestOptions
- returns
an HTTP client request object
-
def
getAbs(absoluteURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP GET request to send to the server using an absolute URI, specifying a response handler to receive the response
Create an HTTP GET request to send to the server using an absolute URI, specifying a response handler to receive the response
- absoluteURI
the absolute URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
getAbs(absoluteURI: String): HttpClientRequest
Create an HTTP GET request to send to the server using an absolute URI
Create an HTTP GET request to send to the server using an absolute URI
- absoluteURI
the absolute URI
- returns
an HTTP client request object
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
getNow(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP GET request to the server at the default host and port, specifying a response handler to receive the response
Sends an HTTP GET request to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
getNow(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP GET request to the server at the specified host and default port, specifying a response handler to receive the response
Sends an HTTP GET request to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
getNow(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP GET request to the server at the specified host and port, specifying a response handler to receive the response
Sends an HTTP GET request to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
getNow(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP GET request to the server with the specified options, specifying a response handler to receive the response
Sends an HTTP GET request to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
head(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP HEAD request to send to the server at the default host and port, specifying a response handler to receive the response
Create an HTTP HEAD request to send to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
head(requestURI: String): HttpClientRequest
Create an HTTP HEAD request to send to the server at the default host and port.
Create an HTTP HEAD request to send to the server at the default host and port.
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
head(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP HEAD request to send to the server at the specified host and default port, specifying a response handler to receive the response
Create an HTTP HEAD request to send to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
head(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP HEAD request to send to the server at the specified host and port, specifying a response handler to receive the response
Create an HTTP HEAD request to send to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
head(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP HEAD request to send to the server with the specified options, specifying a response handler to receive the response
Create an HTTP HEAD request to send to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
head(host: String, requestURI: String): HttpClientRequest
Create an HTTP HEAD request to send to the server at the specified host and default port.
Create an HTTP HEAD request to send to the server at the specified host and default port.
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
head(port: Int, host: String, requestURI: String): HttpClientRequest
Create an HTTP HEAD request to send to the server at the specified host and port.
Create an HTTP HEAD request to send to the server at the specified host and port.
- port
the port
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
head(options: RequestOptions): HttpClientRequest
Create an HTTP HEAD request to send to the server with the specified options.
Create an HTTP HEAD request to send to the server with the specified options.
- options
the request optionssee RequestOptions
- returns
an HTTP client request object
-
def
headAbs(absoluteURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP HEAD request to send to the server using an absolute URI, specifying a response handler to receive the response
Create an HTTP HEAD request to send to the server using an absolute URI, specifying a response handler to receive the response
- absoluteURI
the absolute URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
headAbs(absoluteURI: String): HttpClientRequest
Create an HTTP HEAD request to send to the server using an absolute URI
Create an HTTP HEAD request to send to the server using an absolute URI
- absoluteURI
the absolute URI
- returns
an HTTP client request object
-
def
headNow(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP HEAD request to the server at the default host and port, specifying a response handler to receive the response
Sends an HTTP HEAD request to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
headNow(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP HEAD request to the server at the specified host and default port, specifying a response handler to receive the response
Sends an HTTP HEAD request to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
headNow(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP HEAD request to the server at the specified host and port, specifying a response handler to receive the response
Sends an HTTP HEAD request to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
headNow(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP HEAD request to the server with the specified options, specifying a response handler to receive the response
Sends an HTTP HEAD request to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
isMetricsEnabled(): Boolean
Whether the metrics are enabled for this measured object
Whether the metrics are enabled for this measured object
- returns
true if the metrics are enabled
- Definition Classes
- HttpClient → Measured
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
options(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP OPTIONS request to send to the server at the default host and port, specifying a response handler to receive the response
Create an HTTP OPTIONS request to send to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
options(requestURI: String): HttpClientRequest
Create an HTTP OPTIONS request to send to the server at the default host and port.
Create an HTTP OPTIONS request to send to the server at the default host and port.
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
options(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP OPTIONS request to send to the server at the specified host and default port, specifying a response handler to receive the response
Create an HTTP OPTIONS request to send to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
options(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP OPTIONS request to send to the server at the specified host and port, specifying a response handler to receive the response
Create an HTTP OPTIONS request to send to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
options(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP OPTIONS request to send to the server with the specified options, specifying a response handler to receive the response
Create an HTTP OPTIONS request to send to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
options(host: String, requestURI: String): HttpClientRequest
Create an HTTP OPTIONS request to send to the server at the specified host and default port.
Create an HTTP OPTIONS request to send to the server at the specified host and default port.
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
options(port: Int, host: String, requestURI: String): HttpClientRequest
Create an HTTP OPTIONS request to send to the server at the specified host and port.
Create an HTTP OPTIONS request to send to the server at the specified host and port.
- port
the port
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
options(options: RequestOptions): HttpClientRequest
Create an HTTP OPTIONS request to send to the server with the specified options.
Create an HTTP OPTIONS request to send to the server with the specified options.
- options
the request optionssee RequestOptions
- returns
an HTTP client request object
-
def
optionsAbs(absoluteURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP OPTIONS request to send to the server using an absolute URI, specifying a response handler to receive the response
Create an HTTP OPTIONS request to send to the server using an absolute URI, specifying a response handler to receive the response
- absoluteURI
the absolute URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
optionsAbs(absoluteURI: String): HttpClientRequest
Create an HTTP OPTIONS request to send to the server using an absolute URI
Create an HTTP OPTIONS request to send to the server using an absolute URI
- absoluteURI
the absolute URI
- returns
an HTTP client request object
-
def
optionsNow(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP OPTIONS request to the server at the default host and port, specifying a response handler to receive the response
Sends an HTTP OPTIONS request to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
optionsNow(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP OPTIONS request to the server at the specified host and default port, specifying a response handler to receive the response
Sends an HTTP OPTIONS request to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
optionsNow(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP OPTIONS request to the server at the specified host and port, specifying a response handler to receive the response
Sends an HTTP OPTIONS request to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
optionsNow(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClient
Sends an HTTP OPTIONS request to the server with the specified options, specifying a response handler to receive the response
Sends an HTTP OPTIONS request to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
a reference to this, so the API can be used fluently
-
def
post(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP POST request to send to the server at the default host and port, specifying a response handler to receive the response
Create an HTTP POST request to send to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
post(requestURI: String): HttpClientRequest
Create an HTTP POST request to send to the server at the default host and port.
Create an HTTP POST request to send to the server at the default host and port.
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
post(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP POST request to send to the server at the specified host and default port, specifying a response handler to receive the response
Create an HTTP POST request to send to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
post(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP POST request to send to the server at the specified host and port, specifying a response handler to receive the response
Create an HTTP POST request to send to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
post(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP POST request to send to the server with the specified options, specifying a response handler to receive the response
Create an HTTP POST request to send to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
post(host: String, requestURI: String): HttpClientRequest
Create an HTTP POST request to send to the server at the specified host and default port.
Create an HTTP POST request to send to the server at the specified host and default port.
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
post(port: Int, host: String, requestURI: String): HttpClientRequest
Create an HTTP POST request to send to the server at the specified host and port.
Create an HTTP POST request to send to the server at the specified host and port.
- port
the port
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
post(options: RequestOptions): HttpClientRequest
Create an HTTP POST request to send to the server with the specified options.
Create an HTTP POST request to send to the server with the specified options.
- options
the request optionssee RequestOptions
- returns
an HTTP client request object
-
def
postAbs(absoluteURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP POST request to send to the server using an absolute URI, specifying a response handler to receive the response
Create an HTTP POST request to send to the server using an absolute URI, specifying a response handler to receive the response
- absoluteURI
the absolute URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
postAbs(absoluteURI: String): HttpClientRequest
Create an HTTP POST request to send to the server using an absolute URI
Create an HTTP POST request to send to the server using an absolute URI
- absoluteURI
the absolute URI
- returns
an HTTP client request object
-
def
put(requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP PUT request to send to the server at the default host and port, specifying a response handler to receive the response
Create an HTTP PUT request to send to the server at the default host and port, specifying a response handler to receive the response
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
put(requestURI: String): HttpClientRequest
Create an HTTP PUT request to send to the server at the default host and port.
Create an HTTP PUT request to send to the server at the default host and port.
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
put(host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP PUT request to send to the server at the specified host and default port, specifying a response handler to receive the response
Create an HTTP PUT request to send to the server at the specified host and default port, specifying a response handler to receive the response
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
put(port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP PUT request to send to the server at the specified host and port, specifying a response handler to receive the response
Create an HTTP PUT request to send to the server at the specified host and port, specifying a response handler to receive the response
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
put(options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP PUT request to send to the server with the specified options, specifying a response handler to receive the response
Create an HTTP PUT request to send to the server with the specified options, specifying a response handler to receive the response
- options
the request optionssee RequestOptions
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
put(host: String, requestURI: String): HttpClientRequest
Create an HTTP PUT request to send to the server at the specified host and default port.
Create an HTTP PUT request to send to the server at the specified host and default port.
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
put(port: Int, host: String, requestURI: String): HttpClientRequest
Create an HTTP PUT request to send to the server at the specified host and port.
Create an HTTP PUT request to send to the server at the specified host and port.
- port
the port
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
put(options: RequestOptions): HttpClientRequest
Create an HTTP PUT request to send to the server with the specified options.
Create an HTTP PUT request to send to the server with the specified options.
- options
the request optionssee RequestOptions
- returns
an HTTP client request object
-
def
putAbs(absoluteURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP PUT request to send to the server using an absolute URI, specifying a response handler to receive the response
Create an HTTP PUT request to send to the server using an absolute URI, specifying a response handler to receive the response
- absoluteURI
the absolute URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
putAbs(absoluteURI: String): HttpClientRequest
Create an HTTP PUT request to send to the server using an absolute URI
Create an HTTP PUT request to send to the server using an absolute URI
- absoluteURI
the absolute URI
- returns
an HTTP client request object
-
def
redirectHandler(handler: (HttpClientResponse) ⇒ Future[HttpClientRequest]): HttpClient
Set a redirect handler for the http client.
Set a redirect handler for the http client.
The redirect handler is called when a
3xx
response is received and the request is configured to follow redirects with io.vertx.scala.core.http.HttpClientRequest#setFollowRedirects.The redirect handler is passed the io.vertx.scala.core.http.HttpClientResponse, it can return an io.vertx.scala.core.http.HttpClientRequest or
null
.- when null is returned, the original response is processed by the original request response handler
- when a new
Future<HttpClientRequest>
is returned, the client will send this new request
The handler must return a
Future<HttpClientRequest>
unsent so the client can further configure it and send it.- handler
the new redirect handler
- returns
a reference to this, so the API can be used fluently
-
def
request(method: HttpMethod, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP request to send to the server at the default host and port, specifying a response handler to receive the response
Create an HTTP request to send to the server at the default host and port, specifying a response handler to receive the response
- method
the HTTP method
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
request(method: HttpMethod, requestURI: String): HttpClientRequest
Create an HTTP request to send to the server at the default host and port.
Create an HTTP request to send to the server at the default host and port.
- method
the HTTP method
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
request(method: HttpMethod, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP request to send to the server at the specified host and default port, specifying a response handler to receive the response
Create an HTTP request to send to the server at the specified host and default port, specifying a response handler to receive the response
- method
the HTTP method
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
request(method: HttpMethod, port: Int, host: String, requestURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP request to send to the server at the specified host and port, specifying a response handler to receive the response
Create an HTTP request to send to the server at the specified host and port, specifying a response handler to receive the response
- method
the HTTP method
- port
the port
- host
the host
- requestURI
the relative URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
request(method: HttpMethod, options: RequestOptions, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP request to send to the server with the specified options, specifying a response handler to receive
Create an HTTP request to send to the server with the specified options, specifying a response handler to receive
- method
the HTTP method
- options
the request optionssee RequestOptions
- returns
an HTTP client request object
-
def
request(method: HttpMethod, host: String, requestURI: String): HttpClientRequest
Create an HTTP request to send to the server at the specified host and default port.
Create an HTTP request to send to the server at the specified host and default port.
- method
the HTTP method
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
request(method: HttpMethod, port: Int, host: String, requestURI: String): HttpClientRequest
Create an HTTP request to send to the server at the specified host and port.
Create an HTTP request to send to the server at the specified host and port.
- method
the HTTP method
- port
the port
- host
the host
- requestURI
the relative URI
- returns
an HTTP client request object
-
def
request(method: HttpMethod, options: RequestOptions): HttpClientRequest
Create an HTTP request to send to the server with the specified options.
Create an HTTP request to send to the server with the specified options.
- method
the HTTP method
- options
the request optionssee RequestOptions
- returns
an HTTP client request object
-
def
requestAbs(method: HttpMethod, absoluteURI: String, responseHandler: Handler[HttpClientResponse]): HttpClientRequest
Create an HTTP request to send to the server using an absolute URI, specifying a response handler to receive the response
Create an HTTP request to send to the server using an absolute URI, specifying a response handler to receive the response
- method
the HTTP method
- absoluteURI
the absolute URI
- responseHandler
the response handler
- returns
an HTTP client request object
-
def
requestAbs(method: HttpMethod, absoluteURI: String): HttpClientRequest
Create an HTTP request to send to the server using an absolute URI
Create an HTTP request to send to the server using an absolute URI
- method
the HTTP method
- absoluteURI
the absolute URI
- returns
an HTTP client request object
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
def
websocket(requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket at the relative request URI using the default host and port, the specified headers, the specified version of WebSockets and the specified sub protocols
Connect a WebSocket at the relative request URI using the default host and port, the specified headers, the specified version of WebSockets and the specified sub protocols
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket at the relative request URI using the default host and port, the specified headers, the specified version of WebSockets and the specified sub protocols
Connect a WebSocket at the relative request URI using the default host and port, the specified headers, the specified version of WebSockets and the specified sub protocols
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(requestURI: String, headers: MultiMap, version: WebsocketVersion, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket at the relative request URI using the default host and port, the specified headers and the specified version of WebSockets
Connect a WebSocket at the relative request URI using the default host and port, the specified headers and the specified version of WebSockets
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(requestURI: String, headers: MultiMap, version: WebsocketVersion, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket at the relative request URI using the default host and port, the specified headers and the specified version of WebSockets
Connect a WebSocket at the relative request URI using the default host and port, the specified headers and the specified version of WebSockets
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(requestURI: String, headers: MultiMap, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket at the relative request URI using the default host and port and the specified headers
Connect a WebSocket at the relative request URI using the default host and port and the specified headers
- requestURI
the relative URI
- headers
the headers
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(requestURI: String, headers: MultiMap, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket at the relative request URI using the default host and port and the specified headers
Connect a WebSocket at the relative request URI using the default host and port and the specified headers
- requestURI
the relative URI
- headers
the headers
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(requestURI: String, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket at the relative request URI using the default host and port
Connect a WebSocket at the relative request URI using the default host and port
- requestURI
the relative URI
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(requestURI: String, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket at the relative request URI using the default host and port
Connect a WebSocket at the relative request URI using the default host and port
- requestURI
the relative URI
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket to the specified host, relative request URI and default port, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Connect a WebSocket to the specified host, relative request URI and default port, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket to the specified host, relative request URI and default port, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Connect a WebSocket to the specified host, relative request URI and default port, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(port: Int, host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket to the specified port, host and relative request URI, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Connect a WebSocket to the specified port, host and relative request URI, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(options: RequestOptions, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket with the specified options, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Connect a WebSocket with the specified options, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- options
the request optionssee RequestOptions
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(port: Int, host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket to the specified port, host and relative request URI, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Connect a WebSocket to the specified port, host and relative request URI, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(options: RequestOptions, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket with the specified options, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Connect a WebSocket with the specified options, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- options
the request optionssee RequestOptions
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket to the specified host, relative request URI and default port with the specified headers and using the specified version of WebSockets
Connect a WebSocket to the specified host, relative request URI and default port with the specified headers and using the specified version of WebSockets
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket to the specified host, relative request URI and default port with the specified headers and using the specified version of WebSockets
Connect a WebSocket to the specified host, relative request URI and default port with the specified headers and using the specified version of WebSockets
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(port: Int, host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket to the specified port, host and relative request URI, with the specified headers and using the specified version of WebSockets
Connect a WebSocket to the specified port, host and relative request URI, with the specified headers and using the specified version of WebSockets
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(options: RequestOptions, headers: MultiMap, version: WebsocketVersion, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket with the specified options, with the specified headers and using the specified version of WebSockets
Connect a WebSocket with the specified options, with the specified headers and using the specified version of WebSockets
- options
the request optionssee RequestOptions
- headers
the headers
- version
the websocket version
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(port: Int, host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket to the specified port, host and relative request URI, with the specified headers and using the specified version of WebSockets
Connect a WebSocket to the specified port, host and relative request URI, with the specified headers and using the specified version of WebSockets
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(options: RequestOptions, headers: MultiMap, version: WebsocketVersion, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket with the specified optionsI, with the specified headers and using the specified version of WebSockets
Connect a WebSocket with the specified optionsI, with the specified headers and using the specified version of WebSockets
- options
the request optionssee RequestOptions
- headers
the headers
- version
the websocket version
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(host: String, requestURI: String, headers: MultiMap, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket to the specified host,relative request UR, and default port and with the specified headers
Connect a WebSocket to the specified host,relative request UR, and default port and with the specified headers
- host
the host
- requestURI
the relative URI
- headers
the headers
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(host: String, requestURI: String, headers: MultiMap, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket to the specified host,relative request UR, and default port and with the specified headers
Connect a WebSocket to the specified host,relative request UR, and default port and with the specified headers
- host
the host
- requestURI
the relative URI
- headers
the headers
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(port: Int, host: String, requestURI: String, headers: MultiMap, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket to the specified port, host and relative request URI, and with the specified headers
Connect a WebSocket to the specified port, host and relative request URI, and with the specified headers
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(options: RequestOptions, headers: MultiMap, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket with the specified options, and with the specified headers
Connect a WebSocket with the specified options, and with the specified headers
- options
the request optionssee RequestOptions
- headers
the headers
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(port: Int, host: String, requestURI: String, headers: MultiMap, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket to the specified port, host and relative request URI, and with the specified headers
Connect a WebSocket to the specified port, host and relative request URI, and with the specified headers
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(options: RequestOptions, headers: MultiMap, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket with the specified options, and with the specified headers
Connect a WebSocket with the specified options, and with the specified headers
- options
the request optionssee RequestOptions
- headers
the headers
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(host: String, requestURI: String, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket to the host and relative request URI and default port
Connect a WebSocket to the host and relative request URI and default port
- host
the host
- requestURI
the relative URI
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(host: String, requestURI: String, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket to the host and relative request URI and default port
Connect a WebSocket to the host and relative request URI and default port
- host
the host
- requestURI
the relative URI
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(port: Int, host: String, requestURI: String, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket to the specified port, host and relative request URI
Connect a WebSocket to the specified port, host and relative request URI
- port
the port
- host
the host
- requestURI
the relative URI
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(options: RequestOptions, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket with the specified options
Connect a WebSocket with the specified options
- options
the request optionssee RequestOptions
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocket(port: Int, host: String, requestURI: String, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket to the specified port, host and relative request URI
Connect a WebSocket to the specified port, host and relative request URI
- port
the port
- host
the host
- requestURI
the relative URI
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocket(options: RequestOptions, wsConnect: Handler[WebSocket]): HttpClient
Connect a WebSocket with the specified options
Connect a WebSocket with the specified options
- options
the request optionssee RequestOptions
- wsConnect
handler that will be called with the websocket when connected
- returns
a reference to this, so the API can be used fluently
-
def
websocketAbs(url: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String, wsConnect: Handler[WebSocket], failureHandler: Handler[Throwable]): HttpClient
Connect a WebSocket with the specified absolute url, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols.
Connect a WebSocket with the specified absolute url, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols.
- url
the absolute url
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- wsConnect
handler that will be called with the websocket when connected
- failureHandler
handler that will be called if websocket connection fails
- returns
a reference to this, so the API can be used fluently
-
def
websocketStream(requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String): ReadStream[WebSocket]
Create a WebSocket stream at the relative request URI using the default host and port, the specified headers, the specified version of WebSockets and the specified sub protocols
Create a WebSocket stream at the relative request URI using the default host and port, the specified headers, the specified version of WebSockets and the specified sub protocols
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(requestURI: String, headers: MultiMap, version: WebsocketVersion): ReadStream[WebSocket]
Create a WebSocket stream at the relative request URI using the default host and port, the specified headers and the specified version of WebSockets
Create a WebSocket stream at the relative request URI using the default host and port, the specified headers and the specified version of WebSockets
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(requestURI: String, headers: MultiMap): ReadStream[WebSocket]
Create a WebSocket stream at the relative request URI using the default host and port and the specified headers
Create a WebSocket stream at the relative request URI using the default host and port and the specified headers
- requestURI
the relative URI
- headers
the headers
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(requestURI: String): ReadStream[WebSocket]
Create a WebSocket stream at the relative request URI using the default host and port and the specified headers
Create a WebSocket stream at the relative request URI using the default host and port and the specified headers
- requestURI
the relative URI
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String): ReadStream[WebSocket]
Create a WebSocket stream to the specified host, relative request URI and default port, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Create a WebSocket stream to the specified host, relative request URI and default port, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(port: Int, host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String): ReadStream[WebSocket]
Create a WebSocket stream to the specified port, host and relative request URI, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Create a WebSocket stream to the specified port, host and relative request URI, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(options: RequestOptions, headers: MultiMap, version: WebsocketVersion, subProtocols: String): ReadStream[WebSocket]
Create a WebSocket stream to the specified port, host and relative request URI, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
Create a WebSocket stream to the specified port, host and relative request URI, with the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols
- options
the request optionssee RequestOptions
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion): ReadStream[WebSocket]
Create a WebSocket stream with the specified options and with the specified headers and using the specified version of WebSockets
Create a WebSocket stream with the specified options and with the specified headers and using the specified version of WebSockets
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(port: Int, host: String, requestURI: String, headers: MultiMap, version: WebsocketVersion): ReadStream[WebSocket]
Create a WebSocket stream to the specified port, host and relative request URI, with the specified headers and using the specified version of WebSockets
Create a WebSocket stream to the specified port, host and relative request URI, with the specified headers and using the specified version of WebSockets
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- version
the websocket version
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(options: RequestOptions, headers: MultiMap, version: WebsocketVersion): ReadStream[WebSocket]
Create a WebSocket stream with the specified options, with the specified headers and using the specified version of WebSockets
Create a WebSocket stream with the specified options, with the specified headers and using the specified version of WebSockets
- options
the request optionssee RequestOptions
- headers
the headers
- version
the websocket version
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(host: String, requestURI: String, headers: MultiMap): ReadStream[WebSocket]
Create a WebSocket stream to the specified host, relative request URI and default port and with the specified headers
Create a WebSocket stream to the specified host, relative request URI and default port and with the specified headers
- host
the host
- requestURI
the relative URI
- headers
the headers
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(port: Int, host: String, requestURI: String, headers: MultiMap): ReadStream[WebSocket]
Create a WebSocket stream to the specified port, host and relative request URI, and with the specified headers
Create a WebSocket stream to the specified port, host and relative request URI, and with the specified headers
- port
the port
- host
the host
- requestURI
the relative URI
- headers
the headers
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(options: RequestOptions, headers: MultiMap): ReadStream[WebSocket]
Create a WebSocket stream with the specified options, and with the specified headers
Create a WebSocket stream with the specified options, and with the specified headers
- options
the request optionssee RequestOptions
- headers
the headers
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(host: String, requestURI: String): ReadStream[WebSocket]
Create a WebSocket stream to the specified host, relative request URI and default port
Create a WebSocket stream to the specified host, relative request URI and default port
- host
the host
- requestURI
the relative URI
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(port: Int, host: String, requestURI: String): ReadStream[WebSocket]
Create a WebSocket stream to the specified port, host and relative request URI
Create a WebSocket stream to the specified port, host and relative request URI
- port
the port
- host
the host
- requestURI
the relative URI
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStream(options: RequestOptions): ReadStream[WebSocket]
Create a WebSocket stream with the specified options
Create a WebSocket stream with the specified options
- options
the request optionssee RequestOptions
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket
-
def
websocketStreamAbs(url: String, headers: MultiMap, version: WebsocketVersion, subProtocols: String): ReadStream[WebSocket]
Create a WebSocket stream with the specified absolute url, the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols.
Create a WebSocket stream with the specified absolute url, the specified headers, using the specified version of WebSockets, and the specified websocket sub protocols.
- url
the absolute url
- headers
the headers
- version
the websocket version
- subProtocols
the subprotocols to use
- returns
a stream emitting a WebSocket event when the client connection has been upgraded to a websocket