Class UserProfile.Builder

java.lang.Object
com.hubspot.slack.client.models.users.UserProfile.Builder
Enclosing class:
UserProfile

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

      public final UserProfile.Builder from(UserProfileIF instance)
      Fill a builder with attribute values from the provided UserProfileIF instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.
      Parameters:
      instance - The instance from which to copy values
      Returns:
      this builder for use in a chained invocation
    • setUsername

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

      public final UserProfile.Builder setUsername(Optional<String> username)
      Initializes the optional value username to username.
      Parameters:
      username - The value for username
      Returns:
      this builder for use in a chained invocation
    • setUsernameNormalized

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

      public final UserProfile.Builder setUsernameNormalized(Optional<String> usernameNormalized)
      Initializes the optional value usernameNormalized to usernameNormalized.
      Parameters:
      usernameNormalized - The value for usernameNormalized
      Returns:
      this builder for use in a chained invocation
    • setRealName

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

      public final UserProfile.Builder setRealName(Optional<String> realName)
      Initializes the optional value realName to realName.
      Parameters:
      realName - The value for realName
      Returns:
      this builder for use in a chained invocation
    • setRealNameNormalized

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

      public final UserProfile.Builder setRealNameNormalized(Optional<String> realNameNormalized)
      Initializes the optional value realNameNormalized to realNameNormalized.
      Parameters:
      realNameNormalized - The value for realNameNormalized
      Returns:
      this builder for use in a chained invocation
    • setEmail

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

      public final UserProfile.Builder setEmail(Optional<String> email)
      Initializes the optional value email to email.
      Parameters:
      email - The value for email
      Returns:
      this builder for use in a chained invocation
    • setStatusText

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

      public final UserProfile.Builder setStatusText(Optional<String> statusText)
      Initializes the optional value statusText to statusText.
      Parameters:
      statusText - The value for statusText
      Returns:
      this builder for use in a chained invocation
    • setStatusEmoji

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

      public final UserProfile.Builder setStatusEmoji(Optional<String> statusEmoji)
      Initializes the optional value statusEmoji to statusEmoji.
      Parameters:
      statusEmoji - The value for statusEmoji
      Returns:
      this builder for use in a chained invocation
    • setStatusExpiration

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

      public final UserProfile.Builder setStatusExpiration(Optional<Long> statusExpiration)
      Initializes the optional value statusExpiration to statusExpiration.
      Parameters:
      statusExpiration - The value for statusExpiration
      Returns:
      this builder for use in a chained invocation
    • setTitle

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

      public final UserProfile.Builder setTitle(Optional<String> title)
      Initializes the optional value title to title.
      Parameters:
      title - The value for title
      Returns:
      this builder for use in a chained invocation
    • setPhone

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

      public final UserProfile.Builder setPhone(Optional<String> phone)
      Initializes the optional value phone to phone.
      Parameters:
      phone - The value for phone
      Returns:
      this builder for use in a chained invocation
    • setSkype

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

      public final UserProfile.Builder setSkype(Optional<String> skype)
      Initializes the optional value skype to skype.
      Parameters:
      skype - The value for skype
      Returns:
      this builder for use in a chained invocation
    • setPronouns

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

      public final UserProfile.Builder setPronouns(Optional<String> pronouns)
      Initializes the optional value pronouns to pronouns.
      Parameters:
      pronouns - The value for pronouns
      Returns:
      this builder for use in a chained invocation
    • setFields

      public final UserProfile.Builder setFields(@Nullable Map<String,ProfileField> fields)
      Initializes the optional value fields to fields.
      Parameters:
      fields - The value for fields, null is accepted as java.util.Optional.empty()
      Returns:
      this builder for chained invocation
    • setFields

      public final UserProfile.Builder setFields(Optional<? extends Map<String,ProfileField>> fields)
      Initializes the optional value fields to fields.
      Parameters:
      fields - The value for fields
      Returns:
      this builder for use in a chained invocation
    • setTeamId

      public final UserProfile.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 UserProfile.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
    • setAvatarHash

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

      public final UserProfile.Builder setAvatarHash(Optional<String> avatarHash)
      Initializes the optional value avatarHash to avatarHash.
      Parameters:
      avatarHash - The value for avatarHash
      Returns:
      this builder for use in a chained invocation
    • setImageOriginal

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

      public final UserProfile.Builder setImageOriginal(Optional<String> imageOriginal)
      Initializes the optional value imageOriginal to imageOriginal.
      Parameters:
      imageOriginal - The value for imageOriginal
      Returns:
      this builder for use in a chained invocation
    • setImage24

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

      public final UserProfile.Builder setImage24(Optional<String> image24)
      Initializes the optional value image24 to image24.
      Parameters:
      image24 - The value for image24
      Returns:
      this builder for use in a chained invocation
    • setImage32

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

      public final UserProfile.Builder setImage32(Optional<String> image32)
      Initializes the optional value image32 to image32.
      Parameters:
      image32 - The value for image32
      Returns:
      this builder for use in a chained invocation
    • setImage48

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

      public final UserProfile.Builder setImage48(Optional<String> image48)
      Initializes the optional value image48 to image48.
      Parameters:
      image48 - The value for image48
      Returns:
      this builder for use in a chained invocation
    • setImage72

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

      public final UserProfile.Builder setImage72(Optional<String> image72)
      Initializes the optional value image72 to image72.
      Parameters:
      image72 - The value for image72
      Returns:
      this builder for use in a chained invocation
    • setImage192

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

      public final UserProfile.Builder setImage192(Optional<String> image192)
      Initializes the optional value image192 to image192.
      Parameters:
      image192 - The value for image192
      Returns:
      this builder for use in a chained invocation
    • setImage512

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

      public final UserProfile.Builder setImage512(Optional<String> image512)
      Initializes the optional value image512 to image512.
      Parameters:
      image512 - The value for image512
      Returns:
      this builder for use in a chained invocation
    • setImage1024

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

      public final UserProfile.Builder setImage1024(Optional<String> image1024)
      Initializes the optional value image1024 to image1024.
      Parameters:
      image1024 - The value for image1024
      Returns:
      this builder for use in a chained invocation
    • build

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