Class SubjectAreaHandler<B>


public class SubjectAreaHandler<B> extends OpenMetadataAPIGenericHandler<B>
SubjectAreaHandler provides the exchange of metadata about subject areas between the repository and the OMAS. There is no support for effectivity dating for this element
  • Constructor Details

    • SubjectAreaHandler

      public SubjectAreaHandler(OpenMetadataAPIGenericConverter<B> converter, Class<B> beanClass, String serviceName, String serverName, InvalidParameterHandler invalidParameterHandler, RepositoryHandler repositoryHandler, OMRSRepositoryHelper repositoryHelper, String localServerUserId, OpenMetadataServerSecurityVerifier securityVerifier, List<String> supportedZones, List<String> defaultZones, List<String> publishZones, AuditLog auditLog)
      Construct the subject area handler with information needed to work with B objects.
      Parameters:
      converter - specific converter for this bean class
      beanClass - name of bean class that is represented by the generic class B
      serviceName - name of this service
      serverName - name of the local server
      invalidParameterHandler - handler for managing parameter errors
      repositoryHandler - manages calls to the repository services
      repositoryHelper - provides utilities for manipulating the repository services objects
      localServerUserId - userId for this server
      securityVerifier - open metadata security services verifier
      supportedZones - list of subjectAreas that the access service is allowed to serve B instances from.
      defaultZones - list of subjectAreas that the access service should set in all new B instances.
      publishZones - list of subjectAreas that the access service sets up in published B instances.
      auditLog - destination for audit log events.
  • Method Details

    • createSubjectArea

      public String createSubjectArea(String userId, String externalSourceGUID, String externalSourceName, String qualifiedName, String subjectAreaName, String displayName, String description, String usage, String scope, int domainIdentifier, Map<String,String> additionalProperties, String suppliedTypeName, Map<String,Object> extendedProperties, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Create a definition of a subject area. The qualified name of these subject areas can be added to the supportedZones and defaultZones properties of an OMAS to control which assets are processed and how they are set up. In addition, the qualified names of subjectAreas can be added to Asset definitions to indicate which subjectArea(s) they belong to.
      Parameters:
      userId - calling user
      externalSourceGUID - guid of the software capability entity that represented the external source - null for local
      externalSourceName - name of the software capability entity that represented the external source
      qualifiedName - unique name for the subject area entity
      subjectAreaName - unique name for the subject area - used in other configuration
      displayName - short display name for the subjectArea
      description - description of the subject area
      usage - the usage for inclusion in a subject area
      scope - scope of the organization that this some applies to
      domainIdentifier - the identifier of the governance domain where the subjectArea is managed
      additionalProperties - additional properties for a subject area
      suppliedTypeName - name of subtype - or null for SubjectAreaDefinition
      extendedProperties - properties for a subject area subtype
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      unique identifier of the new subjectArea
      Throws:
      InvalidParameterException - qualifiedName or userId is null
      PropertyServerException - problem accessing property server
      UserNotAuthorizedException - security access problem
    • updateSubjectArea

      public void updateSubjectArea(String userId, String externalSourceGUID, String externalSourceName, String subjectAreaGUID, String subjectAreaGUIDParameterName, String qualifiedName, String subjectAreaName, String displayName, String description, String criteria, String scope, int domainIdentifier, Map<String,String> additionalProperties, String suppliedTypeName, Map<String,Object> extendedProperties, boolean isMergeUpdate, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Create a definition of a subject area. The qualified name of these subject areas can be added to the supportedZones and defaultZones properties of an OMAS to control which assets are processed and how they are set up. In addition, the qualified names of subjectAreas can be added to Asset definitions to indicate which subjectArea(s) they belong to.
      Parameters:
      userId - calling user
      externalSourceGUID - guid of the software capability entity that represented the external source - null for local
      externalSourceName - name of the software capability entity that represented the external source
      subjectAreaGUID - unique identifier of subject area
      subjectAreaGUIDParameterName - parameter name for subjectAreaGUID
      qualifiedName - unique name for the subject area entity
      subjectAreaName - unique name for the subject area - used in other configuration
      displayName - short display name for the subjectArea
      description - description of the subject area
      criteria - the criteria for inclusion in a subject area
      scope - scope of the organization that this some applies to
      domainIdentifier - the identifier of the governance domain where the subjectArea is managed
      additionalProperties - additional properties for a subject area
      suppliedTypeName - subtype name
      extendedProperties - properties for a subject area subtype
      isMergeUpdate - should the supplied properties be merged with the existing one or replace them
      methodName - calling method
      Throws:
      InvalidParameterException - qualifiedName or userId is null
      PropertyServerException - problem accessing property server
      UserNotAuthorizedException - security access problem
    • getSubjectArea

      public B getSubjectArea(String userId, String name, String nameParameter, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Return information about a specific subject area.
      Parameters:
      userId - calling user
      name - unique name for the subjectArea
      nameParameter - name of parameter supplying the name
      forLineage - return elements marked with the Memento classification?
      forDuplicateProcessing - do not merge elements marked as duplicates?
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      properties of the subject area
      Throws:
      InvalidParameterException - name or userId is null
      PropertyServerException - problem accessing property server
      UserNotAuthorizedException - security access problem
    • getSubjectAreaParentGUID

      public String getSubjectAreaParentGUID(String userId, String subjectAreaGUID, String subjectAreaGUIDParameter, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Return information about a specific subject area's parent.
      Parameters:
      userId - calling user
      subjectAreaGUID - unique identifier for the subjectArea
      subjectAreaGUIDParameter - name of parameter supplying the subjectAreaGUID
      forLineage - return elements marked with the Memento classification?
      forDuplicateProcessing - do not merge elements marked as duplicates?
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      unique identifier of the parent subject area
      Throws:
      InvalidParameterException - subjectAreaGUID or userId is null
      PropertyServerException - problem accessing property server
      UserNotAuthorizedException - security access problem
    • getSubjectAreaChildrenGUIDs

      public List<String> getSubjectAreaChildrenGUIDs(String userId, String subjectAreaGUID, String subjectAreaGUIDParameter, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Return information about a specific subject area's child (nested) subjectAreas.
      Parameters:
      userId - calling user
      subjectAreaGUID - unique identifier for the subjectArea
      subjectAreaGUIDParameter - name of parameter supplying the subjectAreaGUID
      forLineage - return elements marked with the Memento classification?
      forDuplicateProcessing - do not merge elements marked as duplicates?
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      list of unique identifier of the parent subject area
      Throws:
      InvalidParameterException - subjectAreaGUID or userId is null
      PropertyServerException - problem accessing property server
      UserNotAuthorizedException - security access problem
    • getSubjectAreas

      public List<B> getSubjectAreas(String userId, int startFrom, int pageSize, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Return information about the defined subject areas.
      Parameters:
      userId - calling user
      startFrom - position in the list (used when there are so many reports that paging is needed
      pageSize - maximum number of elements to return on this call
      forLineage - return elements marked with the Memento classification?
      forDuplicateProcessing - do not merge elements marked as duplicates?
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      properties of the subject area
      Throws:
      InvalidParameterException - qualifiedName or userId is null
      PropertyServerException - problem accessing property server
      UserNotAuthorizedException - security access problem
    • getSubjectAreasByDomain

      public List<B> getSubjectAreasByDomain(String userId, int domainIdentifier, int startFrom, int pageSize, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Return information about the defined subject areas for a specific domain.
      Parameters:
      userId - calling user
      domainIdentifier - identifier of domain - 0 is for all domains
      startFrom - position in the list (used when there are so many reports that paging is needed
      pageSize - maximum number of elements to return on this call
      forLineage - return elements marked with the Memento classification?
      forDuplicateProcessing - do not merge elements marked as duplicates?
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      properties of the subject area
      Throws:
      InvalidParameterException - qualifiedName or userId is null
      PropertyServerException - problem accessing property server
      UserNotAuthorizedException - security access problem