Uses of Class
com.google.api.client.http.HttpRequest
Packages that use HttpRequest
Package
Description
Subset of HTTP 1.1 needed from the specification in RFC 2616: Hypertext Transfer Protocol -- HTTP/1.1.
Beta
Testing utilities used for writing tests based on this library.
-
Uses of HttpRequest in com.google.api.client.http
Fields in com.google.api.client.http declared as HttpRequestMethods in com.google.api.client.http that return HttpRequestModifier and TypeMethodDescriptionHttpRequestFactory.buildDeleteRequest
(GenericUrl url) Builds aDELETE
request for the given URL.HttpRequestFactory.buildGetRequest
(GenericUrl url) Builds aGET
request for the given URL.HttpRequestFactory.buildHeadRequest
(GenericUrl url) Builds aHEAD
request for the given URL.HttpRequestFactory.buildPatchRequest
(GenericUrl url, HttpContent content) Builds aPATCH
request for the given URL and content.HttpRequestFactory.buildPostRequest
(GenericUrl url, HttpContent content) Builds aPOST
request for the given URL and content.HttpRequestFactory.buildPutRequest
(GenericUrl url, HttpContent content) Builds aPUT
request for the given URL and content.HttpRequestFactory.buildRequest
(String requestMethod, GenericUrl url, HttpContent content) Builds a request for the given HTTP method, URL, and content.(package private) HttpRequest
HttpTransport.buildRequest()
Builds a request without specifying the HTTP method.HttpResponse.getRequest()
Returns the HTTP request.HttpRequest.setBackOffPolicy
(BackOffPolicy backOffPolicy) Deprecated.(scheduled to be removed in 1.18).HttpRequest.setConnectTimeout
(int connectTimeout) Sets the timeout in milliseconds to establish a connection or0
for an infinite timeout.HttpRequest.setContent
(HttpContent content) Sets the HTTP request content ornull
for none.HttpRequest.setContentLoggingLimit
(int contentLoggingLimit) Set the limit to the content size that will be logged duringexecute()
.HttpRequest.setCurlLoggingEnabled
(boolean curlLoggingEnabled) Sets whether logging in form of curl commands should be enabled for this request.HttpRequest.setEncoding
(HttpEncoding encoding) Sets the HTTP content encoding ornull
for none.HttpRequest.setFollowRedirects
(boolean followRedirects) Sets whether to follow redirects automatically.HttpRequest.setHeaders
(HttpHeaders headers) Sets the HTTP request headers.HttpRequest.setInterceptor
(HttpExecuteInterceptor interceptor) Sets the HTTP request execute interceptor to intercept the start ofexecute()
(before executing the HTTP request) ornull
for none.HttpRequest.setIOExceptionHandler
(HttpIOExceptionHandler ioExceptionHandler) HttpRequest.setLoggingEnabled
(boolean loggingEnabled) Sets whether logging should be enabled for this request.HttpRequest.setNumberOfRetries
(int numRetries) Sets the number of retries that will be allowed to execute before the request will be terminated or0
to not retry requests.HttpRequest.setParser
(ObjectParser parser) Sets theObjectParser
used to parse the response to this request ornull
for none.HttpRequest.setReadTimeout
(int readTimeout) Sets the timeout in milliseconds to read data from an established connection or0
for an infinite timeout.HttpRequest.setRequestMethod
(String requestMethod) Sets the HTTP request method ornull
for none.HttpRequest.setResponseHeaders
(HttpHeaders responseHeaders) Sets the HTTP response headers.HttpRequest.setResponseInterceptor
(HttpResponseInterceptor responseInterceptor) Sets the HTTP response interceptor ornull
for none.HttpRequest.setRetryOnExecuteIOException
(boolean retryOnExecuteIOException) Deprecated.(scheduled to be removed in 1.18) UsesetIOExceptionHandler(HttpIOExceptionHandler)
instead.HttpRequest.setSleeper
(Sleeper sleeper) Sets the sleeper.HttpRequest.setSuppressUserAgentSuffix
(boolean suppressUserAgentSuffix) Sets whether to not add the suffixUSER_AGENT_SUFFIX
to the User-Agent header.HttpRequest.setThrowExceptionOnExecuteError
(boolean throwExceptionOnExecuteError) Sets whether to throw an exception at the end ofexecute()
on a HTTP error code (non-2XX) after all retries and response handlers have been exhausted.HttpRequest.setUnsuccessfulResponseHandler
(HttpUnsuccessfulResponseHandler unsuccessfulResponseHandler) Sets the HTTP unsuccessful (non-2XX) response handler ornull
for none.HttpRequest.setUrl
(GenericUrl url) Sets the HTTP request URL.Methods in com.google.api.client.http with parameters of type HttpRequestModifier and TypeMethodDescriptionstatic UrlEncodedContent
UrlEncodedContent.getContent
(HttpRequest request) Returns the URL-encoded content of the given HTTP request, or if none return and set as content a new instance ofUrlEncodedContent
(whoseUrlEncodedContent.getData()
is an implementation ofMap
).boolean
HttpBackOffIOExceptionHandler.handleIOException
(HttpRequest request, boolean supportsRetry) Invoked when anIOException
is thrown during an HTTP request.boolean
HttpIOExceptionHandler.handleIOException
(HttpRequest request, boolean supportsRetry) Invoked when anIOException
is thrown during an HTTP request.final boolean
HttpBackOffUnsuccessfulResponseHandler.handleResponse
(HttpRequest request, HttpResponse response, boolean supportsRetry) Handler that will be invoked when an abnormal response is received.boolean
HttpUnsuccessfulResponseHandler.handleResponse
(HttpRequest request, HttpResponse response, boolean supportsRetry) Handler that will be invoked when an abnormal response is received.void
BasicAuthentication.initialize
(HttpRequest request) void
HttpRequestInitializer.initialize
(HttpRequest request) Initializes a request.void
BasicAuthentication.intercept
(HttpRequest request) void
HttpExecuteInterceptor.intercept
(HttpRequest request) Invoked at the start ofexecute()
before executing the HTTP request.Constructors in com.google.api.client.http with parameters of type HttpRequestModifierConstructorDescription(package private)
HttpResponse
(HttpRequest request, LowLevelHttpResponse response) -
Uses of HttpRequest in com.google.api.client.testing.http
Methods in com.google.api.client.testing.http with parameters of type HttpRequestModifier and TypeMethodDescriptionboolean
MockHttpUnsuccessfulResponseHandler.handleResponse
(HttpRequest request, HttpResponse response, boolean supportsRetry)