public class CategoryHandler extends Object
| Constructor and Description |
|---|
CategoryHandler(SubjectAreaCategory subjectAreaCategory)
Constructor for the CategoryHandler
|
| Modifier and Type | Method and Description |
|---|---|
Category |
createCategory(String userId,
Category suppliedCategory)
Create a Category
|
Category |
deleteCategory(String userId,
String guid)
Delete a Category instance
A delete (also known as a soft delete) means that the category instance will exist in a deleted state in the repository after the delete operation.
|
List<Category> |
findCategory(String userId,
String searchCriteria,
Date asOfTime,
int offset,
int pageSize,
SequencingOrder sequencingOrder,
String sequencingProperty)
Find Category
|
Category |
getCategoryByGuid(String userId,
String guid)
Get a category by guid.
|
List<Line> |
getCategoryRelationships(String userId,
String guid,
Date asOfTime,
int offset,
int pageSize,
SequencingOrder sequencingOrder,
String sequencingProperty)
Get Category relationships
|
void |
purgeCategory(String userId,
String guid)
Purge a Category instance
A purge means that the category will not exist after the operation.
|
Category |
replaceCategory(String userId,
String guid,
Category suppliedCategory)
Replace a Category.
|
Category |
restoreCategory(String userId,
String guid)
Restore a Category
Restore allows the deleted Category to be made active again.
|
Category |
updateCategory(String userId,
String guid,
Category suppliedCategory)
Update a Category.
|
public CategoryHandler(SubjectAreaCategory subjectAreaCategory)
subjectAreaCategory - The SubjectAreaDefinition Open Metadata Access Service (OMAS) API for categories. This is the same as the
The Glossary author Open Metadata View Service (OMVS) API for categories.public Category createCategory(String userId, Category suppliedCategory) throws MetadataServerUncontactableException, ClassificationException, FunctionNotSupportedException, UnexpectedResponseException, InvalidParameterException, UserNotAuthorizedException, UnrecognizedGUIDException
userId - userId under which the request is performedsuppliedCategory - Category to createUserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.ClassificationException - Error processing a classificationFunctionNotSupportedException - Function not supportedUnrecognizedGUIDException - Unrecognised GUID
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverpublic Category getCategoryByGuid(String userId, String guid) throws MetadataServerUncontactableException, FunctionNotSupportedException, UnexpectedResponseException, InvalidParameterException, UserNotAuthorizedException, UnrecognizedGUIDException
userId - userId under which the request is performedguid - guid of the category to getUserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.FunctionNotSupportedException - Function not supportedUnrecognizedGUIDException - unrecognised GUID
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverpublic List<Category> findCategory(String userId, String searchCriteria, Date asOfTime, int offset, int pageSize, SequencingOrder sequencingOrder, String sequencingProperty) throws MetadataServerUncontactableException, FunctionNotSupportedException, UnexpectedResponseException, InvalidParameterException, UserNotAuthorizedException
userId - unique identifier for requesting user, under which the request is performedsearchCriteria - String expression matching Category property values (this does not include the CategorySummary content).asOfTime - the relationships returned as they were at this time. null indicates at the current time.offset - the starting element number for this set of results. This is used when retrieving elements
beyond the first page of results. Zero means the results start from the first element.pageSize - the maximum number of elements that can be returned on this request.
0 means there is no limit to the page sizesequencingOrder - the sequencing order for the results.sequencingProperty - the name of the property that should be used to sequence the results.UserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.FunctionNotSupportedException - Function not supported
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverpublic Category replaceCategory(String userId, String guid, Category suppliedCategory) throws UnexpectedResponseException, FunctionNotSupportedException, MetadataServerUncontactableException, InvalidParameterException, UserNotAuthorizedException
Status is not updated using this call. The GovernanceAction content if specified replaces what is on the server.
userId - userId under which the request is performedguid - guid of the category to updatesuppliedCategory - category to be updatedUserNotAuthorizedException - the requesting user is not authorized to issue this request.FunctionNotSupportedException - Function not supportedInvalidParameterException - one of the parameters is null or invalid.
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverpublic Category updateCategory(String userId, String guid, Category suppliedCategory) throws UnexpectedResponseException, FunctionNotSupportedException, MetadataServerUncontactableException, InvalidParameterException, UserNotAuthorizedException
Status is not updated using this call. The GovernanceAction content if specified replaces what is on the server.
userId - userId under which the request is performedguid - guid of the category to updatesuppliedCategory - category to be updatedUserNotAuthorizedException - the requesting user is not authorized to issue this request.FunctionNotSupportedException - Function not supportedInvalidParameterException - one of the parameters is null or invalid.
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverpublic Category deleteCategory(String userId, String guid) throws MetadataServerUncontactableException, UnrecognizedGUIDException, FunctionNotSupportedException, UnexpectedResponseException, EntityNotDeletedException, InvalidParameterException, UserNotAuthorizedException
userId - userId under which the request is performedguid - guid of the category to be deleted.UserNotAuthorizedException - the requesting user is not authorized to issue this request.FunctionNotSupportedException - Function not supported this indicates that a soft delete was issued but the repository does not support it.InvalidParameterException - one of the parameters is null or invalid.MetadataServerUncontactableException - not able to communicate with a Metadata respository service. There is a problem retrieving properties from the metadata repository.EntityNotDeletedException - a soft delete was issued but the relationship was not deleted.UnrecognizedGUIDException - the supplied guid was not recognised
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverpublic void purgeCategory(String userId, String guid) throws MetadataServerUncontactableException, UnrecognizedGUIDException, EntityNotPurgedException, UnexpectedResponseException, FunctionNotSupportedException, InvalidParameterException, UserNotAuthorizedException
userId - userId under which the request is performedguid - guid of the category to be deleted.UserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.EntityNotPurgedException - a hard delete was issued but the category was not purgedUnrecognizedGUIDException - the supplied guid was not recognisedFunctionNotSupportedException - Function not supported
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverpublic Category restoreCategory(String userId, String guid) throws MetadataServerUncontactableException, UnrecognizedGUIDException, FunctionNotSupportedException, UnexpectedResponseException, InvalidParameterException, UserNotAuthorizedException
userId - unique identifier for requesting user, under which the request is performedguid - guid of the category to restoreUnrecognizedGUIDException - the supplied guid was not recognisedUserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.FunctionNotSupportedException - Function not supported this indicates that a soft delete was issued but the repository does not support it.
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverpublic List<Line> getCategoryRelationships(String userId, String guid, Date asOfTime, int offset, int pageSize, SequencingOrder sequencingOrder, String sequencingProperty) throws MetadataServerUncontactableException, UserNotAuthorizedException, InvalidParameterException, FunctionNotSupportedException, UnexpectedResponseException
userId - unique identifier for requesting user, under which the request is performedguid - guid of the category to getasOfTime - the relationships returned as they were at this time. null indicates at the current time.offset - the starting element number for this set of results. This is used when retrieving elements
beyond the first page of results. Zero means the results start from the first element.pageSize - the maximum number of elements that can be returned on this request.
0 means there is not limit to the page sizesequencingOrder - the sequencing order for the results.sequencingProperty - the name of the property that should be used to sequence the results.UserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.FunctionNotSupportedException - Function not supported
Client library ExceptionsMetadataServerUncontactableException - Unable to contact the serverUnexpectedResponseException - an unexpected response was returned from the serverCopyright © 2018–2020 ODPi. All rights reserved.