Class UsergroupPreferences.Builder

java.lang.Object
com.hubspot.slack.client.models.usergroups.UsergroupPreferences.Builder
Enclosing class:
UsergroupPreferences

@Generated(from="UsergroupPreferencesIF", generator="Immutables") @NotThreadSafe public static final class UsergroupPreferences.Builder extends Object
Builds instances of type UsergroupPreferences. 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 UsergroupPreferencesIF 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
    • addChannelIdsUsersAutojoin

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

      public final UsergroupPreferences.Builder addChannelIdsUsersAutojoin(String... elements)
      Adds elements to channelIdsUsersAutojoin list.
      Parameters:
      elements - An array of channelIdsUsersAutojoin elements
      Returns:
      this builder for use in a chained invocation
    • setChannelIdsUsersAutojoin

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

      public final UsergroupPreferences.Builder addAllChannelIdsUsersAutojoin(Iterable<String> elements)
      Adds elements to channelIdsUsersAutojoin list.
      Parameters:
      elements - An iterable of channelIdsUsersAutojoin elements
      Returns:
      this builder for use in a chained invocation
    • addGroupsUsersAutojoin

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

      public final UsergroupPreferences.Builder addGroupsUsersAutojoin(String... elements)
      Adds elements to groupsUsersAutojoin list.
      Parameters:
      elements - An array of groupsUsersAutojoin elements
      Returns:
      this builder for use in a chained invocation
    • setGroupsUsersAutojoin

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

      public final UsergroupPreferences.Builder addAllGroupsUsersAutojoin(Iterable<String> elements)
      Adds elements to groupsUsersAutojoin list.
      Parameters:
      elements - An iterable of groupsUsersAutojoin elements
      Returns:
      this builder for use in a chained invocation
    • build

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