io.envoyproxy.envoy.config.route.v3.RateLimit Maven / Gradle / Ivy
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: envoy/config/route/v3/route_components.proto
// Protobuf Java Version: 3.25.5
package io.envoyproxy.envoy.config.route.v3;
/**
*
* Global rate limiting :ref:`architecture overview <arch_overview_global_rate_limit>`.
* Also applies to Local rate limiting :ref:`using descriptors <config_http_filters_local_rate_limit_descriptors>`.
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit}
*/
public final class RateLimit extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit)
RateLimitOrBuilder {
private static final long serialVersionUID = 0L;
// Use RateLimit.newBuilder() to construct.
private RateLimit(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RateLimit() {
disableKey_ = "";
actions_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RateLimit();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Builder.class);
}
public interface ActionOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action)
com.google.protobuf.MessageOrBuilder {
/**
*
* Rate limit on source cluster.
*
*
* .envoy.config.route.v3.RateLimit.Action.SourceCluster source_cluster = 1;
* @return Whether the sourceCluster field is set.
*/
boolean hasSourceCluster();
/**
*
* Rate limit on source cluster.
*
*
* .envoy.config.route.v3.RateLimit.Action.SourceCluster source_cluster = 1;
* @return The sourceCluster.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster getSourceCluster();
/**
*
* Rate limit on source cluster.
*
*
* .envoy.config.route.v3.RateLimit.Action.SourceCluster source_cluster = 1;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceClusterOrBuilder getSourceClusterOrBuilder();
/**
*
* Rate limit on destination cluster.
*
*
* .envoy.config.route.v3.RateLimit.Action.DestinationCluster destination_cluster = 2;
* @return Whether the destinationCluster field is set.
*/
boolean hasDestinationCluster();
/**
*
* Rate limit on destination cluster.
*
*
* .envoy.config.route.v3.RateLimit.Action.DestinationCluster destination_cluster = 2;
* @return The destinationCluster.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster getDestinationCluster();
/**
*
* Rate limit on destination cluster.
*
*
* .envoy.config.route.v3.RateLimit.Action.DestinationCluster destination_cluster = 2;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationClusterOrBuilder getDestinationClusterOrBuilder();
/**
*
* Rate limit on request headers.
*
*
* .envoy.config.route.v3.RateLimit.Action.RequestHeaders request_headers = 3;
* @return Whether the requestHeaders field is set.
*/
boolean hasRequestHeaders();
/**
*
* Rate limit on request headers.
*
*
* .envoy.config.route.v3.RateLimit.Action.RequestHeaders request_headers = 3;
* @return The requestHeaders.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders getRequestHeaders();
/**
*
* Rate limit on request headers.
*
*
* .envoy.config.route.v3.RateLimit.Action.RequestHeaders request_headers = 3;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeadersOrBuilder getRequestHeadersOrBuilder();
/**
*
* Rate limit on remote address.
*
*
* .envoy.config.route.v3.RateLimit.Action.RemoteAddress remote_address = 4;
* @return Whether the remoteAddress field is set.
*/
boolean hasRemoteAddress();
/**
*
* Rate limit on remote address.
*
*
* .envoy.config.route.v3.RateLimit.Action.RemoteAddress remote_address = 4;
* @return The remoteAddress.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress getRemoteAddress();
/**
*
* Rate limit on remote address.
*
*
* .envoy.config.route.v3.RateLimit.Action.RemoteAddress remote_address = 4;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddressOrBuilder getRemoteAddressOrBuilder();
/**
*
* Rate limit on a generic key.
*
*
* .envoy.config.route.v3.RateLimit.Action.GenericKey generic_key = 5;
* @return Whether the genericKey field is set.
*/
boolean hasGenericKey();
/**
*
* Rate limit on a generic key.
*
*
* .envoy.config.route.v3.RateLimit.Action.GenericKey generic_key = 5;
* @return The genericKey.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey getGenericKey();
/**
*
* Rate limit on a generic key.
*
*
* .envoy.config.route.v3.RateLimit.Action.GenericKey generic_key = 5;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKeyOrBuilder getGenericKeyOrBuilder();
/**
*
* Rate limit on the existence of request headers.
*
*
* .envoy.config.route.v3.RateLimit.Action.HeaderValueMatch header_value_match = 6;
* @return Whether the headerValueMatch field is set.
*/
boolean hasHeaderValueMatch();
/**
*
* Rate limit on the existence of request headers.
*
*
* .envoy.config.route.v3.RateLimit.Action.HeaderValueMatch header_value_match = 6;
* @return The headerValueMatch.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch getHeaderValueMatch();
/**
*
* Rate limit on the existence of request headers.
*
*
* .envoy.config.route.v3.RateLimit.Action.HeaderValueMatch header_value_match = 6;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatchOrBuilder getHeaderValueMatchOrBuilder();
/**
*
* Rate limit on dynamic metadata.
*
* .. attention::
* This field has been deprecated in favor of the :ref:`metadata <envoy_v3_api_field_config.route.v3.RateLimit.Action.metadata>` field
*
*
* .envoy.config.route.v3.RateLimit.Action.DynamicMetaData dynamic_metadata = 7 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0", (.envoy.annotations.disallowed_by_default) = true];
* @deprecated envoy.config.route.v3.RateLimit.Action.dynamic_metadata is deprecated.
* See envoy/config/route/v3/route_components.proto;l=2125
* @return Whether the dynamicMetadata field is set.
*/
@java.lang.Deprecated boolean hasDynamicMetadata();
/**
*
* Rate limit on dynamic metadata.
*
* .. attention::
* This field has been deprecated in favor of the :ref:`metadata <envoy_v3_api_field_config.route.v3.RateLimit.Action.metadata>` field
*
*
* .envoy.config.route.v3.RateLimit.Action.DynamicMetaData dynamic_metadata = 7 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0", (.envoy.annotations.disallowed_by_default) = true];
* @deprecated envoy.config.route.v3.RateLimit.Action.dynamic_metadata is deprecated.
* See envoy/config/route/v3/route_components.proto;l=2125
* @return The dynamicMetadata.
*/
@java.lang.Deprecated io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData getDynamicMetadata();
/**
*
* Rate limit on dynamic metadata.
*
* .. attention::
* This field has been deprecated in favor of the :ref:`metadata <envoy_v3_api_field_config.route.v3.RateLimit.Action.metadata>` field
*
*
* .envoy.config.route.v3.RateLimit.Action.DynamicMetaData dynamic_metadata = 7 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0", (.envoy.annotations.disallowed_by_default) = true];
*/
@java.lang.Deprecated io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaDataOrBuilder getDynamicMetadataOrBuilder();
/**
*
* Rate limit on metadata.
*
*
* .envoy.config.route.v3.RateLimit.Action.MetaData metadata = 8;
* @return Whether the metadata field is set.
*/
boolean hasMetadata();
/**
*
* Rate limit on metadata.
*
*
* .envoy.config.route.v3.RateLimit.Action.MetaData metadata = 8;
* @return The metadata.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MetaData getMetadata();
/**
*
* Rate limit on metadata.
*
*
* .envoy.config.route.v3.RateLimit.Action.MetaData metadata = 8;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MetaDataOrBuilder getMetadataOrBuilder();
/**
*
* Rate limit descriptor extension. See the rate limit descriptor extensions documentation.
*
* :ref:`HTTP matching input functions <arch_overview_matching_api>` are
* permitted as descriptor extensions. The input functions are only
* looked up if there is no rate limit descriptor extension matching
* the type URL.
*
* [#extension-category: envoy.rate_limit_descriptors]
*
*
* .envoy.config.core.v3.TypedExtensionConfig extension = 9;
* @return Whether the extension field is set.
*/
boolean hasExtension();
/**
*
* Rate limit descriptor extension. See the rate limit descriptor extensions documentation.
*
* :ref:`HTTP matching input functions <arch_overview_matching_api>` are
* permitted as descriptor extensions. The input functions are only
* looked up if there is no rate limit descriptor extension matching
* the type URL.
*
* [#extension-category: envoy.rate_limit_descriptors]
*
*
* .envoy.config.core.v3.TypedExtensionConfig extension = 9;
* @return The extension.
*/
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig getExtension();
/**
*
* Rate limit descriptor extension. See the rate limit descriptor extensions documentation.
*
* :ref:`HTTP matching input functions <arch_overview_matching_api>` are
* permitted as descriptor extensions. The input functions are only
* looked up if there is no rate limit descriptor extension matching
* the type URL.
*
* [#extension-category: envoy.rate_limit_descriptors]
*
*
* .envoy.config.core.v3.TypedExtensionConfig extension = 9;
*/
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfigOrBuilder getExtensionOrBuilder();
/**
*
* Rate limit on masked remote address.
*
*
* .envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress masked_remote_address = 10;
* @return Whether the maskedRemoteAddress field is set.
*/
boolean hasMaskedRemoteAddress();
/**
*
* Rate limit on masked remote address.
*
*
* .envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress masked_remote_address = 10;
* @return The maskedRemoteAddress.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress getMaskedRemoteAddress();
/**
*
* Rate limit on masked remote address.
*
*
* .envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress masked_remote_address = 10;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddressOrBuilder getMaskedRemoteAddressOrBuilder();
/**
*
* Rate limit on the existence of query parameters.
*
*
* .envoy.config.route.v3.RateLimit.Action.QueryParameterValueMatch query_parameter_value_match = 11;
* @return Whether the queryParameterValueMatch field is set.
*/
boolean hasQueryParameterValueMatch();
/**
*
* Rate limit on the existence of query parameters.
*
*
* .envoy.config.route.v3.RateLimit.Action.QueryParameterValueMatch query_parameter_value_match = 11;
* @return The queryParameterValueMatch.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.QueryParameterValueMatch getQueryParameterValueMatch();
/**
*
* Rate limit on the existence of query parameters.
*
*
* .envoy.config.route.v3.RateLimit.Action.QueryParameterValueMatch query_parameter_value_match = 11;
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.QueryParameterValueMatchOrBuilder getQueryParameterValueMatchOrBuilder();
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.ActionSpecifierCase getActionSpecifierCase();
}
/**
*
* [#next-free-field: 12]
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action}
*/
public static final class Action extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action)
ActionOrBuilder {
private static final long serialVersionUID = 0L;
// Use Action.newBuilder() to construct.
private Action(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Action() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new Action();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.Builder.class);
}
public interface SourceClusterOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.SourceCluster)
com.google.protobuf.MessageOrBuilder {
}
/**
*
* The following descriptor entry is appended to the descriptor:
*
* .. code-block:: cpp
*
* ("source_cluster", "<local service cluster>")
*
* <local service cluster> is derived from the :option:`--service-cluster` option.
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.SourceCluster}
*/
public static final class SourceCluster extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.SourceCluster)
SourceClusterOrBuilder {
private static final long serialVersionUID = 0L;
// Use SourceCluster.newBuilder() to construct.
private SourceCluster(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private SourceCluster() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new SourceCluster();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_SourceCluster_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_SourceCluster_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster.Builder.class);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster other = (io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster) obj;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* The following descriptor entry is appended to the descriptor:
*
* .. code-block:: cpp
*
* ("source_cluster", "<local service cluster>")
*
* <local service cluster> is derived from the :option:`--service-cluster` option.
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.SourceCluster}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RateLimit.Action.SourceCluster)
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceClusterOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_SourceCluster_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_SourceCluster_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_SourceCluster_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster build() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster buildPartial() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster result = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster(this);
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster other) {
if (other == io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster.getDefaultInstance()) return this;
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RateLimit.Action.SourceCluster)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RateLimit.Action.SourceCluster)
private static final io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster();
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public SourceCluster parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.SourceCluster getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface DestinationClusterOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.DestinationCluster)
com.google.protobuf.MessageOrBuilder {
}
/**
*
* The following descriptor entry is appended to the descriptor:
*
* .. code-block:: cpp
*
* ("destination_cluster", "<routed target cluster>")
*
* Once a request matches against a route table rule, a routed cluster is determined by one of
* the following :ref:`route table configuration <envoy_v3_api_msg_config.route.v3.RouteConfiguration>`
* settings:
*
* * :ref:`cluster <envoy_v3_api_field_config.route.v3.RouteAction.cluster>` indicates the upstream cluster
* to route to.
* * :ref:`weighted_clusters <envoy_v3_api_field_config.route.v3.RouteAction.weighted_clusters>`
* chooses a cluster randomly from a set of clusters with attributed weight.
* * :ref:`cluster_header <envoy_v3_api_field_config.route.v3.RouteAction.cluster_header>` indicates which
* header in the request contains the target cluster.
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.DestinationCluster}
*/
public static final class DestinationCluster extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.DestinationCluster)
DestinationClusterOrBuilder {
private static final long serialVersionUID = 0L;
// Use DestinationCluster.newBuilder() to construct.
private DestinationCluster(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private DestinationCluster() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new DestinationCluster();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DestinationCluster_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DestinationCluster_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster.Builder.class);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster other = (io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster) obj;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* The following descriptor entry is appended to the descriptor:
*
* .. code-block:: cpp
*
* ("destination_cluster", "<routed target cluster>")
*
* Once a request matches against a route table rule, a routed cluster is determined by one of
* the following :ref:`route table configuration <envoy_v3_api_msg_config.route.v3.RouteConfiguration>`
* settings:
*
* * :ref:`cluster <envoy_v3_api_field_config.route.v3.RouteAction.cluster>` indicates the upstream cluster
* to route to.
* * :ref:`weighted_clusters <envoy_v3_api_field_config.route.v3.RouteAction.weighted_clusters>`
* chooses a cluster randomly from a set of clusters with attributed weight.
* * :ref:`cluster_header <envoy_v3_api_field_config.route.v3.RouteAction.cluster_header>` indicates which
* header in the request contains the target cluster.
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.DestinationCluster}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RateLimit.Action.DestinationCluster)
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationClusterOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DestinationCluster_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DestinationCluster_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DestinationCluster_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster build() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster buildPartial() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster result = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster(this);
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster other) {
if (other == io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster.getDefaultInstance()) return this;
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RateLimit.Action.DestinationCluster)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RateLimit.Action.DestinationCluster)
private static final io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster();
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public DestinationCluster parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DestinationCluster getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface RequestHeadersOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.RequestHeaders)
com.google.protobuf.MessageOrBuilder {
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @return The headerName.
*/
java.lang.String getHeaderName();
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @return The bytes for headerName.
*/
com.google.protobuf.ByteString
getHeaderNameBytes();
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @return The descriptorKey.
*/
java.lang.String getDescriptorKey();
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @return The bytes for descriptorKey.
*/
com.google.protobuf.ByteString
getDescriptorKeyBytes();
/**
*
* If set to true, Envoy skips the descriptor while calling rate limiting service
* when header is not present in the request. By default it skips calling the
* rate limiting service if this header is not present in the request.
*
*
* bool skip_if_absent = 3;
* @return The skipIfAbsent.
*/
boolean getSkipIfAbsent();
}
/**
*
* The following descriptor entry is appended when a header contains a key that matches the
* ``header_name``:
*
* .. code-block:: cpp
*
* ("<descriptor_key>", "<header_value_queried_from_header>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.RequestHeaders}
*/
public static final class RequestHeaders extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.RequestHeaders)
RequestHeadersOrBuilder {
private static final long serialVersionUID = 0L;
// Use RequestHeaders.newBuilder() to construct.
private RequestHeaders(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RequestHeaders() {
headerName_ = "";
descriptorKey_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RequestHeaders();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RequestHeaders_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RequestHeaders_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders.Builder.class);
}
public static final int HEADER_NAME_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object headerName_ = "";
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @return The headerName.
*/
@java.lang.Override
public java.lang.String getHeaderName() {
java.lang.Object ref = headerName_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
headerName_ = s;
return s;
}
}
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @return The bytes for headerName.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getHeaderNameBytes() {
java.lang.Object ref = headerName_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
headerName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int DESCRIPTOR_KEY_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object descriptorKey_ = "";
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @return The descriptorKey.
*/
@java.lang.Override
public java.lang.String getDescriptorKey() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorKey_ = s;
return s;
}
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @return The bytes for descriptorKey.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDescriptorKeyBytes() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorKey_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int SKIP_IF_ABSENT_FIELD_NUMBER = 3;
private boolean skipIfAbsent_ = false;
/**
*
* If set to true, Envoy skips the descriptor while calling rate limiting service
* when header is not present in the request. By default it skips calling the
* rate limiting service if this header is not present in the request.
*
*
* bool skip_if_absent = 3;
* @return The skipIfAbsent.
*/
@java.lang.Override
public boolean getSkipIfAbsent() {
return skipIfAbsent_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(headerName_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, headerName_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorKey_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, descriptorKey_);
}
if (skipIfAbsent_ != false) {
output.writeBool(3, skipIfAbsent_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(headerName_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, headerName_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorKey_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, descriptorKey_);
}
if (skipIfAbsent_ != false) {
size += com.google.protobuf.CodedOutputStream
.computeBoolSize(3, skipIfAbsent_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders other = (io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders) obj;
if (!getHeaderName()
.equals(other.getHeaderName())) return false;
if (!getDescriptorKey()
.equals(other.getDescriptorKey())) return false;
if (getSkipIfAbsent()
!= other.getSkipIfAbsent()) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + HEADER_NAME_FIELD_NUMBER;
hash = (53 * hash) + getHeaderName().hashCode();
hash = (37 * hash) + DESCRIPTOR_KEY_FIELD_NUMBER;
hash = (53 * hash) + getDescriptorKey().hashCode();
hash = (37 * hash) + SKIP_IF_ABSENT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getSkipIfAbsent());
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* The following descriptor entry is appended when a header contains a key that matches the
* ``header_name``:
*
* .. code-block:: cpp
*
* ("<descriptor_key>", "<header_value_queried_from_header>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.RequestHeaders}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RateLimit.Action.RequestHeaders)
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeadersOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RequestHeaders_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RequestHeaders_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
headerName_ = "";
descriptorKey_ = "";
skipIfAbsent_ = false;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RequestHeaders_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders build() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders buildPartial() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders result = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.headerName_ = headerName_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.descriptorKey_ = descriptorKey_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.skipIfAbsent_ = skipIfAbsent_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders other) {
if (other == io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders.getDefaultInstance()) return this;
if (!other.getHeaderName().isEmpty()) {
headerName_ = other.headerName_;
bitField0_ |= 0x00000001;
onChanged();
}
if (!other.getDescriptorKey().isEmpty()) {
descriptorKey_ = other.descriptorKey_;
bitField0_ |= 0x00000002;
onChanged();
}
if (other.getSkipIfAbsent() != false) {
setSkipIfAbsent(other.getSkipIfAbsent());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
headerName_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
descriptorKey_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 24: {
skipIfAbsent_ = input.readBool();
bitField0_ |= 0x00000004;
break;
} // case 24
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object headerName_ = "";
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @return The headerName.
*/
public java.lang.String getHeaderName() {
java.lang.Object ref = headerName_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
headerName_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @return The bytes for headerName.
*/
public com.google.protobuf.ByteString
getHeaderNameBytes() {
java.lang.Object ref = headerName_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
headerName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @param value The headerName to set.
* @return This builder for chaining.
*/
public Builder setHeaderName(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
headerName_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearHeaderName() {
headerName_ = getDefaultInstance().getHeaderName();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* The header name to be queried from the request headers. The header’s
* value is used to populate the value of the descriptor entry for the
* descriptor_key.
*
*
* string header_name = 1 [(.validate.rules) = { ... }
* @param value The bytes for headerName to set.
* @return This builder for chaining.
*/
public Builder setHeaderNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
headerName_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private java.lang.Object descriptorKey_ = "";
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @return The descriptorKey.
*/
public java.lang.String getDescriptorKey() {
java.lang.Object ref = descriptorKey_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorKey_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @return The bytes for descriptorKey.
*/
public com.google.protobuf.ByteString
getDescriptorKeyBytes() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorKey_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @param value The descriptorKey to set.
* @return This builder for chaining.
*/
public Builder setDescriptorKey(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
descriptorKey_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearDescriptorKey() {
descriptorKey_ = getDefaultInstance().getDescriptorKey();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 2 [(.validate.rules) = { ... }
* @param value The bytes for descriptorKey to set.
* @return This builder for chaining.
*/
public Builder setDescriptorKeyBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
descriptorKey_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private boolean skipIfAbsent_ ;
/**
*
* If set to true, Envoy skips the descriptor while calling rate limiting service
* when header is not present in the request. By default it skips calling the
* rate limiting service if this header is not present in the request.
*
*
* bool skip_if_absent = 3;
* @return The skipIfAbsent.
*/
@java.lang.Override
public boolean getSkipIfAbsent() {
return skipIfAbsent_;
}
/**
*
* If set to true, Envoy skips the descriptor while calling rate limiting service
* when header is not present in the request. By default it skips calling the
* rate limiting service if this header is not present in the request.
*
*
* bool skip_if_absent = 3;
* @param value The skipIfAbsent to set.
* @return This builder for chaining.
*/
public Builder setSkipIfAbsent(boolean value) {
skipIfAbsent_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* If set to true, Envoy skips the descriptor while calling rate limiting service
* when header is not present in the request. By default it skips calling the
* rate limiting service if this header is not present in the request.
*
*
* bool skip_if_absent = 3;
* @return This builder for chaining.
*/
public Builder clearSkipIfAbsent() {
bitField0_ = (bitField0_ & ~0x00000004);
skipIfAbsent_ = false;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RateLimit.Action.RequestHeaders)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RateLimit.Action.RequestHeaders)
private static final io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders();
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RequestHeaders parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RequestHeaders getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface RemoteAddressOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.RemoteAddress)
com.google.protobuf.MessageOrBuilder {
}
/**
*
* The following descriptor entry is appended to the descriptor and is populated using the
* trusted address from :ref:`x-forwarded-for <config_http_conn_man_headers_x-forwarded-for>`:
*
* .. code-block:: cpp
*
* ("remote_address", "<trusted address from x-forwarded-for>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.RemoteAddress}
*/
public static final class RemoteAddress extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.RemoteAddress)
RemoteAddressOrBuilder {
private static final long serialVersionUID = 0L;
// Use RemoteAddress.newBuilder() to construct.
private RemoteAddress(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RemoteAddress() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RemoteAddress();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RemoteAddress_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RemoteAddress_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress.Builder.class);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress other = (io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress) obj;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* The following descriptor entry is appended to the descriptor and is populated using the
* trusted address from :ref:`x-forwarded-for <config_http_conn_man_headers_x-forwarded-for>`:
*
* .. code-block:: cpp
*
* ("remote_address", "<trusted address from x-forwarded-for>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.RemoteAddress}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RateLimit.Action.RemoteAddress)
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddressOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RemoteAddress_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RemoteAddress_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_RemoteAddress_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress build() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress buildPartial() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress result = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress(this);
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress other) {
if (other == io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress.getDefaultInstance()) return this;
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RateLimit.Action.RemoteAddress)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RateLimit.Action.RemoteAddress)
private static final io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress();
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RemoteAddress parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.RemoteAddress getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface MaskedRemoteAddressOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress)
com.google.protobuf.MessageOrBuilder {
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
* @return Whether the v4PrefixMaskLen field is set.
*/
boolean hasV4PrefixMaskLen();
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
* @return The v4PrefixMaskLen.
*/
com.google.protobuf.UInt32Value getV4PrefixMaskLen();
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
com.google.protobuf.UInt32ValueOrBuilder getV4PrefixMaskLenOrBuilder();
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
* @return Whether the v6PrefixMaskLen field is set.
*/
boolean hasV6PrefixMaskLen();
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
* @return The v6PrefixMaskLen.
*/
com.google.protobuf.UInt32Value getV6PrefixMaskLen();
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
com.google.protobuf.UInt32ValueOrBuilder getV6PrefixMaskLenOrBuilder();
}
/**
*
* The following descriptor entry is appended to the descriptor and is populated using the
* masked address from :ref:`x-forwarded-for <config_http_conn_man_headers_x-forwarded-for>`:
*
* .. code-block:: cpp
*
* ("masked_remote_address", "<masked address from x-forwarded-for>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress}
*/
public static final class MaskedRemoteAddress extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress)
MaskedRemoteAddressOrBuilder {
private static final long serialVersionUID = 0L;
// Use MaskedRemoteAddress.newBuilder() to construct.
private MaskedRemoteAddress(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private MaskedRemoteAddress() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new MaskedRemoteAddress();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_MaskedRemoteAddress_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_MaskedRemoteAddress_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress.Builder.class);
}
private int bitField0_;
public static final int V4_PREFIX_MASK_LEN_FIELD_NUMBER = 1;
private com.google.protobuf.UInt32Value v4PrefixMaskLen_;
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
* @return Whether the v4PrefixMaskLen field is set.
*/
@java.lang.Override
public boolean hasV4PrefixMaskLen() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
* @return The v4PrefixMaskLen.
*/
@java.lang.Override
public com.google.protobuf.UInt32Value getV4PrefixMaskLen() {
return v4PrefixMaskLen_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : v4PrefixMaskLen_;
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
@java.lang.Override
public com.google.protobuf.UInt32ValueOrBuilder getV4PrefixMaskLenOrBuilder() {
return v4PrefixMaskLen_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : v4PrefixMaskLen_;
}
public static final int V6_PREFIX_MASK_LEN_FIELD_NUMBER = 2;
private com.google.protobuf.UInt32Value v6PrefixMaskLen_;
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
* @return Whether the v6PrefixMaskLen field is set.
*/
@java.lang.Override
public boolean hasV6PrefixMaskLen() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
* @return The v6PrefixMaskLen.
*/
@java.lang.Override
public com.google.protobuf.UInt32Value getV6PrefixMaskLen() {
return v6PrefixMaskLen_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : v6PrefixMaskLen_;
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
@java.lang.Override
public com.google.protobuf.UInt32ValueOrBuilder getV6PrefixMaskLenOrBuilder() {
return v6PrefixMaskLen_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : v6PrefixMaskLen_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(1, getV4PrefixMaskLen());
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(2, getV6PrefixMaskLen());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getV4PrefixMaskLen());
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getV6PrefixMaskLen());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress other = (io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress) obj;
if (hasV4PrefixMaskLen() != other.hasV4PrefixMaskLen()) return false;
if (hasV4PrefixMaskLen()) {
if (!getV4PrefixMaskLen()
.equals(other.getV4PrefixMaskLen())) return false;
}
if (hasV6PrefixMaskLen() != other.hasV6PrefixMaskLen()) return false;
if (hasV6PrefixMaskLen()) {
if (!getV6PrefixMaskLen()
.equals(other.getV6PrefixMaskLen())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasV4PrefixMaskLen()) {
hash = (37 * hash) + V4_PREFIX_MASK_LEN_FIELD_NUMBER;
hash = (53 * hash) + getV4PrefixMaskLen().hashCode();
}
if (hasV6PrefixMaskLen()) {
hash = (37 * hash) + V6_PREFIX_MASK_LEN_FIELD_NUMBER;
hash = (53 * hash) + getV6PrefixMaskLen().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* The following descriptor entry is appended to the descriptor and is populated using the
* masked address from :ref:`x-forwarded-for <config_http_conn_man_headers_x-forwarded-for>`:
*
* .. code-block:: cpp
*
* ("masked_remote_address", "<masked address from x-forwarded-for>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress)
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddressOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_MaskedRemoteAddress_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_MaskedRemoteAddress_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getV4PrefixMaskLenFieldBuilder();
getV6PrefixMaskLenFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
v4PrefixMaskLen_ = null;
if (v4PrefixMaskLenBuilder_ != null) {
v4PrefixMaskLenBuilder_.dispose();
v4PrefixMaskLenBuilder_ = null;
}
v6PrefixMaskLen_ = null;
if (v6PrefixMaskLenBuilder_ != null) {
v6PrefixMaskLenBuilder_.dispose();
v6PrefixMaskLenBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_MaskedRemoteAddress_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress build() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress buildPartial() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress result = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.v4PrefixMaskLen_ = v4PrefixMaskLenBuilder_ == null
? v4PrefixMaskLen_
: v4PrefixMaskLenBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.v6PrefixMaskLen_ = v6PrefixMaskLenBuilder_ == null
? v6PrefixMaskLen_
: v6PrefixMaskLenBuilder_.build();
to_bitField0_ |= 0x00000002;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress other) {
if (other == io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress.getDefaultInstance()) return this;
if (other.hasV4PrefixMaskLen()) {
mergeV4PrefixMaskLen(other.getV4PrefixMaskLen());
}
if (other.hasV6PrefixMaskLen()) {
mergeV6PrefixMaskLen(other.getV6PrefixMaskLen());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
input.readMessage(
getV4PrefixMaskLenFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
input.readMessage(
getV6PrefixMaskLenFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private com.google.protobuf.UInt32Value v4PrefixMaskLen_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> v4PrefixMaskLenBuilder_;
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
* @return Whether the v4PrefixMaskLen field is set.
*/
public boolean hasV4PrefixMaskLen() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
* @return The v4PrefixMaskLen.
*/
public com.google.protobuf.UInt32Value getV4PrefixMaskLen() {
if (v4PrefixMaskLenBuilder_ == null) {
return v4PrefixMaskLen_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : v4PrefixMaskLen_;
} else {
return v4PrefixMaskLenBuilder_.getMessage();
}
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
public Builder setV4PrefixMaskLen(com.google.protobuf.UInt32Value value) {
if (v4PrefixMaskLenBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
v4PrefixMaskLen_ = value;
} else {
v4PrefixMaskLenBuilder_.setMessage(value);
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
public Builder setV4PrefixMaskLen(
com.google.protobuf.UInt32Value.Builder builderForValue) {
if (v4PrefixMaskLenBuilder_ == null) {
v4PrefixMaskLen_ = builderForValue.build();
} else {
v4PrefixMaskLenBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
public Builder mergeV4PrefixMaskLen(com.google.protobuf.UInt32Value value) {
if (v4PrefixMaskLenBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0) &&
v4PrefixMaskLen_ != null &&
v4PrefixMaskLen_ != com.google.protobuf.UInt32Value.getDefaultInstance()) {
getV4PrefixMaskLenBuilder().mergeFrom(value);
} else {
v4PrefixMaskLen_ = value;
}
} else {
v4PrefixMaskLenBuilder_.mergeFrom(value);
}
if (v4PrefixMaskLen_ != null) {
bitField0_ |= 0x00000001;
onChanged();
}
return this;
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
public Builder clearV4PrefixMaskLen() {
bitField0_ = (bitField0_ & ~0x00000001);
v4PrefixMaskLen_ = null;
if (v4PrefixMaskLenBuilder_ != null) {
v4PrefixMaskLenBuilder_.dispose();
v4PrefixMaskLenBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
public com.google.protobuf.UInt32Value.Builder getV4PrefixMaskLenBuilder() {
bitField0_ |= 0x00000001;
onChanged();
return getV4PrefixMaskLenFieldBuilder().getBuilder();
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
public com.google.protobuf.UInt32ValueOrBuilder getV4PrefixMaskLenOrBuilder() {
if (v4PrefixMaskLenBuilder_ != null) {
return v4PrefixMaskLenBuilder_.getMessageOrBuilder();
} else {
return v4PrefixMaskLen_ == null ?
com.google.protobuf.UInt32Value.getDefaultInstance() : v4PrefixMaskLen_;
}
}
/**
*
* Length of prefix mask len for IPv4 (e.g. 0, 32).
* Defaults to 32 when unset.
* For example, trusted address from x-forwarded-for is ``192.168.1.1``,
* the descriptor entry is ("masked_remote_address", "192.168.1.1/32");
* if mask len is 24, the descriptor entry is ("masked_remote_address", "192.168.1.0/24").
*
*
* .google.protobuf.UInt32Value v4_prefix_mask_len = 1 [(.validate.rules) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>
getV4PrefixMaskLenFieldBuilder() {
if (v4PrefixMaskLenBuilder_ == null) {
v4PrefixMaskLenBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>(
getV4PrefixMaskLen(),
getParentForChildren(),
isClean());
v4PrefixMaskLen_ = null;
}
return v4PrefixMaskLenBuilder_;
}
private com.google.protobuf.UInt32Value v6PrefixMaskLen_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> v6PrefixMaskLenBuilder_;
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
* @return Whether the v6PrefixMaskLen field is set.
*/
public boolean hasV6PrefixMaskLen() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
* @return The v6PrefixMaskLen.
*/
public com.google.protobuf.UInt32Value getV6PrefixMaskLen() {
if (v6PrefixMaskLenBuilder_ == null) {
return v6PrefixMaskLen_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : v6PrefixMaskLen_;
} else {
return v6PrefixMaskLenBuilder_.getMessage();
}
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
public Builder setV6PrefixMaskLen(com.google.protobuf.UInt32Value value) {
if (v6PrefixMaskLenBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
v6PrefixMaskLen_ = value;
} else {
v6PrefixMaskLenBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
public Builder setV6PrefixMaskLen(
com.google.protobuf.UInt32Value.Builder builderForValue) {
if (v6PrefixMaskLenBuilder_ == null) {
v6PrefixMaskLen_ = builderForValue.build();
} else {
v6PrefixMaskLenBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
public Builder mergeV6PrefixMaskLen(com.google.protobuf.UInt32Value value) {
if (v6PrefixMaskLenBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
v6PrefixMaskLen_ != null &&
v6PrefixMaskLen_ != com.google.protobuf.UInt32Value.getDefaultInstance()) {
getV6PrefixMaskLenBuilder().mergeFrom(value);
} else {
v6PrefixMaskLen_ = value;
}
} else {
v6PrefixMaskLenBuilder_.mergeFrom(value);
}
if (v6PrefixMaskLen_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
public Builder clearV6PrefixMaskLen() {
bitField0_ = (bitField0_ & ~0x00000002);
v6PrefixMaskLen_ = null;
if (v6PrefixMaskLenBuilder_ != null) {
v6PrefixMaskLenBuilder_.dispose();
v6PrefixMaskLenBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
public com.google.protobuf.UInt32Value.Builder getV6PrefixMaskLenBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getV6PrefixMaskLenFieldBuilder().getBuilder();
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
public com.google.protobuf.UInt32ValueOrBuilder getV6PrefixMaskLenOrBuilder() {
if (v6PrefixMaskLenBuilder_ != null) {
return v6PrefixMaskLenBuilder_.getMessageOrBuilder();
} else {
return v6PrefixMaskLen_ == null ?
com.google.protobuf.UInt32Value.getDefaultInstance() : v6PrefixMaskLen_;
}
}
/**
*
* Length of prefix mask len for IPv6 (e.g. 0, 128).
* Defaults to 128 when unset.
* For example, trusted address from x-forwarded-for is ``2001:abcd:ef01:2345:6789:abcd:ef01:234``,
* the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345:6789:abcd:ef01:234/128");
* if mask len is 64, the descriptor entry is ("masked_remote_address", "2001:abcd:ef01:2345::/64").
*
*
* .google.protobuf.UInt32Value v6_prefix_mask_len = 2 [(.validate.rules) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>
getV6PrefixMaskLenFieldBuilder() {
if (v6PrefixMaskLenBuilder_ == null) {
v6PrefixMaskLenBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>(
getV6PrefixMaskLen(),
getParentForChildren(),
isClean());
v6PrefixMaskLen_ = null;
}
return v6PrefixMaskLenBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress)
private static final io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress();
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public MaskedRemoteAddress parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MaskedRemoteAddress getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface GenericKeyOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.GenericKey)
com.google.protobuf.MessageOrBuilder {
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The descriptorValue.
*/
java.lang.String getDescriptorValue();
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorValue.
*/
com.google.protobuf.ByteString
getDescriptorValueBytes();
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @return The descriptorKey.
*/
java.lang.String getDescriptorKey();
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @return The bytes for descriptorKey.
*/
com.google.protobuf.ByteString
getDescriptorKeyBytes();
}
/**
*
* The following descriptor entry is appended to the descriptor:
*
* .. code-block:: cpp
*
* ("generic_key", "<descriptor_value>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.GenericKey}
*/
public static final class GenericKey extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.GenericKey)
GenericKeyOrBuilder {
private static final long serialVersionUID = 0L;
// Use GenericKey.newBuilder() to construct.
private GenericKey(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private GenericKey() {
descriptorValue_ = "";
descriptorKey_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new GenericKey();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_GenericKey_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_GenericKey_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey.Builder.class);
}
public static final int DESCRIPTOR_VALUE_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object descriptorValue_ = "";
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The descriptorValue.
*/
@java.lang.Override
public java.lang.String getDescriptorValue() {
java.lang.Object ref = descriptorValue_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorValue_ = s;
return s;
}
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorValue.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDescriptorValueBytes() {
java.lang.Object ref = descriptorValue_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorValue_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int DESCRIPTOR_KEY_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object descriptorKey_ = "";
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @return The descriptorKey.
*/
@java.lang.Override
public java.lang.String getDescriptorKey() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorKey_ = s;
return s;
}
}
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @return The bytes for descriptorKey.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDescriptorKeyBytes() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorKey_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorValue_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, descriptorValue_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorKey_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, descriptorKey_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorValue_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, descriptorValue_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorKey_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, descriptorKey_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey other = (io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey) obj;
if (!getDescriptorValue()
.equals(other.getDescriptorValue())) return false;
if (!getDescriptorKey()
.equals(other.getDescriptorKey())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + DESCRIPTOR_VALUE_FIELD_NUMBER;
hash = (53 * hash) + getDescriptorValue().hashCode();
hash = (37 * hash) + DESCRIPTOR_KEY_FIELD_NUMBER;
hash = (53 * hash) + getDescriptorKey().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* The following descriptor entry is appended to the descriptor:
*
* .. code-block:: cpp
*
* ("generic_key", "<descriptor_value>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.GenericKey}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RateLimit.Action.GenericKey)
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKeyOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_GenericKey_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_GenericKey_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
descriptorValue_ = "";
descriptorKey_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_GenericKey_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey build() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey buildPartial() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey result = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.descriptorValue_ = descriptorValue_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.descriptorKey_ = descriptorKey_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey other) {
if (other == io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey.getDefaultInstance()) return this;
if (!other.getDescriptorValue().isEmpty()) {
descriptorValue_ = other.descriptorValue_;
bitField0_ |= 0x00000001;
onChanged();
}
if (!other.getDescriptorKey().isEmpty()) {
descriptorKey_ = other.descriptorKey_;
bitField0_ |= 0x00000002;
onChanged();
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
descriptorValue_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
descriptorKey_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object descriptorValue_ = "";
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The descriptorValue.
*/
public java.lang.String getDescriptorValue() {
java.lang.Object ref = descriptorValue_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorValue_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorValue.
*/
public com.google.protobuf.ByteString
getDescriptorValueBytes() {
java.lang.Object ref = descriptorValue_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorValue_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @param value The descriptorValue to set.
* @return This builder for chaining.
*/
public Builder setDescriptorValue(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
descriptorValue_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearDescriptorValue() {
descriptorValue_ = getDefaultInstance().getDescriptorValue();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @param value The bytes for descriptorValue to set.
* @return This builder for chaining.
*/
public Builder setDescriptorValueBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
descriptorValue_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private java.lang.Object descriptorKey_ = "";
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @return The descriptorKey.
*/
public java.lang.String getDescriptorKey() {
java.lang.Object ref = descriptorKey_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorKey_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @return The bytes for descriptorKey.
*/
public com.google.protobuf.ByteString
getDescriptorKeyBytes() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorKey_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @param value The descriptorKey to set.
* @return This builder for chaining.
*/
public Builder setDescriptorKey(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
descriptorKey_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @return This builder for chaining.
*/
public Builder clearDescriptorKey() {
descriptorKey_ = getDefaultInstance().getDescriptorKey();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* An optional key to use in the descriptor entry. If not set it defaults
* to 'generic_key' as the descriptor key.
*
*
* string descriptor_key = 2;
* @param value The bytes for descriptorKey to set.
* @return This builder for chaining.
*/
public Builder setDescriptorKeyBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
descriptorKey_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RateLimit.Action.GenericKey)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RateLimit.Action.GenericKey)
private static final io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey();
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public GenericKey parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.GenericKey getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface HeaderValueMatchOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.HeaderValueMatch)
com.google.protobuf.MessageOrBuilder {
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @return The descriptorKey.
*/
java.lang.String getDescriptorKey();
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @return The bytes for descriptorKey.
*/
com.google.protobuf.ByteString
getDescriptorKeyBytes();
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The descriptorValue.
*/
java.lang.String getDescriptorValue();
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorValue.
*/
com.google.protobuf.ByteString
getDescriptorValueBytes();
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
* @return Whether the expectMatch field is set.
*/
boolean hasExpectMatch();
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
* @return The expectMatch.
*/
com.google.protobuf.BoolValue getExpectMatch();
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
com.google.protobuf.BoolValueOrBuilder getExpectMatchOrBuilder();
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
java.util.List
getHeadersList();
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
io.envoyproxy.envoy.config.route.v3.HeaderMatcher getHeaders(int index);
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
int getHeadersCount();
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
java.util.List extends io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getHeadersOrBuilderList();
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder getHeadersOrBuilder(
int index);
}
/**
*
* The following descriptor entry is appended to the descriptor:
*
* .. code-block:: cpp
*
* ("header_match", "<descriptor_value>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.HeaderValueMatch}
*/
public static final class HeaderValueMatch extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.HeaderValueMatch)
HeaderValueMatchOrBuilder {
private static final long serialVersionUID = 0L;
// Use HeaderValueMatch.newBuilder() to construct.
private HeaderValueMatch(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private HeaderValueMatch() {
descriptorKey_ = "";
descriptorValue_ = "";
headers_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new HeaderValueMatch();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch.Builder.class);
}
private int bitField0_;
public static final int DESCRIPTOR_KEY_FIELD_NUMBER = 4;
@SuppressWarnings("serial")
private volatile java.lang.Object descriptorKey_ = "";
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @return The descriptorKey.
*/
@java.lang.Override
public java.lang.String getDescriptorKey() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorKey_ = s;
return s;
}
}
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @return The bytes for descriptorKey.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDescriptorKeyBytes() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorKey_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int DESCRIPTOR_VALUE_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object descriptorValue_ = "";
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The descriptorValue.
*/
@java.lang.Override
public java.lang.String getDescriptorValue() {
java.lang.Object ref = descriptorValue_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorValue_ = s;
return s;
}
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorValue.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDescriptorValueBytes() {
java.lang.Object ref = descriptorValue_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorValue_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int EXPECT_MATCH_FIELD_NUMBER = 2;
private com.google.protobuf.BoolValue expectMatch_;
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
* @return Whether the expectMatch field is set.
*/
@java.lang.Override
public boolean hasExpectMatch() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
* @return The expectMatch.
*/
@java.lang.Override
public com.google.protobuf.BoolValue getExpectMatch() {
return expectMatch_ == null ? com.google.protobuf.BoolValue.getDefaultInstance() : expectMatch_;
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
@java.lang.Override
public com.google.protobuf.BoolValueOrBuilder getExpectMatchOrBuilder() {
return expectMatch_ == null ? com.google.protobuf.BoolValue.getDefaultInstance() : expectMatch_;
}
public static final int HEADERS_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private java.util.List headers_;
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
@java.lang.Override
public java.util.List getHeadersList() {
return headers_;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
@java.lang.Override
public java.util.List extends io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getHeadersOrBuilderList() {
return headers_;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
@java.lang.Override
public int getHeadersCount() {
return headers_.size();
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher getHeaders(int index) {
return headers_.get(index);
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder getHeadersOrBuilder(
int index) {
return headers_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorValue_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, descriptorValue_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(2, getExpectMatch());
}
for (int i = 0; i < headers_.size(); i++) {
output.writeMessage(3, headers_.get(i));
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorKey_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 4, descriptorKey_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorValue_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, descriptorValue_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getExpectMatch());
}
for (int i = 0; i < headers_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, headers_.get(i));
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorKey_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, descriptorKey_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch other = (io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch) obj;
if (!getDescriptorKey()
.equals(other.getDescriptorKey())) return false;
if (!getDescriptorValue()
.equals(other.getDescriptorValue())) return false;
if (hasExpectMatch() != other.hasExpectMatch()) return false;
if (hasExpectMatch()) {
if (!getExpectMatch()
.equals(other.getExpectMatch())) return false;
}
if (!getHeadersList()
.equals(other.getHeadersList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + DESCRIPTOR_KEY_FIELD_NUMBER;
hash = (53 * hash) + getDescriptorKey().hashCode();
hash = (37 * hash) + DESCRIPTOR_VALUE_FIELD_NUMBER;
hash = (53 * hash) + getDescriptorValue().hashCode();
if (hasExpectMatch()) {
hash = (37 * hash) + EXPECT_MATCH_FIELD_NUMBER;
hash = (53 * hash) + getExpectMatch().hashCode();
}
if (getHeadersCount() > 0) {
hash = (37 * hash) + HEADERS_FIELD_NUMBER;
hash = (53 * hash) + getHeadersList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* The following descriptor entry is appended to the descriptor:
*
* .. code-block:: cpp
*
* ("header_match", "<descriptor_value>")
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.HeaderValueMatch}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RateLimit.Action.HeaderValueMatch)
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatchOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getExpectMatchFieldBuilder();
getHeadersFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
descriptorKey_ = "";
descriptorValue_ = "";
expectMatch_ = null;
if (expectMatchBuilder_ != null) {
expectMatchBuilder_.dispose();
expectMatchBuilder_ = null;
}
if (headersBuilder_ == null) {
headers_ = java.util.Collections.emptyList();
} else {
headers_ = null;
headersBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000008);
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_HeaderValueMatch_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch build() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch buildPartial() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch result = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch result) {
if (headersBuilder_ == null) {
if (((bitField0_ & 0x00000008) != 0)) {
headers_ = java.util.Collections.unmodifiableList(headers_);
bitField0_ = (bitField0_ & ~0x00000008);
}
result.headers_ = headers_;
} else {
result.headers_ = headersBuilder_.build();
}
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.descriptorKey_ = descriptorKey_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.descriptorValue_ = descriptorValue_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000004) != 0)) {
result.expectMatch_ = expectMatchBuilder_ == null
? expectMatch_
: expectMatchBuilder_.build();
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch other) {
if (other == io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch.getDefaultInstance()) return this;
if (!other.getDescriptorKey().isEmpty()) {
descriptorKey_ = other.descriptorKey_;
bitField0_ |= 0x00000001;
onChanged();
}
if (!other.getDescriptorValue().isEmpty()) {
descriptorValue_ = other.descriptorValue_;
bitField0_ |= 0x00000002;
onChanged();
}
if (other.hasExpectMatch()) {
mergeExpectMatch(other.getExpectMatch());
}
if (headersBuilder_ == null) {
if (!other.headers_.isEmpty()) {
if (headers_.isEmpty()) {
headers_ = other.headers_;
bitField0_ = (bitField0_ & ~0x00000008);
} else {
ensureHeadersIsMutable();
headers_.addAll(other.headers_);
}
onChanged();
}
} else {
if (!other.headers_.isEmpty()) {
if (headersBuilder_.isEmpty()) {
headersBuilder_.dispose();
headersBuilder_ = null;
headers_ = other.headers_;
bitField0_ = (bitField0_ & ~0x00000008);
headersBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getHeadersFieldBuilder() : null;
} else {
headersBuilder_.addAllMessages(other.headers_);
}
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
descriptorValue_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 10
case 18: {
input.readMessage(
getExpectMatchFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 18
case 26: {
io.envoyproxy.envoy.config.route.v3.HeaderMatcher m =
input.readMessage(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.parser(),
extensionRegistry);
if (headersBuilder_ == null) {
ensureHeadersIsMutable();
headers_.add(m);
} else {
headersBuilder_.addMessage(m);
}
break;
} // case 26
case 34: {
descriptorKey_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 34
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object descriptorKey_ = "";
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @return The descriptorKey.
*/
public java.lang.String getDescriptorKey() {
java.lang.Object ref = descriptorKey_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorKey_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @return The bytes for descriptorKey.
*/
public com.google.protobuf.ByteString
getDescriptorKeyBytes() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorKey_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @param value The descriptorKey to set.
* @return This builder for chaining.
*/
public Builder setDescriptorKey(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
descriptorKey_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @return This builder for chaining.
*/
public Builder clearDescriptorKey() {
descriptorKey_ = getDefaultInstance().getDescriptorKey();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* The key to use in the descriptor entry. Defaults to ``header_match``.
*
*
* string descriptor_key = 4;
* @param value The bytes for descriptorKey to set.
* @return This builder for chaining.
*/
public Builder setDescriptorKeyBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
descriptorKey_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private java.lang.Object descriptorValue_ = "";
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The descriptorValue.
*/
public java.lang.String getDescriptorValue() {
java.lang.Object ref = descriptorValue_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorValue_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorValue.
*/
public com.google.protobuf.ByteString
getDescriptorValueBytes() {
java.lang.Object ref = descriptorValue_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorValue_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @param value The descriptorValue to set.
* @return This builder for chaining.
*/
public Builder setDescriptorValue(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
descriptorValue_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearDescriptorValue() {
descriptorValue_ = getDefaultInstance().getDescriptorValue();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* The value to use in the descriptor entry.
*
*
* string descriptor_value = 1 [(.validate.rules) = { ... }
* @param value The bytes for descriptorValue to set.
* @return This builder for chaining.
*/
public Builder setDescriptorValueBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
descriptorValue_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private com.google.protobuf.BoolValue expectMatch_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.BoolValue, com.google.protobuf.BoolValue.Builder, com.google.protobuf.BoolValueOrBuilder> expectMatchBuilder_;
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
* @return Whether the expectMatch field is set.
*/
public boolean hasExpectMatch() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
* @return The expectMatch.
*/
public com.google.protobuf.BoolValue getExpectMatch() {
if (expectMatchBuilder_ == null) {
return expectMatch_ == null ? com.google.protobuf.BoolValue.getDefaultInstance() : expectMatch_;
} else {
return expectMatchBuilder_.getMessage();
}
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
public Builder setExpectMatch(com.google.protobuf.BoolValue value) {
if (expectMatchBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
expectMatch_ = value;
} else {
expectMatchBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
public Builder setExpectMatch(
com.google.protobuf.BoolValue.Builder builderForValue) {
if (expectMatchBuilder_ == null) {
expectMatch_ = builderForValue.build();
} else {
expectMatchBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
public Builder mergeExpectMatch(com.google.protobuf.BoolValue value) {
if (expectMatchBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
expectMatch_ != null &&
expectMatch_ != com.google.protobuf.BoolValue.getDefaultInstance()) {
getExpectMatchBuilder().mergeFrom(value);
} else {
expectMatch_ = value;
}
} else {
expectMatchBuilder_.mergeFrom(value);
}
if (expectMatch_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
public Builder clearExpectMatch() {
bitField0_ = (bitField0_ & ~0x00000004);
expectMatch_ = null;
if (expectMatchBuilder_ != null) {
expectMatchBuilder_.dispose();
expectMatchBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
public com.google.protobuf.BoolValue.Builder getExpectMatchBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getExpectMatchFieldBuilder().getBuilder();
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
public com.google.protobuf.BoolValueOrBuilder getExpectMatchOrBuilder() {
if (expectMatchBuilder_ != null) {
return expectMatchBuilder_.getMessageOrBuilder();
} else {
return expectMatch_ == null ?
com.google.protobuf.BoolValue.getDefaultInstance() : expectMatch_;
}
}
/**
*
* If set to true, the action will append a descriptor entry when the
* request matches the headers. If set to false, the action will append a
* descriptor entry when the request does not match the headers. The
* default value is true.
*
*
* .google.protobuf.BoolValue expect_match = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.BoolValue, com.google.protobuf.BoolValue.Builder, com.google.protobuf.BoolValueOrBuilder>
getExpectMatchFieldBuilder() {
if (expectMatchBuilder_ == null) {
expectMatchBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.BoolValue, com.google.protobuf.BoolValue.Builder, com.google.protobuf.BoolValueOrBuilder>(
getExpectMatch(),
getParentForChildren(),
isClean());
expectMatch_ = null;
}
return expectMatchBuilder_;
}
private java.util.List headers_ =
java.util.Collections.emptyList();
private void ensureHeadersIsMutable() {
if (!((bitField0_ & 0x00000008) != 0)) {
headers_ = new java.util.ArrayList(headers_);
bitField0_ |= 0x00000008;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder> headersBuilder_;
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public java.util.List getHeadersList() {
if (headersBuilder_ == null) {
return java.util.Collections.unmodifiableList(headers_);
} else {
return headersBuilder_.getMessageList();
}
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public int getHeadersCount() {
if (headersBuilder_ == null) {
return headers_.size();
} else {
return headersBuilder_.getCount();
}
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher getHeaders(int index) {
if (headersBuilder_ == null) {
return headers_.get(index);
} else {
return headersBuilder_.getMessage(index);
}
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder setHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (headersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureHeadersIsMutable();
headers_.set(index, value);
onChanged();
} else {
headersBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder setHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (headersBuilder_ == null) {
ensureHeadersIsMutable();
headers_.set(index, builderForValue.build());
onChanged();
} else {
headersBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder addHeaders(io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (headersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureHeadersIsMutable();
headers_.add(value);
onChanged();
} else {
headersBuilder_.addMessage(value);
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder addHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (headersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureHeadersIsMutable();
headers_.add(index, value);
onChanged();
} else {
headersBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder addHeaders(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (headersBuilder_ == null) {
ensureHeadersIsMutable();
headers_.add(builderForValue.build());
onChanged();
} else {
headersBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder addHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (headersBuilder_ == null) {
ensureHeadersIsMutable();
headers_.add(index, builderForValue.build());
onChanged();
} else {
headersBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder addAllHeaders(
java.lang.Iterable extends io.envoyproxy.envoy.config.route.v3.HeaderMatcher> values) {
if (headersBuilder_ == null) {
ensureHeadersIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, headers_);
onChanged();
} else {
headersBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder clearHeaders() {
if (headersBuilder_ == null) {
headers_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000008);
onChanged();
} else {
headersBuilder_.clear();
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public Builder removeHeaders(int index) {
if (headersBuilder_ == null) {
ensureHeadersIsMutable();
headers_.remove(index);
onChanged();
} else {
headersBuilder_.remove(index);
}
return this;
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder getHeadersBuilder(
int index) {
return getHeadersFieldBuilder().getBuilder(index);
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder getHeadersOrBuilder(
int index) {
if (headersBuilder_ == null) {
return headers_.get(index); } else {
return headersBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public java.util.List extends io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getHeadersOrBuilderList() {
if (headersBuilder_ != null) {
return headersBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(headers_);
}
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder addHeadersBuilder() {
return getHeadersFieldBuilder().addBuilder(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.getDefaultInstance());
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder addHeadersBuilder(
int index) {
return getHeadersFieldBuilder().addBuilder(
index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.getDefaultInstance());
}
/**
*
* Specifies a set of headers that the rate limit action should match
* on. The action will check the request’s headers against all the
* specified headers in the config. A match will happen if all the
* headers in the config are present in the request with the same values
* (or based on presence if the value field is not in the config).
*
*
* repeated .envoy.config.route.v3.HeaderMatcher headers = 3 [(.validate.rules) = { ... }
*/
public java.util.List
getHeadersBuilderList() {
return getHeadersFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getHeadersFieldBuilder() {
if (headersBuilder_ == null) {
headersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>(
headers_,
((bitField0_ & 0x00000008) != 0),
getParentForChildren(),
isClean());
headers_ = null;
}
return headersBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RateLimit.Action.HeaderValueMatch)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RateLimit.Action.HeaderValueMatch)
private static final io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch();
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public HeaderValueMatch parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.HeaderValueMatch getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface DynamicMetaDataOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.DynamicMetaData)
com.google.protobuf.MessageOrBuilder {
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return The descriptorKey.
*/
java.lang.String getDescriptorKey();
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorKey.
*/
com.google.protobuf.ByteString
getDescriptorKeyBytes();
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
* @return Whether the metadataKey field is set.
*/
boolean hasMetadataKey();
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
* @return The metadataKey.
*/
io.envoyproxy.envoy.type.metadata.v3.MetadataKey getMetadataKey();
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
io.envoyproxy.envoy.type.metadata.v3.MetadataKeyOrBuilder getMetadataKeyOrBuilder();
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @return The defaultValue.
*/
java.lang.String getDefaultValue();
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @return The bytes for defaultValue.
*/
com.google.protobuf.ByteString
getDefaultValueBytes();
}
/**
*
* The following descriptor entry is appended when the
* :ref:`dynamic metadata <well_known_dynamic_metadata>` contains a key value:
*
* .. code-block:: cpp
*
* ("<descriptor_key>", "<value_queried_from_dynamic_metadata>")
*
* .. attention::
* This action has been deprecated in favor of the :ref:`metadata <envoy_v3_api_msg_config.route.v3.RateLimit.Action.MetaData>` action
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.DynamicMetaData}
*/
public static final class DynamicMetaData extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.DynamicMetaData)
DynamicMetaDataOrBuilder {
private static final long serialVersionUID = 0L;
// Use DynamicMetaData.newBuilder() to construct.
private DynamicMetaData(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private DynamicMetaData() {
descriptorKey_ = "";
defaultValue_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new DynamicMetaData();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DynamicMetaData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DynamicMetaData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData.Builder.class);
}
private int bitField0_;
public static final int DESCRIPTOR_KEY_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object descriptorKey_ = "";
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return The descriptorKey.
*/
@java.lang.Override
public java.lang.String getDescriptorKey() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorKey_ = s;
return s;
}
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorKey.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDescriptorKeyBytes() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorKey_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int METADATA_KEY_FIELD_NUMBER = 2;
private io.envoyproxy.envoy.type.metadata.v3.MetadataKey metadataKey_;
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
* @return Whether the metadataKey field is set.
*/
@java.lang.Override
public boolean hasMetadataKey() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
* @return The metadataKey.
*/
@java.lang.Override
public io.envoyproxy.envoy.type.metadata.v3.MetadataKey getMetadataKey() {
return metadataKey_ == null ? io.envoyproxy.envoy.type.metadata.v3.MetadataKey.getDefaultInstance() : metadataKey_;
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
@java.lang.Override
public io.envoyproxy.envoy.type.metadata.v3.MetadataKeyOrBuilder getMetadataKeyOrBuilder() {
return metadataKey_ == null ? io.envoyproxy.envoy.type.metadata.v3.MetadataKey.getDefaultInstance() : metadataKey_;
}
public static final int DEFAULT_VALUE_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private volatile java.lang.Object defaultValue_ = "";
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @return The defaultValue.
*/
@java.lang.Override
public java.lang.String getDefaultValue() {
java.lang.Object ref = defaultValue_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
defaultValue_ = s;
return s;
}
}
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @return The bytes for defaultValue.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDefaultValueBytes() {
java.lang.Object ref = defaultValue_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
defaultValue_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorKey_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, descriptorKey_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(2, getMetadataKey());
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(defaultValue_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, defaultValue_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(descriptorKey_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, descriptorKey_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getMetadataKey());
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(defaultValue_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, defaultValue_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData other = (io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData) obj;
if (!getDescriptorKey()
.equals(other.getDescriptorKey())) return false;
if (hasMetadataKey() != other.hasMetadataKey()) return false;
if (hasMetadataKey()) {
if (!getMetadataKey()
.equals(other.getMetadataKey())) return false;
}
if (!getDefaultValue()
.equals(other.getDefaultValue())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + DESCRIPTOR_KEY_FIELD_NUMBER;
hash = (53 * hash) + getDescriptorKey().hashCode();
if (hasMetadataKey()) {
hash = (37 * hash) + METADATA_KEY_FIELD_NUMBER;
hash = (53 * hash) + getMetadataKey().hashCode();
}
hash = (37 * hash) + DEFAULT_VALUE_FIELD_NUMBER;
hash = (53 * hash) + getDefaultValue().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* The following descriptor entry is appended when the
* :ref:`dynamic metadata <well_known_dynamic_metadata>` contains a key value:
*
* .. code-block:: cpp
*
* ("<descriptor_key>", "<value_queried_from_dynamic_metadata>")
*
* .. attention::
* This action has been deprecated in favor of the :ref:`metadata <envoy_v3_api_msg_config.route.v3.RateLimit.Action.MetaData>` action
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.DynamicMetaData}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RateLimit.Action.DynamicMetaData)
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaDataOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DynamicMetaData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DynamicMetaData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getMetadataKeyFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
descriptorKey_ = "";
metadataKey_ = null;
if (metadataKeyBuilder_ != null) {
metadataKeyBuilder_.dispose();
metadataKeyBuilder_ = null;
}
defaultValue_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_DynamicMetaData_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData build() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData buildPartial() {
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData result = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.descriptorKey_ = descriptorKey_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.metadataKey_ = metadataKeyBuilder_ == null
? metadataKey_
: metadataKeyBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.defaultValue_ = defaultValue_;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData other) {
if (other == io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData.getDefaultInstance()) return this;
if (!other.getDescriptorKey().isEmpty()) {
descriptorKey_ = other.descriptorKey_;
bitField0_ |= 0x00000001;
onChanged();
}
if (other.hasMetadataKey()) {
mergeMetadataKey(other.getMetadataKey());
}
if (!other.getDefaultValue().isEmpty()) {
defaultValue_ = other.defaultValue_;
bitField0_ |= 0x00000004;
onChanged();
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
descriptorKey_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
input.readMessage(
getMetadataKeyFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
defaultValue_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000004;
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object descriptorKey_ = "";
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return The descriptorKey.
*/
public java.lang.String getDescriptorKey() {
java.lang.Object ref = descriptorKey_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
descriptorKey_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorKey.
*/
public com.google.protobuf.ByteString
getDescriptorKeyBytes() {
java.lang.Object ref = descriptorKey_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
descriptorKey_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @param value The descriptorKey to set.
* @return This builder for chaining.
*/
public Builder setDescriptorKey(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
descriptorKey_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearDescriptorKey() {
descriptorKey_ = getDefaultInstance().getDescriptorKey();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @param value The bytes for descriptorKey to set.
* @return This builder for chaining.
*/
public Builder setDescriptorKeyBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
descriptorKey_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private io.envoyproxy.envoy.type.metadata.v3.MetadataKey metadataKey_;
private com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.type.metadata.v3.MetadataKey, io.envoyproxy.envoy.type.metadata.v3.MetadataKey.Builder, io.envoyproxy.envoy.type.metadata.v3.MetadataKeyOrBuilder> metadataKeyBuilder_;
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
* @return Whether the metadataKey field is set.
*/
public boolean hasMetadataKey() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
* @return The metadataKey.
*/
public io.envoyproxy.envoy.type.metadata.v3.MetadataKey getMetadataKey() {
if (metadataKeyBuilder_ == null) {
return metadataKey_ == null ? io.envoyproxy.envoy.type.metadata.v3.MetadataKey.getDefaultInstance() : metadataKey_;
} else {
return metadataKeyBuilder_.getMessage();
}
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
public Builder setMetadataKey(io.envoyproxy.envoy.type.metadata.v3.MetadataKey value) {
if (metadataKeyBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
metadataKey_ = value;
} else {
metadataKeyBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
public Builder setMetadataKey(
io.envoyproxy.envoy.type.metadata.v3.MetadataKey.Builder builderForValue) {
if (metadataKeyBuilder_ == null) {
metadataKey_ = builderForValue.build();
} else {
metadataKeyBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
public Builder mergeMetadataKey(io.envoyproxy.envoy.type.metadata.v3.MetadataKey value) {
if (metadataKeyBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
metadataKey_ != null &&
metadataKey_ != io.envoyproxy.envoy.type.metadata.v3.MetadataKey.getDefaultInstance()) {
getMetadataKeyBuilder().mergeFrom(value);
} else {
metadataKey_ = value;
}
} else {
metadataKeyBuilder_.mergeFrom(value);
}
if (metadataKey_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
public Builder clearMetadataKey() {
bitField0_ = (bitField0_ & ~0x00000002);
metadataKey_ = null;
if (metadataKeyBuilder_ != null) {
metadataKeyBuilder_.dispose();
metadataKeyBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.type.metadata.v3.MetadataKey.Builder getMetadataKeyBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getMetadataKeyFieldBuilder().getBuilder();
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.type.metadata.v3.MetadataKeyOrBuilder getMetadataKeyOrBuilder() {
if (metadataKeyBuilder_ != null) {
return metadataKeyBuilder_.getMessageOrBuilder();
} else {
return metadataKey_ == null ?
io.envoyproxy.envoy.type.metadata.v3.MetadataKey.getDefaultInstance() : metadataKey_;
}
}
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the dynamic metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.type.metadata.v3.MetadataKey, io.envoyproxy.envoy.type.metadata.v3.MetadataKey.Builder, io.envoyproxy.envoy.type.metadata.v3.MetadataKeyOrBuilder>
getMetadataKeyFieldBuilder() {
if (metadataKeyBuilder_ == null) {
metadataKeyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.type.metadata.v3.MetadataKey, io.envoyproxy.envoy.type.metadata.v3.MetadataKey.Builder, io.envoyproxy.envoy.type.metadata.v3.MetadataKeyOrBuilder>(
getMetadataKey(),
getParentForChildren(),
isClean());
metadataKey_ = null;
}
return metadataKeyBuilder_;
}
private java.lang.Object defaultValue_ = "";
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @return The defaultValue.
*/
public java.lang.String getDefaultValue() {
java.lang.Object ref = defaultValue_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
defaultValue_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @return The bytes for defaultValue.
*/
public com.google.protobuf.ByteString
getDefaultValueBytes() {
java.lang.Object ref = defaultValue_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
defaultValue_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @param value The defaultValue to set.
* @return This builder for chaining.
*/
public Builder setDefaultValue(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
defaultValue_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @return This builder for chaining.
*/
public Builder clearDefaultValue() {
defaultValue_ = getDefaultInstance().getDefaultValue();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged();
return this;
}
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then no descriptor is generated.
*
*
* string default_value = 3;
* @param value The bytes for defaultValue to set.
* @return This builder for chaining.
*/
public Builder setDefaultValueBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
defaultValue_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RateLimit.Action.DynamicMetaData)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RateLimit.Action.DynamicMetaData)
private static final io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData();
}
public static io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public DynamicMetaData parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RateLimit.Action.DynamicMetaData getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface MetaDataOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RateLimit.Action.MetaData)
com.google.protobuf.MessageOrBuilder {
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return The descriptorKey.
*/
java.lang.String getDescriptorKey();
/**
*
* The key to use in the descriptor entry.
*
*
* string descriptor_key = 1 [(.validate.rules) = { ... }
* @return The bytes for descriptorKey.
*/
com.google.protobuf.ByteString
getDescriptorKeyBytes();
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
* @return Whether the metadataKey field is set.
*/
boolean hasMetadataKey();
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
* @return The metadataKey.
*/
io.envoyproxy.envoy.type.metadata.v3.MetadataKey getMetadataKey();
/**
*
* Metadata struct that defines the key and path to retrieve the string value. A match will
* only happen if the value in the metadata is of type string.
*
*
* .envoy.type.metadata.v3.MetadataKey metadata_key = 2 [(.validate.rules) = { ... }
*/
io.envoyproxy.envoy.type.metadata.v3.MetadataKeyOrBuilder getMetadataKeyOrBuilder();
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then ``skip_if_absent`` is followed to
* skip calling the rate limiting service or skip the descriptor.
*
*
* string default_value = 3;
* @return The defaultValue.
*/
java.lang.String getDefaultValue();
/**
*
* An optional value to use if ``metadata_key`` is empty. If not set and
* no value is present under the metadata_key then ``skip_if_absent`` is followed to
* skip calling the rate limiting service or skip the descriptor.
*
*
* string default_value = 3;
* @return The bytes for defaultValue.
*/
com.google.protobuf.ByteString
getDefaultValueBytes();
/**
*
* Source of metadata
*
*
* .envoy.config.route.v3.RateLimit.Action.MetaData.Source source = 4 [(.validate.rules) = { ... }
* @return The enum numeric value on the wire for source.
*/
int getSourceValue();
/**
*
* Source of metadata
*
*
* .envoy.config.route.v3.RateLimit.Action.MetaData.Source source = 4 [(.validate.rules) = { ... }
* @return The source.
*/
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MetaData.Source getSource();
/**
*
* If set to true, Envoy skips the descriptor while calling rate limiting service
* when ``metadata_key`` is empty and ``default_value`` is not set. By default it skips calling the
* rate limiting service in that case.
*
*
* bool skip_if_absent = 5;
* @return The skipIfAbsent.
*/
boolean getSkipIfAbsent();
}
/**
*
* The following descriptor entry is appended when the metadata contains a key value:
*
* .. code-block:: cpp
*
* ("<descriptor_key>", "<value_queried_from_metadata>")
* [#next-free-field: 6]
*
*
* Protobuf type {@code envoy.config.route.v3.RateLimit.Action.MetaData}
*/
public static final class MetaData extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RateLimit.Action.MetaData)
MetaDataOrBuilder {
private static final long serialVersionUID = 0L;
// Use MetaData.newBuilder() to construct.
private MetaData(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private MetaData() {
descriptorKey_ = "";
defaultValue_ = "";
source_ = 0;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new MetaData();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_MetaData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RateLimit_Action_MetaData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MetaData.class, io.envoyproxy.envoy.config.route.v3.RateLimit.Action.MetaData.Builder.class);
}
/**
* Protobuf enum {@code envoy.config.route.v3.RateLimit.Action.MetaData.Source}
*/
public enum Source
implements com.google.protobuf.ProtocolMessageEnum {
/**
*
* Query :ref:`dynamic metadata <well_known_dynamic_metadata>`
*
*
* DYNAMIC = 0;
*/
DYNAMIC(0),
/**
*
* Query :ref:`route entry metadata <envoy_v3_api_field_config.route.v3.Route.metadata>`
*
*
* ROUTE_ENTRY = 1;
*/
ROUTE_ENTRY(1),
UNRECOGNIZED(-1),
;
/**
*
* Query :ref:`dynamic metadata <well_known_dynamic_metadata>`
*
*
* DYNAMIC = 0;
*/
public static final int DYNAMIC_VALUE = 0;
/**
*
* Query :ref:`route entry metadata <envoy_v3_api_field_config.route.v3.Route.metadata>`
*
*
* ROUTE_ENTRY = 1;
*/
public static final int ROUTE_ENTRY_VALUE = 1;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static Source valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static Source forNumber(int value) {
switch (value) {
case 0: return DYNAMIC;
case 1: return ROUTE_ENTRY;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
© 2015 - 2025 Weber Informatics LLC | Privacy Policy