Class MachineImage.Builder
java.lang.Object
co.yellowdog.platform.model.builders.ValidatedBuilder<MachineImage>
co.yellowdog.platform.model.MachineImage.Builder
- Enclosing class:
MachineImage
A builder that can be used to build a new MachineImage that is automatically validated on build.
-
Method Summary
Modifier and TypeMethodDescriptionBuilds the object without enforcing validation constraints.osType(ImageOsType osType) provider(CloudProvider provider) providerImageId(String providerImageId) regions(Collection<? extends String> regions) supportedInstanceType(String supportedInstanceType) supportedInstanceTypes(Collection<? extends String> supportedInstanceTypes) toString()Methods inherited from class ValidatedBuilder
build, validateModifier and TypeMethodDescriptionbuild()Builds and validates the object.Set<jakarta.validation.ConstraintViolation<MachineImage>> validate()Performs validation based on the current builder properties and returns the ConstraintViolations without throwing.
-
Method Details
-
name
- Returns:
this.
-
provider
- Returns:
this.
-
region
-
regions
-
clearRegions
-
providerImageId
- Returns:
this.
-
osType
- Returns:
this.
-
supportedInstanceType
-
supportedInstanceTypes
public MachineImage.Builder supportedInstanceTypes(Collection<? extends String> supportedInstanceTypes) -
clearSupportedInstanceTypes
-
metadata
-
metadata
-
clearMetadata
-
buildUnchecked
Description copied from class:ValidatedBuilderBuilds the object without enforcing validation constraints. Use this when the object is validated later, for example as part of an enclosing object built withValidatedBuilder.build(), or when it does not need to be valid on its own.- Overrides:
buildUncheckedin classValidatedBuilder<MachineImage>- Returns:
- the object being built
-
toString
-