Class AuthorizationPolicy.Rule.Source.Builder

    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<AuthorizationPolicy.Rule.Source.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<AuthorizationPolicy.Rule.Source.Builder>
      • getDefaultInstanceForType

        public AuthorizationPolicy.Rule.Source getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public AuthorizationPolicy.Rule.Source build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public AuthorizationPolicy.Rule.Source buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<AuthorizationPolicy.Rule.Source.Builder>
      • getPrincipalsList

        public com.google.protobuf.ProtocolStringList getPrincipalsList()
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getPrincipalsList in interface AuthorizationPolicy.Rule.SourceOrBuilder
        Returns:
        A list containing the principals.
      • getPrincipalsCount

        public int getPrincipalsCount()
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getPrincipalsCount in interface AuthorizationPolicy.Rule.SourceOrBuilder
        Returns:
        The count of principals.
      • getPrincipals

        public String getPrincipals​(int index)
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getPrincipals in interface AuthorizationPolicy.Rule.SourceOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The principals at the given index.
      • getPrincipalsBytes

        public com.google.protobuf.ByteString getPrincipalsBytes​(int index)
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getPrincipalsBytes in interface AuthorizationPolicy.Rule.SourceOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the principals at the given index.
      • setPrincipals

        public AuthorizationPolicy.Rule.Source.Builder setPrincipals​(int index,
                                                                     String value)
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        index - The index to set the value at.
        value - The principals to set.
        Returns:
        This builder for chaining.
      • addPrincipals

        public AuthorizationPolicy.Rule.Source.Builder addPrincipals​(String value)
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The principals to add.
        Returns:
        This builder for chaining.
      • addAllPrincipals

        public AuthorizationPolicy.Rule.Source.Builder addAllPrincipals​(Iterable<String> values)
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        values - The principals to add.
        Returns:
        This builder for chaining.
      • clearPrincipals

        public AuthorizationPolicy.Rule.Source.Builder clearPrincipals()
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Returns:
        This builder for chaining.
      • addPrincipalsBytes

        public AuthorizationPolicy.Rule.Source.Builder addPrincipalsBytes​(com.google.protobuf.ByteString value)
         Optional. List of peer identities to match for authorization. At least one
         principal should match. Each peer can be an exact match, or a prefix
         match (example, "namespace/*") or a suffix match (example,
         "*/service-account") or a presence match "*". Authorization based on
         the principal name without certificate validation (configured by
         ServerTlsPolicy resource) is considered insecure.
         
        repeated string principals = 1 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The bytes of the principals to add.
        Returns:
        This builder for chaining.
      • getIpBlocksList

        public com.google.protobuf.ProtocolStringList getIpBlocksList()
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getIpBlocksList in interface AuthorizationPolicy.Rule.SourceOrBuilder
        Returns:
        A list containing the ipBlocks.
      • getIpBlocksCount

        public int getIpBlocksCount()
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getIpBlocksCount in interface AuthorizationPolicy.Rule.SourceOrBuilder
        Returns:
        The count of ipBlocks.
      • getIpBlocks

        public String getIpBlocks​(int index)
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getIpBlocks in interface AuthorizationPolicy.Rule.SourceOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The ipBlocks at the given index.
      • getIpBlocksBytes

        public com.google.protobuf.ByteString getIpBlocksBytes​(int index)
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getIpBlocksBytes in interface AuthorizationPolicy.Rule.SourceOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the ipBlocks at the given index.
      • setIpBlocks

        public AuthorizationPolicy.Rule.Source.Builder setIpBlocks​(int index,
                                                                   String value)
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        index - The index to set the value at.
        value - The ipBlocks to set.
        Returns:
        This builder for chaining.
      • addIpBlocks

        public AuthorizationPolicy.Rule.Source.Builder addIpBlocks​(String value)
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The ipBlocks to add.
        Returns:
        This builder for chaining.
      • addAllIpBlocks

        public AuthorizationPolicy.Rule.Source.Builder addAllIpBlocks​(Iterable<String> values)
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        values - The ipBlocks to add.
        Returns:
        This builder for chaining.
      • clearIpBlocks

        public AuthorizationPolicy.Rule.Source.Builder clearIpBlocks()
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Returns:
        This builder for chaining.
      • addIpBlocksBytes

        public AuthorizationPolicy.Rule.Source.Builder addIpBlocksBytes​(com.google.protobuf.ByteString value)
         Optional. List of CIDR ranges to match based on source IP address. At least one
         IP block should match. Single IP (e.g., "1.2.3.4") and CIDR (e.g.,
         "1.2.3.0/24") are supported. Authorization based on source IP alone
         should be avoided. The IP addresses of any load balancers or proxies
         should be considered untrusted.
         
        repeated string ip_blocks = 2 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The bytes of the ipBlocks to add.
        Returns:
        This builder for chaining.