Class GlossaryAuthorViewRelationshipsClient
- java.lang.Object
-
- org.odpi.openmetadata.viewservices.glossaryauthor.fvt.client.relationships.GlossaryAuthorViewRelationshipsClient
-
- All Implemented Interfaces:
ResponseParameterization<Relationship>,GlossaryAuthorViewRelationships
public class GlossaryAuthorViewRelationshipsClient extends Object implements GlossaryAuthorViewRelationships, ResponseParameterization<Relationship>
The class acts as a wrapper class for calling the REST services for Glossary Author Relationship related services.
-
-
Field Summary
Fields Modifier and Type Field Description protected GlossaryAuthorViewRestClientclient
-
Constructor Summary
Constructors Constructor Description GlossaryAuthorViewRelationshipsClient(GlossaryAuthorViewRestClient client)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Relationshipcreate(String userId, Relationship relationship)Create a Relationship.<T> TcreateRel(String userId, T t, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType)SynonymcreateSynonym(String userId, Synonym synonym)voiddelete(String userId, String guid)Delete a Relationship.<T> voiddeleteRel(String userId, String guid, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType)List<Relationship>find(String userId, FindRequest findRequest, boolean exactValue, boolean ignoreCase)Extract children within a RelationshipList<Relationship>findAll(String userId)Find CategoryRelationshipgetByGUID(String userId, String guid)Get a Relationship.List<Category>getCategories(String userId, String termGuid, FindRequest findRequest)Extract categories for a RelationshipList<Category>getCategoryChildren(String userId, String parentGuid, FindRequest findRequest, boolean exactValue, boolean ignoreCase)Extract children within a CategoryOMAGServerConfiggetConfig(String userId)Get config for serverViewServiceConfiggetGlossaryAuthViewServiceConfig(String userId)Get service config for a particular view Serviceprotected StringgetMethodInfo(String methodName)<T> TgetRel(String userId, String guid, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType)SynonymgetSynonym(String userId, String guid)List<ViewServiceConfig>getViewServiceConfigs(String userId)Get list of view service config on the server<T> TreplaceRel(String userId, String guid, T t, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType, boolean isReplace)Class<? extends GenericResponse>responseType()Relationshiprestore(String userId, String guid)Restore a soft-deleted Relationship.<T> TrestoreRel(String userId, String guid, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType)Relationshipupdate(String userId, String guid, Relationship relationship, boolean isReplace)Update a Relationship.<T> TupdateRel(String userId, String guid, T t, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType, boolean isReplace)SynonymupdateSynonym(String userId, String guid, Synonym updateSynonym, boolean isReplace)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.odpi.openmetadata.commonservices.ffdc.rest.ResponseParameterization
getParameterizedType, resultType
-
-
-
-
Field Detail
-
client
protected final GlossaryAuthorViewRestClient client
-
-
Constructor Detail
-
GlossaryAuthorViewRelationshipsClient
public GlossaryAuthorViewRelationshipsClient(GlossaryAuthorViewRestClient client)
-
-
Method Detail
-
create
public Relationship create(String userId, Relationship relationship) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsCreate a Relationship.The result is the Relationship object
- Specified by:
createin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- userId under which the request is performedrelationship- Relationship object to be created- Returns:
- The Relationship
- Throws:
PropertyServerException- something went wrong with the REST call stack.InvalidParameterException- one of the parameters is null or invalidUserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
update
public Relationship update(String userId, String guid, Relationship relationship, boolean isReplace) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsUpdate a Relationship.The result is the updated Glossary object
- Specified by:
updatein interfaceGlossaryAuthorViewRelationships- Parameters:
userId- userId under which the request is performedguid- guid of Glossary object to be updatedrelationship- Glossary object with updated valuesisReplace- If the object is to be replaced- Returns:
- The updated Relationship
- Throws:
PropertyServerException- something went wrong with the REST call stack.InvalidParameterException- one of the parameters is null or invalidUserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
delete
public void delete(String userId, String guid) throws PropertyServerException
Description copied from interface:GlossaryAuthorViewRelationshipsDelete a Relationship.The result Void object
- Specified by:
deletein interfaceGlossaryAuthorViewRelationships- Parameters:
userId- userId under which the request is performedguid- guid of Relationship object to be retrieved- Throws:
PropertyServerException- something went wrong with the REST call stack.
-
restore
public Relationship restore(String userId, String guid) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsRestore a soft-deleted Relationship.The result is the restored Relationship object
- Specified by:
restorein interfaceGlossaryAuthorViewRelationships- Parameters:
userId- userId under which the request is performedguid- guid of Relationship object to be restored- Returns:
- The restored Relationship
- Throws:
PropertyServerException- something went wrong with the REST call stack.InvalidParameterException- one of the parameters is null or invalidUserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
getCategoryChildren
public List<Category> getCategoryChildren(String userId, String parentGuid, FindRequest findRequest, boolean exactValue, boolean ignoreCase) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsExtract children within a Category- Specified by:
getCategoryChildrenin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- calling userparentGuid- Category GUIDfindRequest- information object for find calls. This include pageSize to limit the number of elements returned.exactValue- exactValue - when false values with trailing characters will match.ignoreCase- ignore the case when matching.- Returns:
- list of Categories
- Throws:
InvalidParameterException- one of the parameters is null or invalidPropertyServerException- something went wrong with the REST call stack.UserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
findAll
public List<Relationship> findAll(String userId) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsFind Category- Specified by:
findAllin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- calling user- Returns:
- Categories belonging to Userid
- Throws:
InvalidParameterException- one of the parameters is null or invalidPropertyServerException- something went wrong with the REST call stack.UserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
getByGUID
public Relationship getByGUID(String userId, String guid) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsGet a Relationship.The result is the requested Relationship object
- Specified by:
getByGUIDin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- userId under which the request is performedguid- guid of Relationship object to be retrieved- Returns:
- The requested Relationship
- Throws:
InvalidParameterException- one of the parameters is null or invalidPropertyServerException- something went wrong with the REST call stack.UserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
find
public List<Relationship> find(String userId, FindRequest findRequest, boolean exactValue, boolean ignoreCase) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsExtract children within a Relationship- Specified by:
findin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- calling userfindRequest- information object for find calls. This include pageSize to limit the number of elements returned.exactValue- exactValue - when false values with trailing characters will match.ignoreCase- ignore the case when matching.- Returns:
- list of Categories
- Throws:
InvalidParameterException- one of the parameters is null or invalidPropertyServerException- something went wrong with the REST call stack.UserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
getCategories
public List<Category> getCategories(String userId, String termGuid, FindRequest findRequest) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsExtract categories for a Relationship- Specified by:
getCategoriesin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- calling usertermGuid- RelationShip GUIDfindRequest- information object for find calls. This include pageSize to limit the number of elements returned.- Returns:
- list of Categories
- Throws:
InvalidParameterException- one of the parameters is null or invalidPropertyServerException- something went wrong with the REST call stack.UserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
getConfig
public OMAGServerConfig getConfig(String userId) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsGet config for server- Specified by:
getConfigin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- calling user- Returns:
- Config for view server
- Throws:
InvalidParameterException- one of the parameters is null or invalidPropertyServerException- something went wrong with the REST call stack.UserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
getGlossaryAuthViewServiceConfig
public ViewServiceConfig getGlossaryAuthViewServiceConfig(String userId) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsGet service config for a particular view Service- Specified by:
getGlossaryAuthViewServiceConfigin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- calling user- Returns:
- Config for view server
- Throws:
InvalidParameterException- one of the parameters is null or invalidPropertyServerException- something went wrong with the REST call stack.UserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
getViewServiceConfigs
public List<ViewServiceConfig> getViewServiceConfigs(String userId) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
Description copied from interface:GlossaryAuthorViewRelationshipsGet list of view service config on the server- Specified by:
getViewServiceConfigsin interfaceGlossaryAuthorViewRelationships- Parameters:
userId- calling user- Returns:
- Config for view server
- Throws:
InvalidParameterException- one of the parameters is null or invalidPropertyServerException- something went wrong with the REST call stack.UserNotAuthorizedException- the requesting user is not authorized to issue this request.
-
responseType
public Class<? extends GenericResponse> responseType()
- Specified by:
responseTypein interfaceResponseParameterization<Relationship>
-
createSynonym
public Synonym createSynonym(String userId, Synonym synonym) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
-
getSynonym
public Synonym getSynonym(String userId, String guid) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
-
updateSynonym
public Synonym updateSynonym(String userId, String guid, Synonym updateSynonym, boolean isReplace) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
-
createRel
public <T> T createRel(String userId, T t, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
-
getRel
public <T> T getRel(String userId, String guid, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
-
updateRel
public <T> T updateRel(String userId, String guid, T t, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType, boolean isReplace) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
-
replaceRel
public <T> T replaceRel(String userId, String guid, T t, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType, boolean isReplace) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
-
deleteRel
public <T> void deleteRel(String userId, String guid, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType) throws PropertyServerException
- Throws:
PropertyServerException
-
restoreRel
public <T> T restoreRel(String userId, String guid, org.springframework.core.ParameterizedTypeReference<GenericResponse<T>> type, String relType) throws PropertyServerException, InvalidParameterException, UserNotAuthorizedException
-
-