|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.aetrion.flickr.Transport
com.aetrion.flickr.REST
public class REST
Transport implementation using the REST interface.
| Field Summary | |
|---|---|
static java.lang.String |
PATH
|
| Fields inherited from class com.aetrion.flickr.Transport |
|---|
responseClass, REST, SOAP |
| Constructor Summary | |
|---|---|
REST()
Construct a new REST transport instance. |
|
REST(java.lang.String host)
Construct a new REST transport instance using the specified host endpoint. |
|
REST(java.lang.String host,
int port)
Construct a new REST transport instance using the specified host and port endpoint. |
|
| Method Summary | |
|---|---|
Response |
get(java.lang.String path,
java.util.List parameters)
Invoke an HTTP GET request on a remote host. |
java.lang.String |
getProxyCredentials()
Generates Base64-encoded credentials from locally stored username and password. |
boolean |
isProxyAuth()
|
Response |
post(java.lang.String path,
java.util.List parameters,
boolean multipart)
Invoke an HTTP POST request on a remote host. |
void |
setProxy(java.lang.String proxyHost,
int proxyPort)
Set a proxy for REST-requests. |
void |
setProxy(java.lang.String proxyHost,
int proxyPort,
java.lang.String username,
java.lang.String password)
Set a proxy with authentication for REST-requests. |
| Methods inherited from class com.aetrion.flickr.Transport |
|---|
getHost, getPath, getPort, getResponseClass, getTransportType, post, setHost, setPath, setPort, setResponseClass, setTransportType |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String PATH
| Constructor Detail |
|---|
public REST()
throws javax.xml.parsers.ParserConfigurationException
javax.xml.parsers.ParserConfigurationException
public REST(java.lang.String host)
throws javax.xml.parsers.ParserConfigurationException
host - The host endpoint
javax.xml.parsers.ParserConfigurationException
public REST(java.lang.String host,
int port)
throws javax.xml.parsers.ParserConfigurationException
host - The host endpointport - The port
javax.xml.parsers.ParserConfigurationException| Method Detail |
|---|
public void setProxy(java.lang.String proxyHost,
int proxyPort)
proxyHost - proxyPort -
public void setProxy(java.lang.String proxyHost,
int proxyPort,
java.lang.String username,
java.lang.String password)
proxyHost - proxyPort - username - password -
public Response get(java.lang.String path,
java.util.List parameters)
throws java.io.IOException,
org.xml.sax.SAXException
get in class Transportpath - The request pathparameters - The parameters (collection of Parameter objects)
java.io.IOException
org.xml.sax.SAXException
public Response post(java.lang.String path,
java.util.List parameters,
boolean multipart)
throws java.io.IOException,
org.xml.sax.SAXException
post in class Transportpath - The request pathparameters - The parameters (collection of Parameter objects)multipart - Use multipart
java.io.IOException
org.xml.sax.SAXExceptionpublic boolean isProxyAuth()
public java.lang.String getProxyCredentials()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||