public class OkHttpRequestAdapter extends Object implements oauth.signpost.http.HttpRequest
HttpRequest implementation that is backed by an OkHttp Request object. This is used by
oauth-signpost to read the Request and sign it.| Constructor and Description |
|---|
OkHttpRequestAdapter(com.squareup.okhttp.Request request)
Constructs a new
OkHttpRequestAdapter. |
| Modifier and Type | Method and Description |
|---|---|
Map<String,String> |
getAllHeaders() |
String |
getContentType() |
String |
getHeader(String key) |
InputStream |
getMessagePayload() |
String |
getMethod() |
String |
getRequestUrl() |
void |
setHeader(String key,
String value) |
void |
setRequestUrl(String url) |
Object |
unwrap() |
public OkHttpRequestAdapter(com.squareup.okhttp.Request request)
OkHttpRequestAdapter.request - the Request that is to be signed.public Map<String,String> getAllHeaders()
getAllHeaders in interface oauth.signpost.http.HttpRequestpublic String getContentType()
getContentType in interface oauth.signpost.http.HttpRequestpublic String getHeader(String key)
getHeader in interface oauth.signpost.http.HttpRequestpublic InputStream getMessagePayload() throws IOException
getMessagePayload in interface oauth.signpost.http.HttpRequestIOExceptionpublic String getMethod()
getMethod in interface oauth.signpost.http.HttpRequestpublic String getRequestUrl()
getRequestUrl in interface oauth.signpost.http.HttpRequestpublic void setHeader(String key, String value)
setHeader in interface oauth.signpost.http.HttpRequestpublic void setRequestUrl(String url)
setRequestUrl in interface oauth.signpost.http.HttpRequestpublic Object unwrap()
unwrap in interface oauth.signpost.http.HttpRequestCopyright © 2015. All rights reserved.