Class GlossaryAuthorViewRestClient
java.lang.Object
org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClientBase
org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClient
org.odpi.openmetadata.viewservices.glossaryauthor.fvt.client.GlossaryAuthorViewRestClient
-
Field Summary
Fields inherited from class org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClientBase
auditLog, exceptionHandler
-
Constructor Summary
ConstructorDescriptionGlossaryAuthorViewRestClient
(String serverName, String serverPlatformURLRoot) -
Method Summary
Modifier and TypeMethodDescriptioncreateFindQuery
(String methodName, FindRequest findRequest) Method for constructing a query (https://en.wikipedia.org/wiki/Query_string) using the information described in the findRequest page size and startingFrom need to set by the caller.createFindQuery
(String methodName, FindRequest findRequest, boolean exactValue, boolean ignoreCase) createFindQuery
(String methodName, FindRequest findRequest, QueryParams queryParams) Method for constructing a query (https://en.wikipedia.org/wiki/Query_string) using the information described in the findRequest page size and startingFrom need to set by the caller.<T> GenericResponse<T>
delRESTCall
(String userId, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, String methodName, String urnTemplate, String guid) Issue a DEL REST call that returns a response object.<T> GenericResponse<T>
findRESTCall
(String userId, String methodName, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, FindRequest findRequest, boolean exactValue, boolean ignoreCase, Integer maximumPageSizeOnRestCall) Issue a GET REST call that does a find and returns results in a Generic Response.<T> GenericResponse<T>
findRESTCallById
(String userId, String methodName, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, FindRequest findRequest, boolean exactValue, boolean ignoreCase, Integer maximumPageSizeOnRestCall, String guid) Issue a GET REST call that does a find and returns results in a Generic Response.<T> GenericResponse<T>
getByGUIdRESTCall
(String userId, String guid, String methodName, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String urnTemplate) Issue a GET REST call that returns a response object by guid.<T> GenericResponse<T>
getByIdRESTCall
(String userId, String guid, String methodName, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String urnTemplate) Issue a GET REST call that returns a response object by guid.<T> GenericResponse<T>
getByIdRESTCall
(String userId, String guid, String methodName, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String urnTemplate, FindRequest findRequest, Integer maximumPageSizeOnRestCall, Map<String, String> params) Issue a GET REST call that returns a response object by guid.<T> GenericResponse<T>
getByIdRESTCall
(String userId, String guid, String methodName, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String urnTemplate, FindRequest findRequest, Integer maximumPageSizeOnRestCall, QueryParams queryParams) Issue a GET REST call that returns a response object by guid.getConfigRESTCall
(String userId, String guid, String methodName, Class<OMAGServerConfigResponse> type, String urnTemplate) Issue a GET REST call that returns a Config object by guid.getViewConfigRESTCall
(String userId, String methodName, Class<ViewServicesResponse> type, String urnTemplate) Issue a GET REST call that returns a View Config object by guid.getViewServiceConfigRESTCall
(String userId, String guid, String methodName, Class<ViewServiceConfigResponse> type, String urnTemplate) Issue a GET REST call that returns a View Config object by guid.<T> GenericResponse<T>
postRESTCall
(String userId, String methodName, String urlTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String guid) Issue a POST REST call that returns a response object.<T> GenericResponse<T>
postRESTCall
(String userId, String create, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, T t) Issue a POST REST call that returns a response object.postRESTCallArr
(String userId, String methodName, String urlTemplate, String guid, org.springframework.core.ParameterizedTypeReference<SubjectAreaOMASAPIResponse<SubjectAreaOMASAPIResponse<Term>>> type, Term[] termArray) Issue a POST REST call that returns a response array.<T> GenericResponse<T>
putRESTCall
(String userId, String guid, String methodName, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, Category category, Object... params) Issue a PUT REST call that returns a response object.<T> GenericResponse<T>
putRESTCall
(String userId, String guid, String methodName, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, Glossary glossary, Object... params) Issue a PUT REST call that returns a response object.<T> GenericResponse<T>
putRESTCall
(String userId, String guid, String methodName, String urlTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, T t) Issue a PUT REST call that returns a response object.Methods inherited from class org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClient
callBooleanGetRESTCall, callCountGetRESTCall, callGUIDGetRESTCall, callGUIDListGetRESTCall, callGUIDListPostRESTCall, callGUIDPostRESTCall, callNameListGetRESTCall, callOCFConnectorReportGetRESTCall, callStringMapGetRESTCall, callVoidGetRESTCall, callVoidPostRESTCall
Methods inherited from class org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClientBase
callDeleteRESTCall, callDeleteRESTCall, callGetRESTCall, callGetRESTCall, callGetRESTCallNoParams, callPostRESTCall, callPostRESTCall, callPostRESTCallNoParams, callPutRESTCall, callPutRESTCall
-
Field Details
-
invalidParameterHandler
-
-
Constructor Details
-
GlossaryAuthorViewRestClient
public GlossaryAuthorViewRestClient(String serverName, String serverPlatformURLRoot) throws InvalidParameterException - Throws:
InvalidParameterException
-
-
Method Details
-
getByIdRESTCall
public <T> GenericResponse<T> getByIdRESTCall(String userId, String guid, String methodName, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String urnTemplate) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Issue a GET REST call that returns a response object by guid.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the objectmethodName
- name of the method being called.type
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
getByGUIdRESTCall
public <T> GenericResponse<T> getByGUIdRESTCall(String userId, String guid, String methodName, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String urnTemplate) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Issue a GET REST call that returns a response object by guid.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the received objectmethodName
- name of the method being called.type
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
postRESTCall
public <T> GenericResponse<T> postRESTCall(String userId, String methodName, String urlTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String guid) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException Issue a POST REST call that returns a response object.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedmethodName
- name of the method being called.urlTemplate
- template of the URN for the REST API call with place-holders for the parameters.type
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
guid
- unique identifier of the object- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
postRESTCall
public <T> GenericResponse<T> postRESTCall(String userId, String create, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, T t) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException Issue a POST REST call that returns a response object. The object to be created is passed.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedcreate
- name of the action/method been called.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.parameterizedType
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
t
- object to be creates- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
postRESTCallArr
public SubjectAreaOMASAPIResponse<SubjectAreaOMASAPIResponse<Term>> postRESTCallArr(String userId, String methodName, String urlTemplate, String guid, org.springframework.core.ParameterizedTypeReference<SubjectAreaOMASAPIResponse<SubjectAreaOMASAPIResponse<Term>>> type, Term[] termArray) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException Issue a POST REST call that returns a response array. The array of objects to be created is passed.- Parameters:
userId
- unique identifier for requesting user, under which the request is performedmethodName
- name of the method being called.urlTemplate
- template of the URN for the REST API call with place-holders for the parameters.guid
- unique identifier of the glossary objecttype
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
termArray
- Array of terms to be creates- Returns:
- Array of type SubjectAreaOMASAPIResponse
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
putRESTCall
public <T> GenericResponse<T> putRESTCall(String userId, String guid, String methodName, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, Glossary glossary, Object... params) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException Issue a PUT REST call that returns a response object. The object to be updated is passed.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the objectmethodName
- name of the method being called.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.parameterizedType
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
glossary
- Glossary to be createsparams
- additional parameters to be passed- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
putRESTCall
public <T> GenericResponse<T> putRESTCall(String userId, String guid, String methodName, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, Category category, Object... params) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException Issue a PUT REST call that returns a response object. The object to be updated is passed.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the objectmethodName
- name of the method being called.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.parameterizedType
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
category
- Category to be createsparams
- additional parameters to be passed- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
putRESTCall
public <T> GenericResponse<T> putRESTCall(String userId, String guid, String methodName, String urlTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, T t) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException Issue a PUT REST call that returns a response object. The object to be updated is passed.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the objectmethodName
- name of the method being called.urlTemplate
- template of the URN for the REST API call with place-holders for the parameters.parameterizedType
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
t
- type of object to be creates- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
delRESTCall
public <T> GenericResponse<T> delRESTCall(String userId, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> parameterizedType, String methodName, String urnTemplate, String guid) throws PropertyServerException Issue a DEL REST call that returns a response object.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedparameterizedType
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
methodName
- name of the method being called.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.guid
- unique identifier of the object- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.
-
createFindQuery
public QueryBuilder createFindQuery(String methodName, FindRequest findRequest) throws InvalidParameterException Method for constructing a query (https://en.wikipedia.org/wiki/Query_string) using the information described in the findRequest page size and startingFrom need to set by the caller.- Parameters:
methodName
- name of the method being called.findRequest
-FindRequest
- Returns:
- query
- Throws:
InvalidParameterException
- one of the parameters is null or invalid
-
createFindQuery
public QueryBuilder createFindQuery(String methodName, FindRequest findRequest, boolean exactValue, boolean ignoreCase) throws InvalidParameterException - Throws:
InvalidParameterException
-
createFindQuery
public QueryBuilder createFindQuery(String methodName, FindRequest findRequest, QueryParams queryParams) throws InvalidParameterException Method for constructing a query (https://en.wikipedia.org/wiki/Query_string) using the information described in the findRequest page size and startingFrom need to set by the caller.- Parameters:
methodName
- name of the method being called.findRequest
-FindRequest
queryParams
- query parameters- Returns:
- query
- Throws:
InvalidParameterException
- one of the parameters is null or invalid
-
findRESTCall
public <T> GenericResponse<T> findRESTCall(String userId, String methodName, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, FindRequest findRequest, boolean exactValue, boolean ignoreCase, Integer maximumPageSizeOnRestCall) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Issue a GET REST call that does a find and returns results in a Generic Response.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedmethodName
- name of the method being called.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.type
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
findRequest
-FindRequest
exactValue
- boolean to determine search parameters should return exact valuesignoreCase
- boolean to determine search parameters should ignore case for teh search criterismaximumPageSizeOnRestCall
- Page size for results- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
findRESTCallById
public <T> GenericResponse<T> findRESTCallById(String userId, String methodName, String urnTemplate, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, FindRequest findRequest, boolean exactValue, boolean ignoreCase, Integer maximumPageSizeOnRestCall, String guid) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Issue a GET REST call that does a find and returns results in a Generic Response.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedmethodName
- name of the method being called.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.type
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
findRequest
-FindRequest
exactValue
- boolean to determine search parameters should return exact valuesignoreCase
- boolean to determine search parameters should ignore case for teh search criterismaximumPageSizeOnRestCall
- Page size for resultsguid
- Object guid- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
getByIdRESTCall
public <T> GenericResponse<T> getByIdRESTCall(String userId, String guid, String methodName, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String urnTemplate, FindRequest findRequest, Integer maximumPageSizeOnRestCall, Map<String, String> params) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedExceptionIssue a GET REST call that returns a response object by guid.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the objectmethodName
- name of the method being called.type
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.findRequest
-FindRequest
maximumPageSizeOnRestCall
- maximum page size that can be used on rest calls, null and 0 mean no limit set.params
- additional parameters to be passed- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
getByIdRESTCall
public <T> GenericResponse<T> getByIdRESTCall(String userId, String guid, String methodName, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String urnTemplate, FindRequest findRequest, Integer maximumPageSizeOnRestCall, QueryParams queryParams) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Issue a GET REST call that returns a response object by guid.- Type Parameters:
T
- return type for results inGenericResponse
- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the objectmethodName
- name of the method being called.type
- class of the response for generic object. Descried usingParameterizedTypeReference
An example can be seen hereResponseParameterization.getParameterizedType()
urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.findRequest
-FindRequest
maximumPageSizeOnRestCall
- maximum page size that can be used on rest calls, null and 0 mean no limit set.queryParams
- additional parameters to be passed- Returns:
- GenericResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
getConfigRESTCall
public OMAGServerConfigResponse getConfigRESTCall(String userId, String guid, String methodName, Class<OMAGServerConfigResponse> type, String urnTemplate) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Issue a GET REST call that returns a Config object by guid.- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the objectmethodName
- name of the method being called.type
- class of the response for generic object.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.- Returns:
- OMAGServerConfigResponse with T result
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
getViewServiceConfigRESTCall
public ViewServiceConfigResponse getViewServiceConfigRESTCall(String userId, String guid, String methodName, Class<ViewServiceConfigResponse> type, String urnTemplate) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Issue a GET REST call that returns a View Config object by guid.- Parameters:
userId
- unique identifier for requesting user, under which the request is performedguid
- unique identifier of the objectmethodName
- name of the method being called.type
- class of the response for generic object.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.- Returns:
- ViewServiceConfigResponse object
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-
getViewConfigRESTCall
public ViewServicesResponse getViewConfigRESTCall(String userId, String methodName, Class<ViewServicesResponse> type, String urnTemplate) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Issue a GET REST call that returns a View Config object by guid.- Parameters:
userId
- unique identifier for requesting user, under which the request is performedmethodName
- name of the method being called.type
- class of the response for generic object.urnTemplate
- template of the URN for the REST API call with place-holders for the parameters.- Returns:
- ViewServicesResponse
- Throws:
PropertyServerException
- something went wrong with the REST call stack.UserNotAuthorizedException
- the requesting user is not authorized to issue this request.InvalidParameterException
- one of the parameters is null or invalid
-