Class ExternalReferenceRESTServices

java.lang.Object
org.odpi.openmetadata.accessservices.assetowner.server.ExternalReferenceRESTServices

public class ExternalReferenceRESTServices extends Object
ExternalReferenceRESTServices is the server-side for managing external references and their links to all types of governance definitions.
  • Constructor Details

    • ExternalReferenceRESTServices

      public ExternalReferenceRESTServices()
      Default constructor
  • Method Details

    • createExternalReference

      public GUIDResponse createExternalReference(String serverName, String userId, ReferenceableRequestBody requestBody)
      Create a definition of an external reference.
      Parameters:
      serverName - name of the server instance to connect to
      userId - calling user
      requestBody - properties for an external reference plus optional element to link the external reference to that will act as an anchor - that is, this external reference will be deleted when the element is deleted (once the external reference is linked to the anchor).
      Returns:
      unique identifier of the external reference or InvalidParameterException qualifiedName or userId is null; qualifiedName is not unique PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • updateExternalReference

      public VoidResponse updateExternalReference(String serverName, String userId, String externalReferenceGUID, boolean isMergeUpdate, ReferenceableRequestBody requestBody)
      Update the definition of an external reference.
      Parameters:
      serverName - name of the server instance to connect to
      userId - calling user
      externalReferenceGUID - unique identifier of external reference
      isMergeUpdate - are unspecified properties unchanged (true) or replaced with null?
      requestBody - properties to change
      Returns:
      void or InvalidParameterException guid, qualifiedName or userId is null; qualifiedName is not unique; guid is not known PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • deleteExternalReference

      public VoidResponse deleteExternalReference(String serverName, String userId, String externalReferenceGUID, ExternalSourceRequestBody requestBody)
      Remove the definition of an external reference.
      Parameters:
      serverName - name of the server instance to connect to
      userId - calling user
      externalReferenceGUID - unique identifier of external reference
      requestBody - external source request body
      Returns:
      void or InvalidParameterException guid, qualifiedName or userId is null; qualifiedName is not unique; guid is not known PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • linkExternalReferenceToElement

      public VoidResponse linkExternalReferenceToElement(String serverName, String userId, String attachedToGUID, String externalReferenceGUID, RelationshipRequestBody requestBody)
      Link an external reference to an object.
      Parameters:
      serverName - name of the server instance to connect to
      userId - the name of the calling user.
      attachedToGUID - object linked to external references.
      externalReferenceGUID - unique identifier (guid) of the external reference details.
      requestBody - description for the reference from the perspective of the object that the reference is being attached to.
      Returns:
      void or InvalidParameterException guid, qualifiedName or userId is null; qualifiedName is not unique; guid is not known PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • unlinkExternalReferenceFromElement

      public VoidResponse unlinkExternalReferenceFromElement(String serverName, String userId, String attachedToGUID, String externalReferenceGUID, RelationshipRequestBody requestBody)
      Remove the link between an external reference and an element. If the element is its anchor, the external reference is removed.
      Parameters:
      serverName - name of the server instance to connect to
      userId - the name of the calling user.
      attachedToGUID - object linked to external references.
      externalReferenceGUID - identifier of the external reference.
      requestBody - external source request body
      Returns:
      void or InvalidParameterException guid, qualifiedName or userId is null; qualifiedName is not unique; guid is not known PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • getExternalReferenceByGUID

      public ExternalReferenceResponse getExternalReferenceByGUID(String serverName, String userId, String externalReferenceGUID)
      Return information about a specific external reference.
      Parameters:
      serverName - name of the server instance to connect to
      userId - calling user
      externalReferenceGUID - unique identifier for the external reference
      Returns:
      properties of the external reference or InvalidParameterException externalReferenceGUID or userId is null PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • findExternalReferencesById

      public ExternalReferenceListResponse findExternalReferencesById(String serverName, String userId, int startFrom, int pageSize, SearchStringRequestBody requestBody)
      Retrieve the list of external references for this resourceId.
      Parameters:
      serverName - name of the server instance to connect to
      userId - the name of the calling user.
      requestBody - unique reference id assigned by the resource owner (supports wildcards). This is the qualified name of the entity
      startFrom - index of the list to start from (0 for start)
      pageSize - maximum number of elements to return.
      Returns:
      links to addition information or InvalidParameterException externalReferenceGUID or userId is null PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • getExternalReferencesByURL

      public ExternalReferenceListResponse getExternalReferencesByURL(String serverName, String userId, int startFrom, int pageSize, NameRequestBody requestBody)
      Retrieve the list of external references for this URL.
      Parameters:
      serverName - name of the server instance to connect to
      userId - the name of the calling user.
      requestBody - URL of the external resource.
      startFrom - index of the list to start from (0 for start)
      pageSize - maximum number of elements to return.
      Returns:
      links to addition information or InvalidParameterException externalReferenceGUID or userId is null PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • retrieveAttachedExternalReferences

      public ExternalReferenceListResponse retrieveAttachedExternalReferences(String serverName, String userId, String attachedToGUID, int startFrom, int pageSize)
      Retrieve the list of external references attached to the supplied object.
      Parameters:
      serverName - name of the server instance to connect to
      userId - the name of the calling user.
      attachedToGUID - object linked to external reference.
      startFrom - index of the list to start from (0 for start)
      pageSize - maximum number of elements to return.
      Returns:
      links to addition information or InvalidParameterException externalReferenceGUID or userId is null PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • getElementsForExternalReference

      public RelatedElementListResponse getElementsForExternalReference(String serverName, String userId, String externalReferenceGUID, int startFrom, int pageSize)
      Return information about the elements linked to a externalReference.
      Parameters:
      serverName - name of the server instance to connect to
      userId - calling user
      externalReferenceGUID - unique identifier for the externalReference
      startFrom - paging start point
      pageSize - maximum results that can be returned
      Returns:
      properties of the external reference InvalidParameterException externalReferenceGUID or userId is null PropertyServerException problem accessing property server UserNotAuthorizedException security access problem