Class ImmutableIssueCommentEvent.Builder
- java.lang.Object
-
- com.spotify.github.v3.activity.events.ImmutableIssueCommentEvent.Builder
-
- Enclosing class:
- ImmutableIssueCommentEvent
@NotThreadSafe public static final class ImmutableIssueCommentEvent.Builder extends Object
Builds instances of typeImmutableIssueCommentEvent. Initialize attributes and then invoke thebuild()method to create an immutable instance.Builderis not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ImmutableIssueCommentEvent.Builderaction(String action)Initializes the value for theactionattribute.ImmutableIssueCommentEventbuild()Builds a newImmutableIssueCommentEvent.ImmutableIssueCommentEvent.Builderchanges(Changes changes)Initializes the optional valuechangesto changes.ImmutableIssueCommentEvent.Builderchanges(Optional<? extends Changes> changes)Initializes the optional valuechangesto changes.ImmutableIssueCommentEvent.Buildercomment(Comment comment)Initializes the value for thecommentattribute.ImmutableIssueCommentEvent.BuildereventInstallation(EventInstallation eventInstallation)Initializes the value for theeventInstallationattribute.ImmutableIssueCommentEvent.Builderfrom(BaseEvent instance)Fill a builder with attribute values from the providedcom.spotify.github.v3.activity.events.BaseEventinstance.ImmutableIssueCommentEvent.Builderfrom(IssueCommentEvent instance)Fill a builder with attribute values from the providedcom.spotify.github.v3.activity.events.IssueCommentEventinstance.ImmutableIssueCommentEvent.Builderissue(Issue issue)Initializes the value for theissueattribute.ImmutableIssueCommentEvent.Builderrepository(Repository repository)Initializes the value for therepositoryattribute.ImmutableIssueCommentEvent.Buildersender(User sender)Initializes the value for thesenderattribute.
-
-
-
Method Detail
-
from
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder from(IssueCommentEvent instance)
Fill a builder with attribute values from the providedcom.spotify.github.v3.activity.events.IssueCommentEventinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder from(BaseEvent instance)
Fill a builder with attribute values from the providedcom.spotify.github.v3.activity.events.BaseEventinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
repository
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder repository(@Nullable Repository repository)
Initializes the value for therepositoryattribute.- Parameters:
repository- The value for repository (can benull)- Returns:
thisbuilder for use in a chained invocation
-
sender
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder sender(@Nullable User sender)
Initializes the value for thesenderattribute.- Parameters:
sender- The value for sender (can benull)- Returns:
thisbuilder for use in a chained invocation
-
eventInstallation
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder eventInstallation(@Nullable EventInstallation eventInstallation)
Initializes the value for theeventInstallationattribute.- Parameters:
eventInstallation- The value for eventInstallation (can benull)- Returns:
thisbuilder for use in a chained invocation
-
action
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder action(@Nullable String action)
Initializes the value for theactionattribute.- Parameters:
action- The value for action (can benull)- Returns:
thisbuilder for use in a chained invocation
-
changes
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder changes(Changes changes)
Initializes the optional valuechangesto changes.- Parameters:
changes- The value for changes- Returns:
thisbuilder for chained invocation
-
changes
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder changes(Optional<? extends Changes> changes)
Initializes the optional valuechangesto changes.- Parameters:
changes- The value for changes- Returns:
thisbuilder for use in a chained invocation
-
issue
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder issue(@Nullable Issue issue)
Initializes the value for theissueattribute.- Parameters:
issue- The value for issue (can benull)- Returns:
thisbuilder for use in a chained invocation
-
comment
@CanIgnoreReturnValue public final ImmutableIssueCommentEvent.Builder comment(@Nullable Comment comment)
Initializes the value for thecommentattribute.- Parameters:
comment- The value for comment (can benull)- Returns:
thisbuilder for use in a chained invocation
-
build
public ImmutableIssueCommentEvent build()
Builds a newImmutableIssueCommentEvent.- Returns:
- An immutable instance of IssueCommentEvent
- Throws:
IllegalStateException- if any required attributes are missing
-
-