Class TcpRouteSpecOptions.Builder
java.lang.Object
software.amazon.awscdk.services.appmesh.TcpRouteSpecOptions.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<TcpRouteSpecOptions>
- Enclosing interface:
TcpRouteSpecOptions
@Stability(Stable)
public static final class TcpRouteSpecOptions.Builder
extends Object
implements software.amazon.jsii.Builder<TcpRouteSpecOptions>
A builder for
TcpRouteSpecOptions-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.Sets the value ofRouteSpecOptionsBase.getPriority()timeout(TcpTimeout timeout) Sets the value ofTcpRouteSpecOptions.getTimeout()weightedTargets(List<? extends WeightedTarget> weightedTargets) Sets the value ofTcpRouteSpecOptions.getWeightedTargets()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
weightedTargets
@Stability(Stable) public TcpRouteSpecOptions.Builder weightedTargets(List<? extends WeightedTarget> weightedTargets) Sets the value ofTcpRouteSpecOptions.getWeightedTargets()- Parameters:
weightedTargets- List of targets that traffic is routed to when a request matches the route. This parameter is required.- Returns:
this
-
timeout
Sets the value ofTcpRouteSpecOptions.getTimeout()- Parameters:
timeout- An object that represents a tcp timeout.- Returns:
this
-
priority
Sets the value ofRouteSpecOptionsBase.getPriority()- Parameters:
priority- The priority for the route. When a Virtual Router has multiple routes, route match is performed in the order of specified value, where 0 is the highest priority, and first matched route is selected.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<TcpRouteSpecOptions>- Returns:
- a new instance of
TcpRouteSpecOptions - Throws:
NullPointerException- if any required attribute was not provided
-