public class ResponseBuilder extends Object
Constructor and Description |
---|
ResponseBuilder(org.apache.http.client.HttpClient httpClient) |
Modifier and Type | Method and Description |
---|---|
<T extends AbstractJsonMapping> |
getResponse(Class<T> clazz,
Map<String,String> properties)
Get the wrapper for the passed properties
Will retry up to retry limit
|
void |
setRetryDelay(long retryDelay)
Set the delay time between API retries when the account is over it's
limit
|
void |
setRetryLimit(int retryLimit)
Number of times to retry the API call when the account limit is hit.
|
public ResponseBuilder(org.apache.http.client.HttpClient httpClient)
public void setRetryDelay(long retryDelay)
retryDelay
- milliseconds to delay for, default is 500mspublic void setRetryLimit(int retryLimit)
retryLimit
- Number of retries, default is 5public <T extends AbstractJsonMapping> T getResponse(Class<T> clazz, Map<String,String> properties) throws RottenTomatoesException
T
- clazz
- properties
- RottenTomatoesException
Copyright © 2012–2017. All rights reserved.