Class SubjectAreaRESTServices
java.lang.Object
org.odpi.openmetadata.tokencontroller.TokenController
org.odpi.openmetadata.viewservices.subjectarea.server.SubjectAreaRESTServices
The SubjectAreaRESTServices provides the server-side implementation of the Subject Area Open Metadata
View Service (OMVS). This interface provides access to data fields, data structures and data classes.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateSubjectArea
(String serverName, NewElementRequestBody requestBody) Create a data structure.createSubjectAreaFromTemplate
(String serverName, TemplateRequestBody requestBody) Create a new metadata element to represent a data structure using an existing metadata element as a template.deleteSubjectArea
(String serverName, String subjectAreaGUID, boolean cascadedDelete, MetadataSourceRequestBody requestBody) Delete a data structure.detachSubjectAreas
(String serverName, String subjectAreaGUID, String dataFieldGUID, MetadataSourceRequestBody requestBody) Detach a data field from a data structure.findSubjectAreas
(String serverName, boolean startsWith, boolean endsWith, boolean ignoreCase, int startFrom, int pageSize, FilterRequestBody requestBody) Retrieve the list of data structure metadata elements that contain the search string.getSubjectAreaByGUID
(String serverName, String subjectAreaGUID, AnyTimeRequestBody requestBody) Retrieve the list of data structure metadata elements that contain the search string.getSubjectAreasByName
(String serverName, int startFrom, int pageSize, FilterRequestBody requestBody) Retrieve the list of data structure metadata elements that contain the search string.linkSubjectAreas
(String serverName, String subjectAreaGUID, String nestedSubjectAreaGUID, RelationshipRequestBody requestBody) Attach a data field to a data structure.updateSubjectArea
(String serverName, String subjectAreaGUID, boolean replaceAllProperties, UpdateElementRequestBody requestBody) Update the properties of a data structure.Methods inherited from class org.odpi.openmetadata.tokencontroller.TokenController
getUser
-
Constructor Details
-
SubjectAreaRESTServices
public SubjectAreaRESTServices()Default constructor
-
-
Method Details
-
createSubjectArea
Create a data structure.- Parameters:
serverName
- name of called server.requestBody
- properties for the data structure.- Returns:
- unique identifier of the newly created element InvalidParameterException one of the parameters is invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
createSubjectAreaFromTemplate
public GUIDResponse createSubjectAreaFromTemplate(String serverName, TemplateRequestBody requestBody) Create a new metadata element to represent a data structure using an existing metadata element as a template. The template defines additional classifications and relationships that should be added to the new element.- Parameters:
serverName
- calling userrequestBody
- properties that override the template- Returns:
- unique identifier of the new metadata element InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException there is a problem reported in the open metadata server(s)
-
updateSubjectArea
public VoidResponse updateSubjectArea(String serverName, String subjectAreaGUID, boolean replaceAllProperties, UpdateElementRequestBody requestBody) Update the properties of a data structure.- Parameters:
serverName
- name of called server.subjectAreaGUID
- unique identifier of the data structure (returned from create)replaceAllProperties
- flag to indicate whether to completely replace the existing properties with the new properties, or just update the individual properties specified on the request.requestBody
- properties for the new element.- Returns:
- void or InvalidParameterException one of the parameters is invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
linkSubjectAreas
public VoidResponse linkSubjectAreas(String serverName, String subjectAreaGUID, String nestedSubjectAreaGUID, RelationshipRequestBody requestBody) Attach a data field to a data structure.- Parameters:
serverName
- name of called serversubjectAreaGUID
- unique identifier of the parent subject area.nestedSubjectAreaGUID
- unique identifier of the nested subject area.requestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
detachSubjectAreas
public VoidResponse detachSubjectAreas(String serverName, String subjectAreaGUID, String dataFieldGUID, MetadataSourceRequestBody requestBody) Detach a data field from a data structure.- Parameters:
serverName
- name of called serversubjectAreaGUID
- unique identifier of the parent data structure.dataFieldGUID
- unique identifier of the nested data field.requestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
deleteSubjectArea
public VoidResponse deleteSubjectArea(String serverName, String subjectAreaGUID, boolean cascadedDelete, MetadataSourceRequestBody requestBody) Delete a data structure.- Parameters:
serverName
- name of called serversubjectAreaGUID
- unique identifier of the element to deletecascadedDelete
- can data structures be deleted if data fields are attached?requestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
getSubjectAreasByName
public SubjectAreasResponse getSubjectAreasByName(String serverName, int startFrom, int pageSize, FilterRequestBody requestBody) Retrieve the list of data structure metadata elements that contain the search string.- Parameters:
serverName
- name of the service to route the request tostartFrom
- paging start pointpageSize
- maximum results that can be returnedrequestBody
- string to find in the properties- Returns:
- list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException there is a problem reported in the open metadata server(s)
-
getSubjectAreaByGUID
public SubjectAreaResponse getSubjectAreaByGUID(String serverName, String subjectAreaGUID, AnyTimeRequestBody requestBody) Retrieve the list of data structure metadata elements that contain the search string.- Parameters:
serverName
- name of the service to route the request tosubjectAreaGUID
- unique identifier of the required elementrequestBody
- string to find in the properties- Returns:
- list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException there is a problem reported in the open metadata server(s)
-
findSubjectAreas
public SubjectAreasResponse findSubjectAreas(String serverName, boolean startsWith, boolean endsWith, boolean ignoreCase, int startFrom, int pageSize, FilterRequestBody requestBody) Retrieve the list of data structure metadata elements that contain the search string.- Parameters:
serverName
- name of the service to route the request tostartsWith
- does the value start with the supplied string?endsWith
- does the value end with the supplied string?ignoreCase
- should the search ignore case?startFrom
- paging start pointpageSize
- maximum results that can be returnedrequestBody
- string to find in the properties- Returns:
- list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException there is a problem reported in the open metadata server(s)
-