Class MigrationExchangeParams.Builder

java.lang.Object
com.hubspot.slack.client.methods.params.migration.MigrationExchangeParams.Builder
Enclosing class:
MigrationExchangeParams

@Generated(from="MigrationExchangeParamsIF", generator="Immutables") @NotThreadSafe public static final class MigrationExchangeParams.Builder extends Object
Builds instances of type MigrationExchangeParams. 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 MigrationExchangeParamsIF instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • setTeamId

      public final MigrationExchangeParams.Builder setTeamId(@Nullable String teamId)
      Initializes the optional value teamId to teamId.
      Parameters:
      teamId - The value for teamId, null is accepted as java.util.Optional.empty()
      Returns:
      this builder for chained invocation
    • setTeamId

      public final MigrationExchangeParams.Builder setTeamId(Optional<String> teamId)
      Initializes the optional value teamId to teamId.
      Parameters:
      teamId - The value for teamId
      Returns:
      this builder for use in a chained invocation
    • setToOld

      public final MigrationExchangeParams.Builder setToOld(@Nullable Boolean toOld)
      Initializes the optional value toOld to toOld.
      Parameters:
      toOld - The value for toOld, null is accepted as java.util.Optional.empty()
      Returns:
      this builder for chained invocation
    • setToOld

      public final MigrationExchangeParams.Builder setToOld(Optional<Boolean> toOld)
      Initializes the optional value toOld to toOld.
      Parameters:
      toOld - The value for toOld
      Returns:
      this builder for use in a chained invocation
    • addUserIds

      public final MigrationExchangeParams.Builder addUserIds(String element)
      Adds one element to userIds set.
      Parameters:
      element - A userIds element
      Returns:
      this builder for use in a chained invocation
    • addUserIds

      public final MigrationExchangeParams.Builder addUserIds(String... elements)
      Adds elements to userIds set.
      Parameters:
      elements - An array of userIds elements
      Returns:
      this builder for use in a chained invocation
    • setUserIds

      public final MigrationExchangeParams.Builder setUserIds(Iterable<String> elements)
      Sets or replaces all elements for userIds set.
      Parameters:
      elements - An iterable of userIds elements
      Returns:
      this builder for use in a chained invocation
    • addAllUserIds

      public final MigrationExchangeParams.Builder addAllUserIds(Iterable<String> elements)
      Adds elements to userIds set.
      Parameters:
      elements - An iterable of userIds elements
      Returns:
      this builder for use in a chained invocation
    • build

      public MigrationExchangeParams build()
      Returns:
      An immutable instance of MigrationExchangeParams
      Throws:
      com.hubspot.immutables.validation.InvalidImmutableStateException - if any required attributes are missing