public abstract class BaseGenieClient
extends java.lang.Object
| Constructor and Description |
|---|
BaseGenieClient(java.lang.String url,
java.util.List<okhttp3.Interceptor> interceptors,
GenieNetworkConfiguration genieNetworkConfiguration)
Constructor that takes the service url and a security interceptor implementation.
|
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.String |
getIdFromLocation(java.lang.String location)
Helper method to parse the id out of the location string in the Header.
|
protected <T> T |
getService(java.lang.Class<T> clazz) |
protected <T> T |
treeToValue(com.fasterxml.jackson.databind.JsonNode node,
java.lang.Class<T> clazz) |
public BaseGenieClient(@NotEmpty
java.lang.String url,
@Nullable
java.util.List<okhttp3.Interceptor> interceptors,
@Nullable
GenieNetworkConfiguration genieNetworkConfiguration)
throws GenieClientException
url - The url of the Genie Service.interceptors - All desired interceptors for the client to be createdgenieNetworkConfiguration - A configuration object that provides network settings for HTTP calls.GenieClientException - If there is any problem creating the constructor.protected java.lang.String getIdFromLocation(java.lang.String location)
location - The location string in the header.protected <T> T getService(java.lang.Class<T> clazz)
protected <T> T treeToValue(com.fasterxml.jackson.databind.JsonNode node,
java.lang.Class<T> clazz)
throws java.io.IOException
java.io.IOException