Package com.spotify.github.v3.checks
Class ImmutableCheckRunImage.Builder
- java.lang.Object
-
- com.spotify.github.v3.checks.ImmutableCheckRunImage.Builder
-
- Enclosing class:
- ImmutableCheckRunImage
@NotThreadSafe public static final class ImmutableCheckRunImage.Builder extends Object
Builds instances of typeImmutableCheckRunImage
. 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 ImmutableCheckRunImage.Builder
alt(String alt)
Initializes the value for thealt
attribute.ImmutableCheckRunImage
build()
Builds a newImmutableCheckRunImage
.ImmutableCheckRunImage.Builder
caption(String caption)
Initializes the optional valuecaption
to caption.ImmutableCheckRunImage.Builder
caption(Optional<String> caption)
Initializes the optional valuecaption
to caption.ImmutableCheckRunImage.Builder
from(CheckRunImage instance)
Fill a builder with attribute values from the providedCheckRunImage
instance.ImmutableCheckRunImage.Builder
imageUrl(String imageUrl)
Initializes the value for theimageUrl
attribute.
-
-
-
Method Detail
-
from
@CanIgnoreReturnValue public final ImmutableCheckRunImage.Builder from(CheckRunImage instance)
Fill a builder with attribute values from the providedCheckRunImage
instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
alt
@CanIgnoreReturnValue public final ImmutableCheckRunImage.Builder alt(String alt)
Initializes the value for thealt
attribute.- Parameters:
alt
- The value for alt- Returns:
this
builder for use in a chained invocation
-
imageUrl
@CanIgnoreReturnValue public final ImmutableCheckRunImage.Builder imageUrl(String imageUrl)
Initializes the value for theimageUrl
attribute.- Parameters:
imageUrl
- The value for imageUrl- Returns:
this
builder for use in a chained invocation
-
caption
@CanIgnoreReturnValue public final ImmutableCheckRunImage.Builder caption(String caption)
Initializes the optional valuecaption
to caption.- Parameters:
caption
- The value for caption- Returns:
this
builder for chained invocation
-
caption
@CanIgnoreReturnValue public final ImmutableCheckRunImage.Builder caption(Optional<String> caption)
Initializes the optional valuecaption
to caption.- Parameters:
caption
- The value for caption- Returns:
this
builder for use in a chained invocation
-
build
public ImmutableCheckRunImage build()
Builds a newImmutableCheckRunImage
.- Returns:
- An immutable instance of CheckRunImage
- Throws:
IllegalStateException
- if any required attributes are missing
-
-