public class FFDCRESTClientBase extends Object
| Modifier and Type | Field and Description |
|---|---|
protected AuditLog |
auditLog |
protected RESTExceptionHandler |
exceptionHandler |
protected String |
serverName |
protected String |
serverPlatformURLRoot |
| Modifier | Constructor and Description |
|---|---|
protected |
FFDCRESTClientBase(String serverName,
String serverPlatformURLRoot)
Constructor for no authentication.
|
protected |
FFDCRESTClientBase(String serverName,
String serverPlatformURLRoot,
AuditLog auditLog)
Constructor for no authentication with audit log.
|
protected |
FFDCRESTClientBase(String serverName,
String serverPlatformURLRoot,
String userId,
String password)
Constructor for simple userId and password authentication.
|
protected |
FFDCRESTClientBase(String serverName,
String serverPlatformURLRoot,
String userId,
String password,
AuditLog auditLog)
Constructor for simple userId and password authentication with audit log.
|
| Modifier and Type | Method and Description |
|---|---|
protected <T> T |
callDeleteRESTCall(String methodName,
Class<T> returnClass,
String urlTemplate,
Object... params)
Issue a Delete REST call that returns a response object.
|
protected <T> T |
callDeleteRESTCall(String methodName,
org.springframework.core.ParameterizedTypeReference<T> responseType,
String urlTemplate,
Object... params)
Issue a Delete REST call that returns a response object.
|
protected <T> T |
callGetRESTCall(String methodName,
Class<T> returnClass,
String urlTemplate,
Object... params)
Issue a GET REST call that returns a response object.
|
protected <T> T |
callGetRESTCall(String methodName,
org.springframework.core.ParameterizedTypeReference<T> responseType,
String urlTemplate,
Object... params)
Issue a GET REST call that returns a response object.
|
protected <T> T |
callGetRESTCallNoParams(String methodName,
Class<T> returnClass,
String urlTemplate)
Issue a GET REST call that returns a response object.
|
protected <T> T |
callPostRESTCall(String methodName,
Class<T> returnClass,
String urlTemplate,
Object requestBody,
Object... params)
Issue a POST REST call that returns a response object.
|
protected <T> T |
callPostRESTCall(String methodName,
org.springframework.core.ParameterizedTypeReference<T> responseType,
String urlTemplate,
Object requestBody,
Object... params)
Issue a POST REST call that returns a response object.
|
protected <T> T |
callPostRESTCallNoParams(String methodName,
Class<T> returnClass,
String urlTemplate,
Object requestBody)
Issue a POST REST call that returns a response object.
|
protected <T> T |
callPutRESTCall(String methodName,
Class<T> returnClass,
String urlTemplate,
Object requestBody,
Object... params)
Issue a PUT REST call that returns a response object.
|
protected <T> T |
callPutRESTCall(String methodName,
org.springframework.core.ParameterizedTypeReference<T> responseType,
String urlTemplate,
Object requestBody,
Object... params)
Issue a PUT REST call that returns a response object.
|
protected String serverName
protected String serverPlatformURLRoot
protected AuditLog auditLog
protected RESTExceptionHandler exceptionHandler
protected FFDCRESTClientBase(String serverName, String serverPlatformURLRoot, AuditLog auditLog) throws InvalidParameterException
serverName - name of the OMAG Server to callserverPlatformURLRoot - URL root of the server platform where the OMAG Server is running.auditLog - destination for log messages.InvalidParameterException - there is a problem creating the client-side components to issue any
REST API calls.protected FFDCRESTClientBase(String serverName, String serverPlatformURLRoot) throws InvalidParameterException
serverName - name of the OMAG Server to callserverPlatformURLRoot - URL root of the server platform where the OMAG Server is running.InvalidParameterException - there is a problem creating the client-side components to issue any
REST API calls.protected FFDCRESTClientBase(String serverName, String serverPlatformURLRoot, String userId, String password, AuditLog auditLog) throws InvalidParameterException
serverName - name of the OMAG Server to callserverPlatformURLRoot - URL root of the server platform where the OMAG Server is running.userId - user id for the HTTP requestpassword - password for the HTTP requestauditLog - destination for log messages.InvalidParameterException - there is a problem creating the client-side components to issue any
REST API calls.protected FFDCRESTClientBase(String serverName, String serverPlatformURLRoot, String userId, String password) throws InvalidParameterException
serverName - name of the OMAG Server to callserverPlatformURLRoot - URL root of the server platform where the OMAG Server is running.userId - user id for the HTTP requestpassword - password for the HTTP requestInvalidParameterException - there is a problem creating the client-side components to issue any
REST API calls.protected <T> T callGetRESTCallNoParams(String methodName, Class<T> returnClass, String urlTemplate) throws PropertyServerException
T - return typemethodName - name of the method being called.returnClass - class of the response object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.PropertyServerException - something went wrong with the REST call stack.protected <T> T callGetRESTCall(String methodName, Class<T> returnClass, String urlTemplate, Object... params) throws PropertyServerException
T - return typemethodName - name of the method being called.returnClass - class of the response object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.params - a list of parameters that are slotted into the url template.PropertyServerException - something went wrong with the REST call stack.protected <T> T callGetRESTCall(String methodName, org.springframework.core.ParameterizedTypeReference<T> responseType, String urlTemplate, Object... params) throws PropertyServerException
SpringRESTClientConnectorT - return typemethodName - name of the method being called.responseType - class of the response object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.params - a list of parameters that are slotted into the url template.PropertyServerException - something went wrong with the REST call stack.protected <T> T callPostRESTCallNoParams(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody) throws PropertyServerException
T - return typemethodName - name of the method being called.returnClass - class of the response object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.requestBody - request body for the request.PropertyServerException - something went wrong with the REST call stack.protected <T> T callPostRESTCall(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody, Object... params) throws PropertyServerException
T - return typemethodName - name of the method being called.returnClass - class of the response object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.requestBody - request body for the request.params - a list of parameters that are slotted into the url template.PropertyServerException - something went wrong with the REST call stack.protected <T> T callPostRESTCall(String methodName, org.springframework.core.ParameterizedTypeReference<T> responseType, String urlTemplate, Object requestBody, Object... params) throws PropertyServerException
SpringRESTClientConnectorT - return typemethodName - name of the method being called.responseType - class of the response for generic object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.requestBody - request body for the request.params - a list of parameters that are slotted into the url template.PropertyServerException - something went wrong with the REST call stack.protected <T> T callPutRESTCall(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody, Object... params) throws PropertyServerException
T - return typemethodName - name of the method being called.returnClass - class of the response object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.requestBody - request body for the request.params - a list of parameters that are slotted into the url template.PropertyServerException - something went wrong with the REST call stack.protected <T> T callPutRESTCall(String methodName, org.springframework.core.ParameterizedTypeReference<T> responseType, String urlTemplate, Object requestBody, Object... params) throws PropertyServerException
SpringRESTClientConnectorT - return typemethodName - name of the method being called.responseType - class of the response for generic object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.requestBody - request body for the request.params - a list of parameters that are slotted into the url template.PropertyServerException - something went wrong with the REST call stack.protected <T> T callDeleteRESTCall(String methodName, Class<T> returnClass, String urlTemplate, Object... params) throws PropertyServerException
T - return typemethodName - name of the method being called.returnClass - class of the response object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.params - a list of parameters that are slotted into the url template.PropertyServerException - something went wrong with the REST call stack.protected <T> T callDeleteRESTCall(String methodName, org.springframework.core.ParameterizedTypeReference<T> responseType, String urlTemplate, Object... params) throws PropertyServerException
T - return typemethodName - name of the method being called.responseType - class of the response for generic object.urlTemplate - template of the URL for the REST API call with place-holders for the parameters.params - a list of parameters that are slotted into the url template.PropertyServerException - something went wrong with the REST call stack.Copyright © 2018–2020 ODPi. All rights reserved.