Interface TemplateChangeService

All Known Implementing Classes:
TemplateChangeServiceImpl

public interface TemplateChangeService
This service handles the runtime change of a template or template definition with an optional change / approval process to be triggered.
Author:
Micha Kiener
  • Field Details

  • Method Details

    • triggerTemplateVariationContentChange

      void triggerTemplateVariationContentChange(String templateVariationId, String tenantId, UpdateTemplateVariationRequest updateRequest)
      Changes and deploys the variation content of the given template variation at runtime. This will start a change / approval process, if configured. And if that's the case, the change and deploy does not happen immediately, but will be done as part of the process. If there is no such process in place, this method will directly invoke deployTemplateVariationContentChange(String, String, String, String).
      Parameters:
      templateVariationId - the id of the template variation to change its variation content
      updateRequest - the update request containing the necessary data (e.g. new variation content, etc) for the update
    • deployTemplateVariationContentChange

      void deployTemplateVariationContentChange(String templateVariationId, String tenantId, String newVariationContent, String newVariationContentResource)
      Directly changes and deploys the variation content of the given template variation at runtime. This method is either invoked by triggerTemplateVariationContentChange(String, String, UpdateTemplateVariationRequest) or as part of the change / approval process to eventually deploy the changed content.
      Parameters:
      templateVariationId - the id of the template variation to change and deploy its content
      tenantId - the optional id of the tenant
      newVariationContent - the new variation content to change and deploy (can be null if newVariationContentResource is passed)
      newVariationContentResource - the new variation content resource to change and deploy (can be null if newVariationContent is passed)
    • deployTemplateVariationContentChange

      void deployTemplateVariationContentChange(String templateVariationId, String tenantId, String newVariationContent, String newVariationContentResource, String externalId)
      Directly changes and deploys the variation content of the given template variation at runtime. This method is either invoked by triggerTemplateVariationContentChange(String, String, UpdateTemplateVariationRequest) or as part of the change / approval process to eventually deploy the changed content.
      Parameters:
      templateVariationId - the ID of the template variation to change and deploy its content
      tenantId - the optional ID of the tenant
      newVariationContent - the new variation content to change and deploy (can be null if newVariationContentResource is passed)
      newVariationContentResource - the new variation content resource to change and deploy (can be null if newVariationContent is passed)
      externalId - the new external ID
    • findApprovalProcessInstance

      ProcessInstance findApprovalProcessInstance(String combinedTemplateVariationKey, String tenantId)
      Find a running approval / change process for the specified template variation.
      Parameters:
      combinedTemplateVariationKey - the combined id of the template and variation key (as being returned by TemplateVariationModel.getKey()
      Returns:
      the optional, running approval process, if any found, null otherwise