public class HttpRequest extends Object
| Constructor and Description |
|---|
HttpRequest(URI uri)
Creates
HttpRequest with provided uri and GET method. |
HttpRequest(URI uri,
String method)
Creates
HttpRequest with provided uri and method. |
HttpRequest(URI uri,
String method,
HttpHeaders headers)
Creates
HttpRequest with provided uri, method and headers. |
| Modifier and Type | Method and Description |
|---|---|
HttpHeaders |
getHeaders()
Gets the headers of this request.
|
String |
getMethod()
Gets the HTTP method of the request.
|
URI |
getUri()
Gets the URI of the request.
|
String |
toString() |
public HttpRequest(URI uri)
HttpRequest with provided uri and GET method.uri - uri of the requestpublic HttpRequest(URI uri, String method)
HttpRequest with provided uri and method.uri - uri of the requestmethod - HTTP methodpublic HttpRequest(URI uri, String method, HttpHeaders headers)
HttpRequest with provided uri, method and headers.uri - uri of the requestmethod - HTTP methodheaders - HTTP headerspublic URI getUri()
public String getMethod()
public HttpHeaders getHeaders()
Copyright © 2023. All rights reserved.