java.lang.Object
org.odpi.openmetadata.adapters.repositoryservices.xtdb.repositoryconnector.txnfn.AbstractTransactionFunction
org.odpi.openmetadata.adapters.repositoryservices.xtdb.repositoryconnector.txnfn.UpdateInstanceStatus
Direct Known Subclasses:
UpdateEntityStatus, UpdateRelationshipStatus

public abstract class UpdateInstanceStatus extends AbstractTransactionFunction
Base transaction function for updating an instance's status.
  • Constructor Details

    • UpdateInstanceStatus

      public UpdateInstanceStatus()
  • Method Details

    • updateInstanceStatus

      protected static clojure.lang.IPersistentMap updateInstanceStatus(String userId, clojure.lang.IPersistentMap existing, int instanceStatus)
      Makes the necessary changes to update a metadata instance's status.
      Parameters:
      userId - doing the update
      existing - metadata instance
      instanceStatus - new status for the instance
      Returns:
      IPersistentMap giving the updated instance representation
    • validate

      protected static void validate(clojure.lang.IPersistentMap existing, String instanceGUID, String metadataCollectionId, Integer instanceStatus, String className, String methodName) throws InvalidParameterException, RepositoryErrorException, IOException, StatusNotSupportedException
      Validate the status change.
      Parameters:
      existing - metadata instance
      instanceGUID - unique identifier of the metadata instance
      metadataCollectionId - of the metadata instance
      instanceStatus - new status for the metadata instance
      className - calling class
      methodName - calling method
      Throws:
      InvalidParameterException - on any null or invalid parameters
      IOException - on any error deserializing values
      StatusNotSupportedException - if the provided status is invalid for the metadata instance
      RepositoryErrorException - on any other error