public class Client extends Object
| Constructor and Description |
|---|
Client(String baseUrl,
com.sun.jersey.api.client.Client apiClient)
Constructor
|
Client(String baseUrl,
com.sun.jersey.api.client.Client apiClient,
com.google.common.cache.Cache cache)
Constructor that enables caching.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
getCachedGet(String url) |
Object |
getCachedPost(String url,
Object o) |
String |
getUrl(String path)
Returns the base url plus the path.
|
com.sun.jersey.api.client.WebResource |
resource(String path) |
void |
setCache(com.google.common.cache.Cache cache) |
void |
setCachedGet(String url,
Object o) |
void |
setCachedPost(String url,
Object o,
Object result) |
public Client(String baseUrl, com.sun.jersey.api.client.Client apiClient)
baseUrl - the api base urlapiClient - a preconfigured client (except auth)public Client(String baseUrl, com.sun.jersey.api.client.Client apiClient, com.google.common.cache.Cache cache)
baseUrl - the api base urlapiClient - a preconfigured client (except auth)cache - cache implementationpublic void setCache(com.google.common.cache.Cache cache)
public com.sun.jersey.api.client.WebResource resource(String path)
Copyright © 2015. All rights reserved.