Package io.vertx.ext.web.api.service
Class ServiceRequest
- java.lang.Object
-
- io.vertx.ext.web.api.service.ServiceRequest
-
public class ServiceRequest extends Object
Data object that encapsulates all informations about an HTTP Request
-
-
Constructor Summary
Constructors Constructor Description ServiceRequest()
ServiceRequest(JsonObject json)
ServiceRequest(JsonObject params, MultiMap headers, JsonObject user, JsonObject extra)
ServiceRequest(ServiceRequest other)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description JsonObject
getExtra()
Get extra payloadMultiMap
getHeaders()
Get request headersJsonObject
getParams()
Get request parsedParameters as JSONJsonObject
getUser()
Get request principal user as routingContext.user().principal(), null if no user is authenticatedServiceRequest
setExtra(JsonObject extra)
ServiceRequest
setHeaders(MultiMap headers)
ServiceRequest
setParams(JsonObject params)
ServiceRequest
setUser(JsonObject user)
JsonObject
toJson()
-
-
-
Constructor Detail
-
ServiceRequest
public ServiceRequest()
-
ServiceRequest
public ServiceRequest(JsonObject json)
-
ServiceRequest
public ServiceRequest(JsonObject params, MultiMap headers, JsonObject user, JsonObject extra)
-
ServiceRequest
public ServiceRequest(ServiceRequest other)
-
-
Method Detail
-
toJson
public JsonObject toJson()
-
getParams
public JsonObject getParams()
Get request parsedParameters as JSON
-
getHeaders
public MultiMap getHeaders()
Get request headers
-
getUser
public JsonObject getUser()
Get request principal user as routingContext.user().principal(), null if no user is authenticated
-
getExtra
public JsonObject getExtra()
Get extra payload- Returns:
-
setParams
public ServiceRequest setParams(JsonObject params)
-
setHeaders
public ServiceRequest setHeaders(MultiMap headers)
-
setUser
public ServiceRequest setUser(JsonObject user)
-
setExtra
public ServiceRequest setExtra(JsonObject extra)
-
-