Class ContainerDependency.Builder
java.lang.Object
software.amazon.awscdk.services.ecs.ContainerDependency.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<ContainerDependency>
- Enclosing interface:
ContainerDependency
@Stability(Stable)
public static final class ContainerDependency.Builder
extends Object
implements software.amazon.jsii.Builder<ContainerDependency>
A builder for
ContainerDependency
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.condition
(ContainerDependencyCondition condition) Sets the value ofContainerDependency.getCondition()
container
(ContainerDefinition container) Sets the value ofContainerDependency.getContainer()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
container
Sets the value ofContainerDependency.getContainer()
- Parameters:
container
- The container to depend on. This parameter is required.- Returns:
this
-
condition
@Stability(Stable) public ContainerDependency.Builder condition(ContainerDependencyCondition condition) Sets the value ofContainerDependency.getCondition()
- Parameters:
condition
- The state the container needs to be in to satisfy the dependency and proceed with startup. Valid values are ContainerDependencyCondition.START, ContainerDependencyCondition.COMPLETE, ContainerDependencyCondition.SUCCESS and ContainerDependencyCondition.HEALTHY.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<ContainerDependency>
- Returns:
- a new instance of
ContainerDependency
- Throws:
NullPointerException
- if any required attribute was not provided
-