All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation Maven / Gradle / Ivy

There is a newer version: 1.0.46
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: envoy/config/common/mutation_rules/v3/mutation_rules.proto

package io.envoyproxy.envoy.config.common.mutation_rules.v3;

/**
 * 
 * The HeaderMutation structure specifies an action that may be taken on HTTP
 * headers.
 * 
* * Protobuf type {@code envoy.config.common.mutation_rules.v3.HeaderMutation} */ public final class HeaderMutation extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:envoy.config.common.mutation_rules.v3.HeaderMutation) HeaderMutationOrBuilder { private static final long serialVersionUID = 0L; // Use HeaderMutation.newBuilder() to construct. private HeaderMutation(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private HeaderMutation() { } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new HeaderMutation(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private HeaderMutation( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { java.lang.String s = input.readStringRequireUtf8(); actionCase_ = 1; action_ = s; break; } case 18: { io.envoyproxy.envoy.config.core.v3.HeaderValueOption.Builder subBuilder = null; if (actionCase_ == 2) { subBuilder = ((io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_).toBuilder(); } action_ = input.readMessage(io.envoyproxy.envoy.config.core.v3.HeaderValueOption.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom((io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_); action_ = subBuilder.buildPartial(); } actionCase_ = 2; break; } default: { if (!parseUnknownField( input, unknownFields, extensionRegistry, tag)) { done = true; } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.envoyproxy.envoy.config.common.mutation_rules.v3.MutationRulesProto.internal_static_envoy_config_common_mutation_rules_v3_HeaderMutation_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.envoyproxy.envoy.config.common.mutation_rules.v3.MutationRulesProto.internal_static_envoy_config_common_mutation_rules_v3_HeaderMutation_fieldAccessorTable .ensureFieldAccessorsInitialized( io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation.class, io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation.Builder.class); } private int actionCase_ = 0; private java.lang.Object action_; public enum ActionCase implements com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { REMOVE(1), APPEND(2), ACTION_NOT_SET(0); private final int value; private ActionCase(int value) { this.value = value; } /** * @param value The number of the enum to look for. * @return The enum associated with the given number. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static ActionCase valueOf(int value) { return forNumber(value); } public static ActionCase forNumber(int value) { switch (value) { case 1: return REMOVE; case 2: return APPEND; case 0: return ACTION_NOT_SET; default: return null; } } public int getNumber() { return this.value; } }; public ActionCase getActionCase() { return ActionCase.forNumber( actionCase_); } public static final int REMOVE_FIELD_NUMBER = 1; /** *
   * Remove the specified header if it exists.
   * 
* * string remove = 1 [(.validate.rules) = { ... } * @return Whether the remove field is set. */ public boolean hasRemove() { return actionCase_ == 1; } /** *
   * Remove the specified header if it exists.
   * 
* * string remove = 1 [(.validate.rules) = { ... } * @return The remove. */ public java.lang.String getRemove() { java.lang.Object ref = ""; if (actionCase_ == 1) { ref = action_; } 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(); if (actionCase_ == 1) { action_ = s; } return s; } } /** *
   * Remove the specified header if it exists.
   * 
* * string remove = 1 [(.validate.rules) = { ... } * @return The bytes for remove. */ public com.google.protobuf.ByteString getRemoveBytes() { java.lang.Object ref = ""; if (actionCase_ == 1) { ref = action_; } if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); if (actionCase_ == 1) { action_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int APPEND_FIELD_NUMBER = 2; /** *
   * Append new header by the specified HeaderValueOption.
   * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; * @return Whether the append field is set. */ @java.lang.Override public boolean hasAppend() { return actionCase_ == 2; } /** *
   * Append new header by the specified HeaderValueOption.
   * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; * @return The append. */ @java.lang.Override public io.envoyproxy.envoy.config.core.v3.HeaderValueOption getAppend() { if (actionCase_ == 2) { return (io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_; } return io.envoyproxy.envoy.config.core.v3.HeaderValueOption.getDefaultInstance(); } /** *
   * Append new header by the specified HeaderValueOption.
   * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; */ @java.lang.Override public io.envoyproxy.envoy.config.core.v3.HeaderValueOptionOrBuilder getAppendOrBuilder() { if (actionCase_ == 2) { return (io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_; } return io.envoyproxy.envoy.config.core.v3.HeaderValueOption.getDefaultInstance(); } 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 (actionCase_ == 1) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, action_); } if (actionCase_ == 2) { output.writeMessage(2, (io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (actionCase_ == 1) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, action_); } if (actionCase_ == 2) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, (io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_); } size += unknownFields.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.common.mutation_rules.v3.HeaderMutation)) { return super.equals(obj); } io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation other = (io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation) obj; if (!getActionCase().equals(other.getActionCase())) return false; switch (actionCase_) { case 1: if (!getRemove() .equals(other.getRemove())) return false; break; case 2: if (!getAppend() .equals(other.getAppend())) return false; break; case 0: default: } if (!unknownFields.equals(other.unknownFields)) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); switch (actionCase_) { case 1: hash = (37 * hash) + REMOVE_FIELD_NUMBER; hash = (53 * hash) + getRemove().hashCode(); break; case 2: hash = (37 * hash) + APPEND_FIELD_NUMBER; hash = (53 * hash) + getAppend().hashCode(); break; case 0: default: } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation 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.common.mutation_rules.v3.HeaderMutation parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation 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.common.mutation_rules.v3.HeaderMutation parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation 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.common.mutation_rules.v3.HeaderMutation parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation 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.common.mutation_rules.v3.HeaderMutation parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation 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.common.mutation_rules.v3.HeaderMutation 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 HeaderMutation structure specifies an action that may be taken on HTTP
   * headers.
   * 
* * Protobuf type {@code envoy.config.common.mutation_rules.v3.HeaderMutation} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:envoy.config.common.mutation_rules.v3.HeaderMutation) io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutationOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.envoyproxy.envoy.config.common.mutation_rules.v3.MutationRulesProto.internal_static_envoy_config_common_mutation_rules_v3_HeaderMutation_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.envoyproxy.envoy.config.common.mutation_rules.v3.MutationRulesProto.internal_static_envoy_config_common_mutation_rules_v3_HeaderMutation_fieldAccessorTable .ensureFieldAccessorsInitialized( io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation.class, io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation.Builder.class); } // Construct using io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { } } @java.lang.Override public Builder clear() { super.clear(); actionCase_ = 0; action_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return io.envoyproxy.envoy.config.common.mutation_rules.v3.MutationRulesProto.internal_static_envoy_config_common_mutation_rules_v3_HeaderMutation_descriptor; } @java.lang.Override public io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation getDefaultInstanceForType() { return io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation.getDefaultInstance(); } @java.lang.Override public io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation build() { io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation buildPartial() { io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation result = new io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation(this); if (actionCase_ == 1) { result.action_ = action_; } if (actionCase_ == 2) { if (appendBuilder_ == null) { result.action_ = action_; } else { result.action_ = appendBuilder_.build(); } } result.actionCase_ = actionCase_; 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.common.mutation_rules.v3.HeaderMutation) { return mergeFrom((io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation other) { if (other == io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation.getDefaultInstance()) return this; switch (other.getActionCase()) { case REMOVE: { actionCase_ = 1; action_ = other.action_; onChanged(); break; } case APPEND: { mergeAppend(other.getAppend()); break; } case ACTION_NOT_SET: { break; } } this.mergeUnknownFields(other.unknownFields); 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 { io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int actionCase_ = 0; private java.lang.Object action_; public ActionCase getActionCase() { return ActionCase.forNumber( actionCase_); } public Builder clearAction() { actionCase_ = 0; action_ = null; onChanged(); return this; } /** *
     * Remove the specified header if it exists.
     * 
* * string remove = 1 [(.validate.rules) = { ... } * @return Whether the remove field is set. */ @java.lang.Override public boolean hasRemove() { return actionCase_ == 1; } /** *
     * Remove the specified header if it exists.
     * 
* * string remove = 1 [(.validate.rules) = { ... } * @return The remove. */ @java.lang.Override public java.lang.String getRemove() { java.lang.Object ref = ""; if (actionCase_ == 1) { ref = action_; } if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (actionCase_ == 1) { action_ = s; } return s; } else { return (java.lang.String) ref; } } /** *
     * Remove the specified header if it exists.
     * 
* * string remove = 1 [(.validate.rules) = { ... } * @return The bytes for remove. */ @java.lang.Override public com.google.protobuf.ByteString getRemoveBytes() { java.lang.Object ref = ""; if (actionCase_ == 1) { ref = action_; } if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); if (actionCase_ == 1) { action_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * Remove the specified header if it exists.
     * 
* * string remove = 1 [(.validate.rules) = { ... } * @param value The remove to set. * @return This builder for chaining. */ public Builder setRemove( java.lang.String value) { if (value == null) { throw new NullPointerException(); } actionCase_ = 1; action_ = value; onChanged(); return this; } /** *
     * Remove the specified header if it exists.
     * 
* * string remove = 1 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearRemove() { if (actionCase_ == 1) { actionCase_ = 0; action_ = null; onChanged(); } return this; } /** *
     * Remove the specified header if it exists.
     * 
* * string remove = 1 [(.validate.rules) = { ... } * @param value The bytes for remove to set. * @return This builder for chaining. */ public Builder setRemoveBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); actionCase_ = 1; action_ = value; onChanged(); return this; } private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.HeaderValueOption, io.envoyproxy.envoy.config.core.v3.HeaderValueOption.Builder, io.envoyproxy.envoy.config.core.v3.HeaderValueOptionOrBuilder> appendBuilder_; /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; * @return Whether the append field is set. */ @java.lang.Override public boolean hasAppend() { return actionCase_ == 2; } /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; * @return The append. */ @java.lang.Override public io.envoyproxy.envoy.config.core.v3.HeaderValueOption getAppend() { if (appendBuilder_ == null) { if (actionCase_ == 2) { return (io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_; } return io.envoyproxy.envoy.config.core.v3.HeaderValueOption.getDefaultInstance(); } else { if (actionCase_ == 2) { return appendBuilder_.getMessage(); } return io.envoyproxy.envoy.config.core.v3.HeaderValueOption.getDefaultInstance(); } } /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; */ public Builder setAppend(io.envoyproxy.envoy.config.core.v3.HeaderValueOption value) { if (appendBuilder_ == null) { if (value == null) { throw new NullPointerException(); } action_ = value; onChanged(); } else { appendBuilder_.setMessage(value); } actionCase_ = 2; return this; } /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; */ public Builder setAppend( io.envoyproxy.envoy.config.core.v3.HeaderValueOption.Builder builderForValue) { if (appendBuilder_ == null) { action_ = builderForValue.build(); onChanged(); } else { appendBuilder_.setMessage(builderForValue.build()); } actionCase_ = 2; return this; } /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; */ public Builder mergeAppend(io.envoyproxy.envoy.config.core.v3.HeaderValueOption value) { if (appendBuilder_ == null) { if (actionCase_ == 2 && action_ != io.envoyproxy.envoy.config.core.v3.HeaderValueOption.getDefaultInstance()) { action_ = io.envoyproxy.envoy.config.core.v3.HeaderValueOption.newBuilder((io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_) .mergeFrom(value).buildPartial(); } else { action_ = value; } onChanged(); } else { if (actionCase_ == 2) { appendBuilder_.mergeFrom(value); } else { appendBuilder_.setMessage(value); } } actionCase_ = 2; return this; } /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; */ public Builder clearAppend() { if (appendBuilder_ == null) { if (actionCase_ == 2) { actionCase_ = 0; action_ = null; onChanged(); } } else { if (actionCase_ == 2) { actionCase_ = 0; action_ = null; } appendBuilder_.clear(); } return this; } /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; */ public io.envoyproxy.envoy.config.core.v3.HeaderValueOption.Builder getAppendBuilder() { return getAppendFieldBuilder().getBuilder(); } /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; */ @java.lang.Override public io.envoyproxy.envoy.config.core.v3.HeaderValueOptionOrBuilder getAppendOrBuilder() { if ((actionCase_ == 2) && (appendBuilder_ != null)) { return appendBuilder_.getMessageOrBuilder(); } else { if (actionCase_ == 2) { return (io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_; } return io.envoyproxy.envoy.config.core.v3.HeaderValueOption.getDefaultInstance(); } } /** *
     * Append new header by the specified HeaderValueOption.
     * 
* * .envoy.config.core.v3.HeaderValueOption append = 2; */ private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.HeaderValueOption, io.envoyproxy.envoy.config.core.v3.HeaderValueOption.Builder, io.envoyproxy.envoy.config.core.v3.HeaderValueOptionOrBuilder> getAppendFieldBuilder() { if (appendBuilder_ == null) { if (!(actionCase_ == 2)) { action_ = io.envoyproxy.envoy.config.core.v3.HeaderValueOption.getDefaultInstance(); } appendBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.HeaderValueOption, io.envoyproxy.envoy.config.core.v3.HeaderValueOption.Builder, io.envoyproxy.envoy.config.core.v3.HeaderValueOptionOrBuilder>( (io.envoyproxy.envoy.config.core.v3.HeaderValueOption) action_, getParentForChildren(), isClean()); action_ = null; } actionCase_ = 2; onChanged();; return appendBuilder_; } @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.common.mutation_rules.v3.HeaderMutation) } // @@protoc_insertion_point(class_scope:envoy.config.common.mutation_rules.v3.HeaderMutation) private static final io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation(); } public static io.envoyproxy.envoy.config.common.mutation_rules.v3.HeaderMutation getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public HeaderMutation parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new HeaderMutation(input, extensionRegistry); } }; 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.common.mutation_rules.v3.HeaderMutation getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy