Package org.kiwiproject.consul.model.acl
Class ImmutablePolicyListResponse.Builder
java.lang.Object
org.kiwiproject.consul.model.acl.ImmutablePolicyListResponse.Builder
- Enclosing class:
- ImmutablePolicyListResponse
Builds instances of type
ImmutablePolicyListResponse.
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.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds a newImmutablePolicyListResponse.createIndex(BigInteger createIndex) Initializes the value for thecreateIndexattribute.datacenters(List<String> datacenters) Initializes the optional valuedatacentersto datacenters.datacenters(Optional<? extends List<String>> datacenters) Initializes the optional valuedatacentersto datacenters.from(BasePolicyResponse instance) Fill a builder with attribute values from the providedorg.kiwiproject.consul.model.acl.BasePolicyResponseinstance.from(PolicyListResponse instance) Fill a builder with attribute values from the providedorg.kiwiproject.consul.model.acl.PolicyListResponseinstance.Initializes the value for thehashattribute.Initializes the value for theidattribute.modifyIndex(BigInteger modifyIndex) Initializes the value for themodifyIndexattribute.Initializes the value for thenameattribute.
-
Method Details
-
from
@CanIgnoreReturnValue public final ImmutablePolicyListResponse.Builder from(BasePolicyResponse instance) Fill a builder with attribute values from the providedorg.kiwiproject.consul.model.acl.BasePolicyResponseinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
@CanIgnoreReturnValue public final ImmutablePolicyListResponse.Builder from(PolicyListResponse instance) Fill a builder with attribute values from the providedorg.kiwiproject.consul.model.acl.PolicyListResponseinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
id
Initializes the value for theidattribute.- Parameters:
id- The value for id- Returns:
thisbuilder for use in a chained invocation
-
name
Initializes the value for thenameattribute.- Parameters:
name- The value for name- Returns:
thisbuilder for use in a chained invocation
-
datacenters
@CanIgnoreReturnValue public final ImmutablePolicyListResponse.Builder datacenters(List<String> datacenters) Initializes the optional valuedatacentersto datacenters.- Parameters:
datacenters- The value for datacenters- Returns:
thisbuilder for chained invocation
-
datacenters
@CanIgnoreReturnValue public final ImmutablePolicyListResponse.Builder datacenters(Optional<? extends List<String>> datacenters) Initializes the optional valuedatacentersto datacenters.- Parameters:
datacenters- The value for datacenters- Returns:
thisbuilder for use in a chained invocation
-
hash
Initializes the value for thehashattribute.- Parameters:
hash- The value for hash- Returns:
thisbuilder for use in a chained invocation
-
createIndex
@CanIgnoreReturnValue public final ImmutablePolicyListResponse.Builder createIndex(BigInteger createIndex) Initializes the value for thecreateIndexattribute.- Parameters:
createIndex- The value for createIndex- Returns:
thisbuilder for use in a chained invocation
-
modifyIndex
@CanIgnoreReturnValue public final ImmutablePolicyListResponse.Builder modifyIndex(BigInteger modifyIndex) Initializes the value for themodifyIndexattribute.- Parameters:
modifyIndex- The value for modifyIndex- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutablePolicyListResponse.- Returns:
- An immutable instance of PolicyListResponse
- Throws:
IllegalStateException- if any required attributes are missing
-