@NotThreadSafe public static final class ImmutableInsightUser.Builder extends Object
ImmutableInsightUser.
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.
| Modifier and Type | Method and Description |
|---|---|
ImmutableInsightUser |
build()
Builds a new
ImmutableInsightUser. |
ImmutableInsightUser.Builder |
from(InsightUser instance)
Fill a builder with attribute values from the provided
InsightUser instance. |
ImmutableInsightUser.Builder |
setDisplayName(String displayName)
Initializes the value for the
displayName attribute. |
ImmutableInsightUser.Builder |
setEmailAddress(String emailAddress)
Initializes the value for the
emailAddress attribute. |
ImmutableInsightUser.Builder |
setExternalId(String externalId)
Initializes the value for the
externalId attribute. |
ImmutableInsightUser.Builder |
setInsightRoles(Collection<InsightRole> insightRoles)
Initializes the value for the
insightRoles attribute. |
ImmutableInsightUser.Builder |
setKey(String key)
Initializes the value for the
key attribute. |
ImmutableInsightUser.Builder |
setLastSeenVersion(String lastSeenVersion)
Initializes the value for the
lastSeenVersion attribute. |
ImmutableInsightUser.Builder |
setName(String name)
Initializes the value for the
name attribute. |
@CanIgnoreReturnValue public final ImmutableInsightUser.Builder from(InsightUser instance)
InsightUser instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.instance - The instance from which to copy valuesthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableInsightUser.Builder setKey(String key)
key attribute.key - The value for keythis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableInsightUser.Builder setName(@Nullable String name)
name attribute.name - The value for name (can be null)this builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableInsightUser.Builder setDisplayName(@Nullable String displayName)
displayName attribute.displayName - The value for displayName (can be null)this builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableInsightUser.Builder setEmailAddress(@Nullable String emailAddress)
emailAddress attribute.emailAddress - The value for emailAddress (can be null)this builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableInsightUser.Builder setLastSeenVersion(@Nullable String lastSeenVersion)
lastSeenVersion attribute.lastSeenVersion - The value for lastSeenVersion (can be null)this builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableInsightUser.Builder setExternalId(@Nullable String externalId)
externalId attribute.externalId - The value for externalId (can be null)this builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableInsightUser.Builder setInsightRoles(@Nullable Collection<InsightRole> insightRoles)
insightRoles attribute.insightRoles - The value for insightRoles (can be null)this builder for use in a chained invocationpublic ImmutableInsightUser build()
ImmutableInsightUser.IllegalStateException - if any required attributes are missingCopyright © 2023 Atlassian. All rights reserved.