Class ImmutableUserTaskRecordValue.Builder

java.lang.Object
io.camunda.zeebe.protocol.record.value.ImmutableUserTaskRecordValue.Builder
Enclosing class:
ImmutableUserTaskRecordValue

public static final class ImmutableUserTaskRecordValue.Builder extends Object
Builds instances of type ImmutableUserTaskRecordValue. Initialize attributes and then invoke the build() method to create an immutable instance.

Builder is not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.

  • Method Details

    • from

      Fill a builder with attribute values from the provided io.camunda.zeebe.protocol.record.value.UserTaskRecordValue instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • from

      Fill a builder with attribute values from the provided io.camunda.zeebe.protocol.record.value.ProcessInstanceRelated instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • from

      public final ImmutableUserTaskRecordValue.Builder from(TenantOwned instance)
      Fill a builder with attribute values from the provided io.camunda.zeebe.protocol.record.value.TenantOwned instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • from

      Fill a builder with attribute values from the provided io.camunda.zeebe.protocol.record.RecordValueWithVariables instance.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • putVariable

      public final ImmutableUserTaskRecordValue.Builder putVariable(String key, Object value)
      Put one entry to the variables map.
      Parameters:
      key - The key in the variables map
      value - The associated value in the variables map
      Returns:
      this builder for use in a chained invocation
    • putVariable

      public final ImmutableUserTaskRecordValue.Builder putVariable(Map.Entry<String,? extends Object> entry)
      Put one entry to the variables map. Nulls are not permitted
      Parameters:
      entry - The key and value entry
      Returns:
      this builder for use in a chained invocation
    • withVariables

      public final ImmutableUserTaskRecordValue.Builder withVariables(Map<String,? extends Object> entries)
      Sets or replaces all mappings from the specified map as entries for the variables map. Nulls are not permitted
      Parameters:
      entries - The entries that will be added to the variables map
      Returns:
      this builder for use in a chained invocation
    • putAllVariables

      public final ImmutableUserTaskRecordValue.Builder putAllVariables(Map<String,? extends Object> entries)
      Put all mappings from the specified map as entries to variables map. Nulls are not permitted
      Parameters:
      entries - The entries that will be added to the variables map
      Returns:
      this builder for use in a chained invocation
    • withProcessInstanceKey

      public final ImmutableUserTaskRecordValue.Builder withProcessInstanceKey(long processInstanceKey)
      Initializes the value for the processInstanceKey attribute.
      Parameters:
      processInstanceKey - The value for processInstanceKey
      Returns:
      this builder for use in a chained invocation
    • withTenantId

      public final ImmutableUserTaskRecordValue.Builder withTenantId(String tenantId)
      Initializes the value for the tenantId attribute.
      Parameters:
      tenantId - The value for tenantId (can be null)
      Returns:
      this builder for use in a chained invocation
    • withUserTaskKey

      public final ImmutableUserTaskRecordValue.Builder withUserTaskKey(long userTaskKey)
      Initializes the value for the userTaskKey attribute.
      Parameters:
      userTaskKey - The value for userTaskKey
      Returns:
      this builder for use in a chained invocation
    • withAssignee

      public final ImmutableUserTaskRecordValue.Builder withAssignee(String assignee)
      Initializes the value for the assignee attribute.
      Parameters:
      assignee - The value for assignee (can be null)
      Returns:
      this builder for use in a chained invocation
    • addCandidateGroupsList

      public final ImmutableUserTaskRecordValue.Builder addCandidateGroupsList(String element)
      Adds one element to candidateGroupsList list.
      Parameters:
      element - A candidateGroupsList element
      Returns:
      this builder for use in a chained invocation
    • addCandidateGroupsList

      public final ImmutableUserTaskRecordValue.Builder addCandidateGroupsList(String... elements)
      Adds elements to candidateGroupsList list.
      Parameters:
      elements - An array of candidateGroupsList elements
      Returns:
      this builder for use in a chained invocation
    • withCandidateGroupsList

      public final ImmutableUserTaskRecordValue.Builder withCandidateGroupsList(Iterable<String> elements)
      Sets or replaces all elements for candidateGroupsList list.
      Parameters:
      elements - An iterable of candidateGroupsList elements
      Returns:
      this builder for use in a chained invocation
    • addAllCandidateGroupsList

      public final ImmutableUserTaskRecordValue.Builder addAllCandidateGroupsList(Iterable<String> elements)
      Adds elements to candidateGroupsList list.
      Parameters:
      elements - An iterable of candidateGroupsList elements
      Returns:
      this builder for use in a chained invocation
    • addCandidateUsersList

      public final ImmutableUserTaskRecordValue.Builder addCandidateUsersList(String element)
      Adds one element to candidateUsersList list.
      Parameters:
      element - A candidateUsersList element
      Returns:
      this builder for use in a chained invocation
    • addCandidateUsersList

      public final ImmutableUserTaskRecordValue.Builder addCandidateUsersList(String... elements)
      Adds elements to candidateUsersList list.
      Parameters:
      elements - An array of candidateUsersList elements
      Returns:
      this builder for use in a chained invocation
    • withCandidateUsersList

      public final ImmutableUserTaskRecordValue.Builder withCandidateUsersList(Iterable<String> elements)
      Sets or replaces all elements for candidateUsersList list.
      Parameters:
      elements - An iterable of candidateUsersList elements
      Returns:
      this builder for use in a chained invocation
    • addAllCandidateUsersList

      public final ImmutableUserTaskRecordValue.Builder addAllCandidateUsersList(Iterable<String> elements)
      Adds elements to candidateUsersList list.
      Parameters:
      elements - An iterable of candidateUsersList elements
      Returns:
      this builder for use in a chained invocation
    • withDueDate

      public final ImmutableUserTaskRecordValue.Builder withDueDate(String dueDate)
      Initializes the value for the dueDate attribute.
      Parameters:
      dueDate - The value for dueDate (can be null)
      Returns:
      this builder for use in a chained invocation
    • withFollowUpDate

      public final ImmutableUserTaskRecordValue.Builder withFollowUpDate(String followUpDate)
      Initializes the value for the followUpDate attribute.
      Parameters:
      followUpDate - The value for followUpDate (can be null)
      Returns:
      this builder for use in a chained invocation
    • withFormKey

      public final ImmutableUserTaskRecordValue.Builder withFormKey(long formKey)
      Initializes the value for the formKey attribute.
      Parameters:
      formKey - The value for formKey
      Returns:
      this builder for use in a chained invocation
    • addChangedAttribute

      public final ImmutableUserTaskRecordValue.Builder addChangedAttribute(String element)
      Adds one element to changedAttributes list.
      Parameters:
      element - A changedAttributes element
      Returns:
      this builder for use in a chained invocation
    • addChangedAttributes

      public final ImmutableUserTaskRecordValue.Builder addChangedAttributes(String... elements)
      Adds elements to changedAttributes list.
      Parameters:
      elements - An array of changedAttributes elements
      Returns:
      this builder for use in a chained invocation
    • withChangedAttributes

      public final ImmutableUserTaskRecordValue.Builder withChangedAttributes(Iterable<String> elements)
      Sets or replaces all elements for changedAttributes list.
      Parameters:
      elements - An iterable of changedAttributes elements
      Returns:
      this builder for use in a chained invocation
    • addAllChangedAttributes

      public final ImmutableUserTaskRecordValue.Builder addAllChangedAttributes(Iterable<String> elements)
      Adds elements to changedAttributes list.
      Parameters:
      elements - An iterable of changedAttributes elements
      Returns:
      this builder for use in a chained invocation
    • withAction

      public final ImmutableUserTaskRecordValue.Builder withAction(String action)
      Initializes the value for the action attribute.
      Parameters:
      action - The value for action (can be null)
      Returns:
      this builder for use in a chained invocation
    • withExternalFormReference

      public final ImmutableUserTaskRecordValue.Builder withExternalFormReference(String externalFormReference)
      Initializes the value for the externalFormReference attribute.
      Parameters:
      externalFormReference - The value for externalFormReference (can be null)
      Returns:
      this builder for use in a chained invocation
    • putCustomHeader

      public final ImmutableUserTaskRecordValue.Builder putCustomHeader(String key, String value)
      Put one entry to the customHeaders map.
      Parameters:
      key - The key in the customHeaders map
      value - The associated value in the customHeaders map
      Returns:
      this builder for use in a chained invocation
    • putCustomHeader

      public final ImmutableUserTaskRecordValue.Builder putCustomHeader(Map.Entry<String,? extends String> entry)
      Put one entry to the customHeaders map. Nulls are not permitted
      Parameters:
      entry - The key and value entry
      Returns:
      this builder for use in a chained invocation
    • withCustomHeaders

      public final ImmutableUserTaskRecordValue.Builder withCustomHeaders(Map<String,? extends String> entries)
      Sets or replaces all mappings from the specified map as entries for the customHeaders map. Nulls are not permitted
      Parameters:
      entries - The entries that will be added to the customHeaders map
      Returns:
      this builder for use in a chained invocation
    • putAllCustomHeaders

      public final ImmutableUserTaskRecordValue.Builder putAllCustomHeaders(Map<String,? extends String> entries)
      Put all mappings from the specified map as entries to customHeaders map. Nulls are not permitted
      Parameters:
      entries - The entries that will be added to the customHeaders map
      Returns:
      this builder for use in a chained invocation
    • withCreationTimestamp

      public final ImmutableUserTaskRecordValue.Builder withCreationTimestamp(long creationTimestamp)
      Initializes the value for the creationTimestamp attribute.
      Parameters:
      creationTimestamp - The value for creationTimestamp
      Returns:
      this builder for use in a chained invocation
    • withElementId

      public final ImmutableUserTaskRecordValue.Builder withElementId(String elementId)
      Initializes the value for the elementId attribute.
      Parameters:
      elementId - The value for elementId (can be null)
      Returns:
      this builder for use in a chained invocation
    • withElementInstanceKey

      public final ImmutableUserTaskRecordValue.Builder withElementInstanceKey(long elementInstanceKey)
      Initializes the value for the elementInstanceKey attribute.
      Parameters:
      elementInstanceKey - The value for elementInstanceKey
      Returns:
      this builder for use in a chained invocation
    • withBpmnProcessId

      public final ImmutableUserTaskRecordValue.Builder withBpmnProcessId(String bpmnProcessId)
      Initializes the value for the bpmnProcessId attribute.
      Parameters:
      bpmnProcessId - The value for bpmnProcessId (can be null)
      Returns:
      this builder for use in a chained invocation
    • withProcessDefinitionVersion

      public final ImmutableUserTaskRecordValue.Builder withProcessDefinitionVersion(int processDefinitionVersion)
      Initializes the value for the processDefinitionVersion attribute.
      Parameters:
      processDefinitionVersion - The value for processDefinitionVersion
      Returns:
      this builder for use in a chained invocation
    • withProcessDefinitionKey

      public final ImmutableUserTaskRecordValue.Builder withProcessDefinitionKey(long processDefinitionKey)
      Initializes the value for the processDefinitionKey attribute.
      Parameters:
      processDefinitionKey - The value for processDefinitionKey
      Returns:
      this builder for use in a chained invocation
    • withPriority

      public final ImmutableUserTaskRecordValue.Builder withPriority(int priority)
      Initializes the value for the priority attribute.
      Parameters:
      priority - The value for priority
      Returns:
      this builder for use in a chained invocation
    • clear

      Clear the builder to the initial state.
      Returns:
      this builder for use in a chained invocation
    • build

      Returns:
      An immutable instance of UserTaskRecordValue
      Throws:
      IllegalStateException - if any required attributes are missing