Package com.spotify.github.v3.checks
Class ImmutableCheckRunResponseList.Builder
- java.lang.Object
-
- com.spotify.github.v3.checks.ImmutableCheckRunResponseList.Builder
-
- Enclosing class:
- ImmutableCheckRunResponseList
@NotThreadSafe public static final class ImmutableCheckRunResponseList.Builder extends Object
Builds instances of typeImmutableCheckRunResponseList. 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 ImmutableCheckRunResponseList.BuilderaddAllCheckRuns(Iterable<? extends CheckRunResponse> elements)Adds elements tocheckRunslist.ImmutableCheckRunResponseList.BuilderaddCheckRuns(CheckRunResponse element)Adds one element tocheckRunslist.ImmutableCheckRunResponseList.BuilderaddCheckRuns(CheckRunResponse... elements)Adds elements tocheckRunslist.ImmutableCheckRunResponseListbuild()Builds a newImmutableCheckRunResponseList.ImmutableCheckRunResponseList.BuildercheckRuns(Iterable<? extends CheckRunResponse> elements)Sets or replaces all elements forcheckRunslist.ImmutableCheckRunResponseList.Builderfrom(CheckRunResponseList instance)Fill a builder with attribute values from the providedCheckRunResponseListinstance.ImmutableCheckRunResponseList.BuildertotalCount(int totalCount)Initializes the value for thetotalCountattribute.
-
-
-
Method Detail
-
from
@CanIgnoreReturnValue public final ImmutableCheckRunResponseList.Builder from(CheckRunResponseList instance)
Fill a builder with attribute values from the providedCheckRunResponseListinstance. 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:
thisbuilder for use in a chained invocation
-
totalCount
@CanIgnoreReturnValue public final ImmutableCheckRunResponseList.Builder totalCount(int totalCount)
Initializes the value for thetotalCountattribute.- Parameters:
totalCount- The value for totalCount- Returns:
thisbuilder for use in a chained invocation
-
addCheckRuns
@CanIgnoreReturnValue public final ImmutableCheckRunResponseList.Builder addCheckRuns(CheckRunResponse element)
Adds one element tocheckRunslist.- Parameters:
element- A checkRuns element- Returns:
thisbuilder for use in a chained invocation
-
addCheckRuns
@CanIgnoreReturnValue public final ImmutableCheckRunResponseList.Builder addCheckRuns(CheckRunResponse... elements)
Adds elements tocheckRunslist.- Parameters:
elements- An array of checkRuns elements- Returns:
thisbuilder for use in a chained invocation
-
checkRuns
@CanIgnoreReturnValue public final ImmutableCheckRunResponseList.Builder checkRuns(Iterable<? extends CheckRunResponse> elements)
Sets or replaces all elements forcheckRunslist.- Parameters:
elements- An iterable of checkRuns elements- Returns:
thisbuilder for use in a chained invocation
-
addAllCheckRuns
@CanIgnoreReturnValue public final ImmutableCheckRunResponseList.Builder addAllCheckRuns(Iterable<? extends CheckRunResponse> elements)
Adds elements tocheckRunslist.- Parameters:
elements- An iterable of checkRuns elements- Returns:
thisbuilder for use in a chained invocation
-
build
public ImmutableCheckRunResponseList build()
Builds a newImmutableCheckRunResponseList.- Returns:
- An immutable instance of CheckRunResponseList
- Throws:
IllegalStateException- if any required attributes are missing
-
-