Class Policy.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
io.envoyproxy.envoy.config.rbac.v2.Policy.Builder
- All Implemented Interfaces:
com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,PolicyOrBuilder,Cloneable
- Enclosing class:
- Policy
public static final class Policy.Builder
extends com.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
implements PolicyOrBuilder
Policy specifies a role and the principals that are assigned/denied the role. A policy matches if and only if at least one of its permissions match the action taking place AND at least one of its principals match the downstream AND the condition is true if specified.Protobuf type
envoy.config.rbac.v2.Policy-
Method Summary
Modifier and TypeMethodDescriptionaddAllPermissions(Iterable<? extends Permission> values) Required.addAllPrincipals(Iterable<? extends Principal> values) Required.addPermissions(int index, Permission value) Required.addPermissions(int index, Permission.Builder builderForValue) Required.addPermissions(Permission value) Required.addPermissions(Permission.Builder builderForValue) Required.Required.addPermissionsBuilder(int index) Required.addPrincipals(int index, Principal value) Required.addPrincipals(int index, Principal.Builder builderForValue) Required.addPrincipals(Principal value) Required.addPrincipals(Principal.Builder builderForValue) Required.Required.addPrincipalsBuilder(int index) Required.addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) build()clear()An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`.clearField(com.google.protobuf.Descriptors.FieldDescriptor field) clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) Required.Required.clone()An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`.An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`.An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorgetPermissions(int index) Required.getPermissionsBuilder(int index) Required.Required.intRequired.Required.getPermissionsOrBuilder(int index) Required.List<? extends PermissionOrBuilder>Required.getPrincipals(int index) Required.getPrincipalsBuilder(int index) Required.Required.intRequired.Required.getPrincipalsOrBuilder(int index) Required.List<? extends PrincipalOrBuilder>Required.booleanAn optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleanmergeCondition(Expr value) An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`.mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) final Policy.BuildermergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) removePermissions(int index) Required.removePrincipals(int index) Required.setCondition(Expr value) An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`.setCondition(Expr.Builder builderForValue) An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`.setPermissions(int index, Permission value) Required.setPermissions(int index, Permission.Builder builderForValue) Required.setPrincipals(int index, Principal value) Required.setPrincipals(int index, Principal.Builder builderForValue) Required.setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) final Policy.BuildersetUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
clone
- Specified by:
clonein interfacecom.google.protobuf.Message.Builder- Specified by:
clonein interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clonein classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
setField
- Specified by:
setFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
clearField
- Specified by:
clearFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
clearFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
clearOneof
- Specified by:
clearOneofin interfacecom.google.protobuf.Message.Builder- Overrides:
clearOneofin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
setRepeatedField
public Policy.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) - Specified by:
setRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
addRepeatedField
public Policy.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
addRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
addRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<Policy.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
mergeFrom
public Policy.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<Policy.Builder>- Throws:
IOException
-
getPermissionsList
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... }- Specified by:
getPermissionsListin interfacePolicyOrBuilder
-
getPermissionsCount
public int getPermissionsCount()Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... }- Specified by:
getPermissionsCountin interfacePolicyOrBuilder
-
getPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... }- Specified by:
getPermissionsin interfacePolicyOrBuilder
-
setPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
setPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
addPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
addPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
addPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
addPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
addAllPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
clearPermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
removePermissions
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
getPermissionsBuilder
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
getPermissionsOrBuilder
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... }- Specified by:
getPermissionsOrBuilderin interfacePolicyOrBuilder
-
getPermissionsOrBuilderList
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... }- Specified by:
getPermissionsOrBuilderListin interfacePolicyOrBuilder
-
addPermissionsBuilder
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
addPermissionsBuilder
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
getPermissionsBuilderList
Required. The set of permissions that define a role. Each permission is matched with OR semantics. To match all actions for this policy, a single Permission with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Permission permissions = 1 [(.validate.rules) = { ... } -
getPrincipalsList
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... }- Specified by:
getPrincipalsListin interfacePolicyOrBuilder
-
getPrincipalsCount
public int getPrincipalsCount()Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... }- Specified by:
getPrincipalsCountin interfacePolicyOrBuilder
-
getPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... }- Specified by:
getPrincipalsin interfacePolicyOrBuilder
-
setPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
setPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
addPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
addPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
addPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
addPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
addAllPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
clearPrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
removePrincipals
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
getPrincipalsBuilder
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
getPrincipalsOrBuilder
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... }- Specified by:
getPrincipalsOrBuilderin interfacePolicyOrBuilder
-
getPrincipalsOrBuilderList
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... }- Specified by:
getPrincipalsOrBuilderListin interfacePolicyOrBuilder
-
addPrincipalsBuilder
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
addPrincipalsBuilder
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
getPrincipalsBuilderList
Required. The set of principals that are assigned/denied the role based on “action”. Each principal is matched with OR semantics. To match all downstreams for this policy, a single Principal with the `any` field set to true should be used.
repeated .envoy.config.rbac.v2.Principal principals = 2 [(.validate.rules) = { ... } -
hasCondition
public boolean hasCondition()An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`. The condition is combined with the permissions and the principals as a clause with AND semantics.
.google.api.expr.v1alpha1.Expr condition = 3;- Specified by:
hasConditionin interfacePolicyOrBuilder- Returns:
- Whether the condition field is set.
-
getCondition
An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`. The condition is combined with the permissions and the principals as a clause with AND semantics.
.google.api.expr.v1alpha1.Expr condition = 3;- Specified by:
getConditionin interfacePolicyOrBuilder- Returns:
- The condition.
-
setCondition
An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`. The condition is combined with the permissions and the principals as a clause with AND semantics.
.google.api.expr.v1alpha1.Expr condition = 3; -
setCondition
An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`. The condition is combined with the permissions and the principals as a clause with AND semantics.
.google.api.expr.v1alpha1.Expr condition = 3; -
mergeCondition
An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`. The condition is combined with the permissions and the principals as a clause with AND semantics.
.google.api.expr.v1alpha1.Expr condition = 3; -
clearCondition
An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`. The condition is combined with the permissions and the principals as a clause with AND semantics.
.google.api.expr.v1alpha1.Expr condition = 3; -
getConditionBuilder
An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`. The condition is combined with the permissions and the principals as a clause with AND semantics.
.google.api.expr.v1alpha1.Expr condition = 3; -
getConditionOrBuilder
An optional symbolic expression specifying an access control :ref:`condition <arch_overview_condition>`. The condition is combined with the permissions and the principals as a clause with AND semantics.
.google.api.expr.v1alpha1.Expr condition = 3;- Specified by:
getConditionOrBuilderin interfacePolicyOrBuilder
-
setUnknownFields
- Specified by:
setUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
setUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-
mergeUnknownFields
- Specified by:
mergeUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<Policy.Builder>
-