Class ImmutableBody.Builder
- java.lang.Object
-
- com.spotify.github.v3.issues.changes.ImmutableBody.Builder
-
- Enclosing class:
- ImmutableBody
@NotThreadSafe public static final class ImmutableBody.Builder extends Object
Builds instances of typeImmutableBody. 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 ImmutableBodybuild()Builds a newImmutableBody.ImmutableBody.Builderfrom(String from)Initializes the value for thefromattribute.
-
-
-
Method Detail
-
from
@CanIgnoreReturnValue public final ImmutableBody.Builder from(@Nullable String from)
Initializes the value for thefromattribute.- Parameters:
from- The value for from (can benull)- Returns:
thisbuilder for use in a chained invocation
-
build
public ImmutableBody build()
Builds a newImmutableBody.- Returns:
- An immutable instance of Body
- Throws:
IllegalStateException- if any required attributes are missing
-
-