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.Builder
is 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 ImmutableBody
build()
Builds a newImmutableBody
.ImmutableBody.Builder
from(String from)
Initializes the value for thefrom
attribute.
-
-
-
Method Detail
-
from
@CanIgnoreReturnValue public final ImmutableBody.Builder from(@Nullable String from)
Initializes the value for thefrom
attribute.- Parameters:
from
- The value for from (can benull
)- Returns:
this
builder 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
-
-