Package com.vmware.nsx_policy.model
Class SegmentDhcpConfig.Builder
- java.lang.Object
-
- com.vmware.nsx_policy.model.SegmentDhcpConfig.Builder
-
- Enclosing class:
- SegmentDhcpConfig
public static final class SegmentDhcpConfig.Builder extends java.lang.Object
Builder class forSegmentDhcpConfig
.
-
-
Constructor Summary
Constructors Constructor Description Builder()
Constructor with parameters for the required properties ofSegmentDhcpConfig
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SegmentDhcpConfig
build()
SegmentDhcpConfig.Builder
setDnsServers(java.util.List<java.lang.String> dnsServers)
IP address of DNS servers for subnet.SegmentDhcpConfig.Builder
setLeaseTime(java.lang.Long leaseTime)
DHCP lease time in seconds.SegmentDhcpConfig.Builder
setServerAddress(java.lang.String serverAddress)
IP address of the DHCP server in CIDR format.
-
-
-
Constructor Detail
-
Builder
public Builder()
Constructor with parameters for the required properties ofSegmentDhcpConfig
.
-
-
Method Detail
-
setDnsServers
public SegmentDhcpConfig.Builder setDnsServers(java.util.List<java.lang.String> dnsServers)
IP address of DNS servers for subnet. DNS server IP address must belong to the same address family as segment gateway_address property. format: ip- Parameters:
dnsServers
- New value for the property.
-
setLeaseTime
public SegmentDhcpConfig.Builder setLeaseTime(java.lang.Long leaseTime)
DHCP lease time in seconds. When specified, this property overwrites lease time configured DHCP server config. format: int64- Parameters:
leaseTime
- New value for the property.
-
setServerAddress
public SegmentDhcpConfig.Builder setServerAddress(java.lang.String serverAddress)
IP address of the DHCP server in CIDR format. The server_address is mandatory in case this segment has provided a dhcp_config_path and it represents a DHCP server config. If this SegmentDhcpConfig is a SegmentDhcpV4Config, the address must be an IPv4 address. If this is a SegmentDhcpV6Config, the address must be an IPv6 address. This address must not overlap the ip-ranges of the subnet, or the gateway address of the subnet, or the DHCP static-binding addresses of this segment. format: ip-cidr-block- Parameters:
serverAddress
- New value for the property.
-
build
public SegmentDhcpConfig build()
-
-