Interface ReviewByUserGroups


public interface ReviewByUserGroups
Defines which user groups review the line items in a review step of a Creation Workflow, and in which order.

You get an instance from api.newReviewByUserGroups(), fill it with review sub-steps using exactly one of the two modes, and pass it to ReviewStepDefinition.withReviewByUserGroupWithSubSteps(ReviewByUserGroups):

The two modes cannot be combined on the same instance. To mix them, nest the sub-steps instead, for example by passing a sequence created by api.newReviewSequentialSubSteps(...) as one of the parallel sub-steps. A review step whose ReviewByUserGroups has no sub-steps fails validation.

Example:


 def reviewStep = api.newReviewStep()
     .withLabel("Review")
     .withReviewByUserGroupWithSubSteps(
         api.newReviewByUserGroups()
             .withParallelSubSteps(
                 api.newReviewSubStep()
                     .withUserGroup("SupplyCoordinator")
                     .withLabel("Supply Coordinator"),
                 api.newReviewSubStep()
                     .withUserGroup("PricingAdvisor")
                     .withLabel("Pricing Advisor")
             )
     )
 
Since:
14.0 - Caribou Lou
See Also:
  • Method Details

    • withSequentialSubSteps

      ReviewByUserGroups withSequentialSubSteps(IsSequentialSubStep... isSequentialSubSteps)
      Sets the review sub-steps that run one after another. The next sub-step starts only when the previous one has completed its review.

      You can call this method only once per instance, and not on an instance on which withParallelSubSteps(IsParallelSubStep...) was already called. Since version 15.1, calling it a second time, or calling it without sub-steps, throws an exception.

      Example:

      
       api.newReviewByUserGroups()
           .withSequentialSubSteps(
               api.newReviewSubStep()
                   .withUserGroup("SupplyCoordinator")
                   .withLabel("Supply Coordinator"),
               api.newReviewSubStep()
                   .withUserGroup("PricingAdvisor")
                   .withLabel("Pricing Advisor")
           )
       
      Parameters:
      isSequentialSubSteps - The sub-steps in the order in which they are processed: single review sub-steps (ReviewUserGroupSubStep) or parallel groups (ReviewUserGroupsParallelSubStep). Must contain at least one sub-step and no null values.
      Returns:
      The same ReviewByUserGroups object, for chaining.
      Throws:
      IllegalStateException - if parallel sub-steps are already defined, or if this method was already called on this instance.
      IllegalArgumentException - if isSequentialSubSteps is null or empty.
      Since:
      14.0 - Caribou Lou
      See Also:
    • withParallelSubSteps

      ReviewByUserGroups withParallelSubSteps(IsParallelSubStep... parallelSubSteps)
      Adds review sub-steps that run at the same time. All user groups in the parallel sub-steps review the document simultaneously.

      Unlike withSequentialSubSteps(IsSequentialSubStep...), this method can be called repeatedly: each call adds its sub-steps to the ones added earlier. It cannot be called on an instance on which withSequentialSubSteps(IsSequentialSubStep...) was already called. Since version 15.1, calling it without sub-steps throws an exception.

      Example:

      
       api.newReviewByUserGroups()
           .withParallelSubSteps(
               api.newReviewSubStep()
                   .withUserGroup("supply_coordinator")
                   .withLabel("Supply Coordinator"),
               api.newReviewSequentialSubSteps(
                   api.newReviewSubStep()
                       .withUserGroup("pricing_advisor")
                       .withLabel("Pricing Advisor"),
                   api.newReviewSubStep()
                       .withUserGroup("channel_analyst")
                       .withLabel("Channel Analyst")
               )
           )
       
      Parameters:
      parallelSubSteps - The sub-steps to run in parallel: single review sub-steps (ReviewUserGroupSubStep) or sequences (ReviewUserGroupsSequentialSubSteps). A sequence passed here must not contain a parallel group. Must contain at least one sub-step and no null values.
      Returns:
      The same ReviewByUserGroups object, for chaining.
      Throws:
      IllegalStateException - if sequential sub-steps are already defined on this instance.
      IllegalArgumentException - if parallelSubSteps is null or empty.
      Since:
      14.0 - Caribou Lou
      See Also: