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
|
void |
deleteCategory(String userId,
String guid)
Delete a Category instance
|
List<Category> |
findCategory(String userId,
FindRequest findRequest)
Find Category
|
Category |
getCategoryByGuid(String userId,
String guid)
Get a category by guid.
|
List<Line> |
getCategoryRelationships(String userId,
String guid,
FindRequest findRequest)
Get Category relationships
|
void |
purgeCategory(String userId,
String guid)
Purge a Category instance
|
Category |
replaceCategory(String userId,
String guid,
Category suppliedCategory)
Replace a Category.
|
Category |
restoreCategory(String userId,
String guid)
Restore a Category
|
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 InvalidParameterException, PropertyServerException, UserNotAuthorizedException
userId - userId under which the request is performedsuppliedCategory - Category to createExceptions returned by the server
UserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.PropertyServerException - property server exceptionpublic Category getCategoryByGuid(String userId, String guid) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
userId - userId under which the request is performedguid - guid of the category to getExceptions returned by the server
UserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.PropertyServerException - property server exceptionpublic List<Category> findCategory(String userId, FindRequest findRequest) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
userId - unique identifier for requesting user, under which the request is performedfindRequest - FindRequestExceptions returned by the server
UserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.PropertyServerException - property server exceptionpublic Category replaceCategory(String userId, String guid, Category suppliedCategory) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
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.InvalidParameterException - one of the parameters is null or invalid.PropertyServerException - property server exceptionpublic Category updateCategory(String userId, String guid, Category suppliedCategory) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
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.InvalidParameterException - one of the parameters is null or invalid.PropertyServerException - property server exceptionpublic void deleteCategory(String userId, String guid) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
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. This means that it is possible to undo the delete.
userId - userId under which the request is performedguid - guid of the category to be deleted.
Exceptions returned by the serverUserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.PropertyServerException - property server exceptionpublic void purgeCategory(String userId, String guid) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
A purge means that the category will not exist after the operation.
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.PropertyServerException - property server exceptionpublic Category restoreCategory(String userId, String guid) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Restore allows the deleted Category to be made active again. Restore allows deletes to be undone. Hard deletes are not stored in the repository so cannot be restored.
userId - unique identifier for requesting user, under which the request is performedguid - guid of the category to restoreUserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.PropertyServerException - property server exceptionpublic List<Line> getCategoryRelationships(String userId, String guid, FindRequest findRequest) throws UserNotAuthorizedException, InvalidParameterException, PropertyServerException
userId - unique identifier for requesting user, under which the request is performedguid - guid of the category to getfindRequest - FindRequestExceptions returned by the server
UserNotAuthorizedException - the requesting user is not authorized to issue this request.InvalidParameterException - one of the parameters is null or invalid.PropertyServerException - property server exceptionCopyright © 2018–2020 ODPi. All rights reserved.