@NotThreadSafe public static final class ImmutableCatalogService.Builder extends Object
ImmutableCatalogService.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
@CanIgnoreReturnValue public final ImmutableCatalogService.Builder from(CatalogService instance)
CatalogService instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.
Collection elements and entries will be added, not replaced.instance - The instance from which to copy valuesthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder node(String node)
node attribute.node - The value for nodethis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder address(String address)
address attribute.address - The value for addressthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder datacenter(String datacenter)
datacenter to datacenter.datacenter - The value for datacenterthis builder for chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder datacenter(Optional<String> datacenter)
datacenter to datacenter.datacenter - The value for datacenterthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceName(String serviceName)
serviceName attribute.serviceName - The value for serviceNamethis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceId(String serviceId)
serviceId attribute.serviceId - The value for serviceIdthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceAddress(String serviceAddress)
serviceAddress attribute.serviceAddress - The value for serviceAddressthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceEnableTagOverride(boolean serviceEnableTagOverride)
serviceEnableTagOverride to serviceEnableTagOverride.serviceEnableTagOverride - The value for serviceEnableTagOverridethis builder for chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceEnableTagOverride(Optional<Boolean> serviceEnableTagOverride)
serviceEnableTagOverride to serviceEnableTagOverride.serviceEnableTagOverride - The value for serviceEnableTagOverridethis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder servicePort(int servicePort)
servicePort attribute.servicePort - The value for servicePortthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder addServiceTags(String element)
serviceTags list.element - A serviceTags elementthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder addServiceTags(String... elements)
serviceTags list.elements - An array of serviceTags elementsthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceTags(Iterable<String> elements)
serviceTags list.elements - An iterable of serviceTags elementsthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder addAllServiceTags(Iterable<String> elements)
serviceTags list.elements - An iterable of serviceTags elementsthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder putServiceMeta(String key, String value)
serviceMeta map.key - The key in the serviceMeta mapvalue - The associated value in the serviceMeta mapthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder putServiceMeta(Map.Entry<String,? extends String> entry)
serviceMeta map. Nulls are not permittedentry - The key and value entrythis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceMeta(Map<String,? extends String> entries)
serviceMeta map. Nulls are not permittedentries - The entries that will be added to the serviceMeta mapthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder putAllServiceMeta(Map<String,? extends String> entries)
serviceMeta map. Nulls are not permittedentries - The entries that will be added to the serviceMeta mapthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceWeights(ServiceWeights serviceWeights)
serviceWeights to serviceWeights.serviceWeights - The value for serviceWeightsthis builder for chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder serviceWeights(Optional<? extends ServiceWeights> serviceWeights)
serviceWeights to serviceWeights.serviceWeights - The value for serviceWeightsthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder putNodeMeta(String key, String value)
nodeMeta map.key - The key in the nodeMeta mapvalue - The associated value in the nodeMeta mapthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder putNodeMeta(Map.Entry<String,? extends String> entry)
nodeMeta map. Nulls are not permittedentry - The key and value entrythis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder nodeMeta(Map<String,? extends String> entries)
nodeMeta map. Nulls are not permittedentries - The entries that will be added to the nodeMeta mapthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableCatalogService.Builder putAllNodeMeta(Map<String,? extends String> entries)
nodeMeta map. Nulls are not permittedentries - The entries that will be added to the nodeMeta mapthis builder for use in a chained invocationpublic ImmutableCatalogService build()
ImmutableCatalogService.IllegalStateException - if any required attributes are missingCopyright © 2019. All rights reserved.