Package software.amazon.awscdk.core
Class DockerVolume.Builder
java.lang.Object
software.amazon.awscdk.core.DockerVolume.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<DockerVolume>
- Enclosing interface:
- DockerVolume
@Stability(Stable)
public static final class DockerVolume.Builder
extends Object
implements software.amazon.jsii.Builder<DockerVolume>
A builder for
DockerVolume
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.consistency
(DockerVolumeConsistency consistency) Sets the value ofDockerVolume.getConsistency()
containerPath
(String containerPath) Sets the value ofDockerVolume.getContainerPath()
Sets the value ofDockerVolume.getHostPath()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
containerPath
Sets the value ofDockerVolume.getContainerPath()
- Parameters:
containerPath
- The path where the file or directory is mounted in the container. This parameter is required.- Returns:
this
-
hostPath
Sets the value ofDockerVolume.getHostPath()
- Parameters:
hostPath
- The path to the file or directory on the host machine. This parameter is required.- Returns:
this
-
consistency
Sets the value ofDockerVolume.getConsistency()
- Parameters:
consistency
- Mount consistency. Only applicable for macOS- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<DockerVolume>
- Returns:
- a new instance of
DockerVolume
- Throws:
NullPointerException
- if any required attribute was not provided
-