public interface WebRequestor
HTTP
requests to the Facebook API
endpoint must operate.Modifier and Type | Interface and Description |
---|---|
static class |
WebRequestor.Response
Encapsulates an HTTP response body and status code.
|
Modifier and Type | Method and Description |
---|---|
WebRequestor.Response |
executeGet(String url)
Given a Facebook API endpoint URL, execute a
GET against it. |
WebRequestor.Response |
executePost(String url,
String parameters)
Given a Facebook API endpoint URL and parameter string, execute a
POST to the endpoint URL. |
WebRequestor.Response |
executePost(String url,
String parameters,
InputStream binaryAttachment)
Given a Facebook API endpoint URL and parameter string, execute a
POST to the endpoint URL. |
WebRequestor.Response executeGet(String url) throws IOException
GET
against it.url
- The URL to make a GET
request for, including URL
parameters.IOException
- If an error occurs while performing the GET
operation.WebRequestor.Response executePost(String url, String parameters) throws IOException
POST
to the endpoint URL.url
- The URL to POST
to.parameters
- The parameters to be POST
ed.IOException
- If an error occurs while performing the POST
.WebRequestor.Response executePost(String url, String parameters, InputStream binaryAttachment) throws IOException
POST
to the endpoint URL.url
- The URL to POST
to.parameters
- The parameters to be POST
ed.binaryAttachment
- A binary attachment to be included in the POST
body (e.g.
a photo).IOException
- If an error occurs while performing the POST
.Copyright © 2014. All rights reserved.