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

io.envoyproxy.envoy.config.trace.v3.LightstepConfig 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/trace/v3/lightstep.proto

package io.envoyproxy.envoy.config.trace.v3;

/**
 * 
 * Configuration for the LightStep tracer.
 * [#extension: envoy.tracers.lightstep]
 * [#not-implemented-hide:]
 * 
* * Protobuf type {@code envoy.config.trace.v3.LightstepConfig} */ public final class LightstepConfig extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:envoy.config.trace.v3.LightstepConfig) LightstepConfigOrBuilder { private static final long serialVersionUID = 0L; // Use LightstepConfig.newBuilder() to construct. private LightstepConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private LightstepConfig() { collectorCluster_ = ""; accessTokenFile_ = ""; propagationModes_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new LightstepConfig(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private LightstepConfig( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; 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(); collectorCluster_ = s; break; } case 18: { java.lang.String s = input.readStringRequireUtf8(); accessTokenFile_ = s; break; } case 24: { int rawValue = input.readEnum(); if (!((mutable_bitField0_ & 0x00000001) != 0)) { propagationModes_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } propagationModes_.add(rawValue); break; } case 26: { int length = input.readRawVarint32(); int oldLimit = input.pushLimit(length); while(input.getBytesUntilLimit() > 0) { int rawValue = input.readEnum(); if (!((mutable_bitField0_ & 0x00000001) != 0)) { propagationModes_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } propagationModes_.add(rawValue); } input.popLimit(oldLimit); break; } case 34: { io.envoyproxy.envoy.config.core.v3.DataSource.Builder subBuilder = null; if (accessToken_ != null) { subBuilder = accessToken_.toBuilder(); } accessToken_ = input.readMessage(io.envoyproxy.envoy.config.core.v3.DataSource.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(accessToken_); accessToken_ = subBuilder.buildPartial(); } 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 { if (((mutable_bitField0_ & 0x00000001) != 0)) { propagationModes_ = java.util.Collections.unmodifiableList(propagationModes_); } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.envoyproxy.envoy.config.trace.v3.LightstepProto.internal_static_envoy_config_trace_v3_LightstepConfig_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.envoyproxy.envoy.config.trace.v3.LightstepProto.internal_static_envoy_config_trace_v3_LightstepConfig_fieldAccessorTable .ensureFieldAccessorsInitialized( io.envoyproxy.envoy.config.trace.v3.LightstepConfig.class, io.envoyproxy.envoy.config.trace.v3.LightstepConfig.Builder.class); } /** *
   * Available propagation modes
   * 
* * Protobuf enum {@code envoy.config.trace.v3.LightstepConfig.PropagationMode} */ public enum PropagationMode implements com.google.protobuf.ProtocolMessageEnum { /** *
     * Propagate trace context in the single header x-ot-span-context.
     * 
* * ENVOY = 0; */ ENVOY(0), /** *
     * Propagate trace context using LightStep's native format.
     * 
* * LIGHTSTEP = 1; */ LIGHTSTEP(1), /** *
     * Propagate trace context using the b3 format.
     * 
* * B3 = 2; */ B3(2), /** *
     * Propagation trace context using the w3 trace-context standard.
     * 
* * TRACE_CONTEXT = 3; */ TRACE_CONTEXT(3), UNRECOGNIZED(-1), ; /** *
     * Propagate trace context in the single header x-ot-span-context.
     * 
* * ENVOY = 0; */ public static final int ENVOY_VALUE = 0; /** *
     * Propagate trace context using LightStep's native format.
     * 
* * LIGHTSTEP = 1; */ public static final int LIGHTSTEP_VALUE = 1; /** *
     * Propagate trace context using the b3 format.
     * 
* * B3 = 2; */ public static final int B3_VALUE = 2; /** *
     * Propagation trace context using the w3 trace-context standard.
     * 
* * TRACE_CONTEXT = 3; */ public static final int TRACE_CONTEXT_VALUE = 3; 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 PropagationMode 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 PropagationMode forNumber(int value) { switch (value) { case 0: return ENVOY; case 1: return LIGHTSTEP; case 2: return B3; case 3: return TRACE_CONTEXT; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap< PropagationMode> internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public PropagationMode findValueByNumber(int number) { return PropagationMode.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return io.envoyproxy.envoy.config.trace.v3.LightstepConfig.getDescriptor().getEnumTypes().get(0); } private static final PropagationMode[] VALUES = values(); public static PropagationMode valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException( "EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private PropagationMode(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:envoy.config.trace.v3.LightstepConfig.PropagationMode) } public static final int COLLECTOR_CLUSTER_FIELD_NUMBER = 1; private volatile java.lang.Object collectorCluster_; /** *
   * The cluster manager cluster that hosts the LightStep collectors.
   * 
* * string collector_cluster = 1 [(.validate.rules) = { ... } * @return The collectorCluster. */ @java.lang.Override public java.lang.String getCollectorCluster() { java.lang.Object ref = collectorCluster_; 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(); collectorCluster_ = s; return s; } } /** *
   * The cluster manager cluster that hosts the LightStep collectors.
   * 
* * string collector_cluster = 1 [(.validate.rules) = { ... } * @return The bytes for collectorCluster. */ @java.lang.Override public com.google.protobuf.ByteString getCollectorClusterBytes() { java.lang.Object ref = collectorCluster_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); collectorCluster_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int ACCESS_TOKEN_FILE_FIELD_NUMBER = 2; private volatile java.lang.Object accessTokenFile_; /** *
   * File containing the access token to the `LightStep
   * <https://lightstep.com/>`_ API.
   * 
* * string access_token_file = 2 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"]; * @deprecated envoy.config.trace.v3.LightstepConfig.access_token_file is deprecated. * See envoy/config/trace/v3/lightstep.proto;l=49 * @return The accessTokenFile. */ @java.lang.Override @java.lang.Deprecated public java.lang.String getAccessTokenFile() { java.lang.Object ref = accessTokenFile_; 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(); accessTokenFile_ = s; return s; } } /** *
   * File containing the access token to the `LightStep
   * <https://lightstep.com/>`_ API.
   * 
* * string access_token_file = 2 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"]; * @deprecated envoy.config.trace.v3.LightstepConfig.access_token_file is deprecated. * See envoy/config/trace/v3/lightstep.proto;l=49 * @return The bytes for accessTokenFile. */ @java.lang.Override @java.lang.Deprecated public com.google.protobuf.ByteString getAccessTokenFileBytes() { java.lang.Object ref = accessTokenFile_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); accessTokenFile_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int ACCESS_TOKEN_FIELD_NUMBER = 4; private io.envoyproxy.envoy.config.core.v3.DataSource accessToken_; /** *
   * Access token to the `LightStep <https://lightstep.com/>`_ API.
   * 
* * .envoy.config.core.v3.DataSource access_token = 4; * @return Whether the accessToken field is set. */ @java.lang.Override public boolean hasAccessToken() { return accessToken_ != null; } /** *
   * Access token to the `LightStep <https://lightstep.com/>`_ API.
   * 
* * .envoy.config.core.v3.DataSource access_token = 4; * @return The accessToken. */ @java.lang.Override public io.envoyproxy.envoy.config.core.v3.DataSource getAccessToken() { return accessToken_ == null ? io.envoyproxy.envoy.config.core.v3.DataSource.getDefaultInstance() : accessToken_; } /** *
   * Access token to the `LightStep <https://lightstep.com/>`_ API.
   * 
* * .envoy.config.core.v3.DataSource access_token = 4; */ @java.lang.Override public io.envoyproxy.envoy.config.core.v3.DataSourceOrBuilder getAccessTokenOrBuilder() { return getAccessToken(); } public static final int PROPAGATION_MODES_FIELD_NUMBER = 3; private java.util.List propagationModes_; private static final com.google.protobuf.Internal.ListAdapter.Converter< java.lang.Integer, io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode> propagationModes_converter_ = new com.google.protobuf.Internal.ListAdapter.Converter< java.lang.Integer, io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode>() { public io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode convert(java.lang.Integer from) { @SuppressWarnings("deprecation") io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode result = io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode.valueOf(from); return result == null ? io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode.UNRECOGNIZED : result; } }; /** *
   * Propagation modes to use by LightStep's tracer.
   * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @return A list containing the propagationModes. */ @java.lang.Override public java.util.List getPropagationModesList() { return new com.google.protobuf.Internal.ListAdapter< java.lang.Integer, io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode>(propagationModes_, propagationModes_converter_); } /** *
   * Propagation modes to use by LightStep's tracer.
   * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @return The count of propagationModes. */ @java.lang.Override public int getPropagationModesCount() { return propagationModes_.size(); } /** *
   * Propagation modes to use by LightStep's tracer.
   * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param index The index of the element to return. * @return The propagationModes at the given index. */ @java.lang.Override public io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode getPropagationModes(int index) { return propagationModes_converter_.convert(propagationModes_.get(index)); } /** *
   * Propagation modes to use by LightStep's tracer.
   * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @return A list containing the enum numeric values on the wire for propagationModes. */ @java.lang.Override public java.util.List getPropagationModesValueList() { return propagationModes_; } /** *
   * Propagation modes to use by LightStep's tracer.
   * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param index The index of the value to return. * @return The enum numeric value on the wire of propagationModes at the given index. */ @java.lang.Override public int getPropagationModesValue(int index) { return propagationModes_.get(index); } private int propagationModesMemoizedSerializedSize; 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 { getSerializedSize(); if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(collectorCluster_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, collectorCluster_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(accessTokenFile_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, accessTokenFile_); } if (getPropagationModesList().size() > 0) { output.writeUInt32NoTag(26); output.writeUInt32NoTag(propagationModesMemoizedSerializedSize); } for (int i = 0; i < propagationModes_.size(); i++) { output.writeEnumNoTag(propagationModes_.get(i)); } if (accessToken_ != null) { output.writeMessage(4, getAccessToken()); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(collectorCluster_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, collectorCluster_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(accessTokenFile_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, accessTokenFile_); } { int dataSize = 0; for (int i = 0; i < propagationModes_.size(); i++) { dataSize += com.google.protobuf.CodedOutputStream .computeEnumSizeNoTag(propagationModes_.get(i)); } size += dataSize; if (!getPropagationModesList().isEmpty()) { size += 1; size += com.google.protobuf.CodedOutputStream .computeUInt32SizeNoTag(dataSize); }propagationModesMemoizedSerializedSize = dataSize; } if (accessToken_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(4, getAccessToken()); } 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.trace.v3.LightstepConfig)) { return super.equals(obj); } io.envoyproxy.envoy.config.trace.v3.LightstepConfig other = (io.envoyproxy.envoy.config.trace.v3.LightstepConfig) obj; if (!getCollectorCluster() .equals(other.getCollectorCluster())) return false; if (!getAccessTokenFile() .equals(other.getAccessTokenFile())) return false; if (hasAccessToken() != other.hasAccessToken()) return false; if (hasAccessToken()) { if (!getAccessToken() .equals(other.getAccessToken())) return false; } if (!propagationModes_.equals(other.propagationModes_)) return false; 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(); hash = (37 * hash) + COLLECTOR_CLUSTER_FIELD_NUMBER; hash = (53 * hash) + getCollectorCluster().hashCode(); hash = (37 * hash) + ACCESS_TOKEN_FILE_FIELD_NUMBER; hash = (53 * hash) + getAccessTokenFile().hashCode(); if (hasAccessToken()) { hash = (37 * hash) + ACCESS_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getAccessToken().hashCode(); } if (getPropagationModesCount() > 0) { hash = (37 * hash) + PROPAGATION_MODES_FIELD_NUMBER; hash = (53 * hash) + propagationModes_.hashCode(); } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig 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.trace.v3.LightstepConfig parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig 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.trace.v3.LightstepConfig parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig 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.trace.v3.LightstepConfig parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig 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.trace.v3.LightstepConfig parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig 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.trace.v3.LightstepConfig 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; } /** *
   * Configuration for the LightStep tracer.
   * [#extension: envoy.tracers.lightstep]
   * [#not-implemented-hide:]
   * 
* * Protobuf type {@code envoy.config.trace.v3.LightstepConfig} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:envoy.config.trace.v3.LightstepConfig) io.envoyproxy.envoy.config.trace.v3.LightstepConfigOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.envoyproxy.envoy.config.trace.v3.LightstepProto.internal_static_envoy_config_trace_v3_LightstepConfig_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.envoyproxy.envoy.config.trace.v3.LightstepProto.internal_static_envoy_config_trace_v3_LightstepConfig_fieldAccessorTable .ensureFieldAccessorsInitialized( io.envoyproxy.envoy.config.trace.v3.LightstepConfig.class, io.envoyproxy.envoy.config.trace.v3.LightstepConfig.Builder.class); } // Construct using io.envoyproxy.envoy.config.trace.v3.LightstepConfig.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(); collectorCluster_ = ""; accessTokenFile_ = ""; if (accessTokenBuilder_ == null) { accessToken_ = null; } else { accessToken_ = null; accessTokenBuilder_ = null; } propagationModes_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return io.envoyproxy.envoy.config.trace.v3.LightstepProto.internal_static_envoy_config_trace_v3_LightstepConfig_descriptor; } @java.lang.Override public io.envoyproxy.envoy.config.trace.v3.LightstepConfig getDefaultInstanceForType() { return io.envoyproxy.envoy.config.trace.v3.LightstepConfig.getDefaultInstance(); } @java.lang.Override public io.envoyproxy.envoy.config.trace.v3.LightstepConfig build() { io.envoyproxy.envoy.config.trace.v3.LightstepConfig result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public io.envoyproxy.envoy.config.trace.v3.LightstepConfig buildPartial() { io.envoyproxy.envoy.config.trace.v3.LightstepConfig result = new io.envoyproxy.envoy.config.trace.v3.LightstepConfig(this); int from_bitField0_ = bitField0_; result.collectorCluster_ = collectorCluster_; result.accessTokenFile_ = accessTokenFile_; if (accessTokenBuilder_ == null) { result.accessToken_ = accessToken_; } else { result.accessToken_ = accessTokenBuilder_.build(); } if (((bitField0_ & 0x00000001) != 0)) { propagationModes_ = java.util.Collections.unmodifiableList(propagationModes_); bitField0_ = (bitField0_ & ~0x00000001); } result.propagationModes_ = propagationModes_; 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.trace.v3.LightstepConfig) { return mergeFrom((io.envoyproxy.envoy.config.trace.v3.LightstepConfig)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(io.envoyproxy.envoy.config.trace.v3.LightstepConfig other) { if (other == io.envoyproxy.envoy.config.trace.v3.LightstepConfig.getDefaultInstance()) return this; if (!other.getCollectorCluster().isEmpty()) { collectorCluster_ = other.collectorCluster_; onChanged(); } if (!other.getAccessTokenFile().isEmpty()) { accessTokenFile_ = other.accessTokenFile_; onChanged(); } if (other.hasAccessToken()) { mergeAccessToken(other.getAccessToken()); } if (!other.propagationModes_.isEmpty()) { if (propagationModes_.isEmpty()) { propagationModes_ = other.propagationModes_; bitField0_ = (bitField0_ & ~0x00000001); } else { ensurePropagationModesIsMutable(); propagationModes_.addAll(other.propagationModes_); } onChanged(); } 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.trace.v3.LightstepConfig parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (io.envoyproxy.envoy.config.trace.v3.LightstepConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int bitField0_; private java.lang.Object collectorCluster_ = ""; /** *
     * The cluster manager cluster that hosts the LightStep collectors.
     * 
* * string collector_cluster = 1 [(.validate.rules) = { ... } * @return The collectorCluster. */ public java.lang.String getCollectorCluster() { java.lang.Object ref = collectorCluster_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); collectorCluster_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     * The cluster manager cluster that hosts the LightStep collectors.
     * 
* * string collector_cluster = 1 [(.validate.rules) = { ... } * @return The bytes for collectorCluster. */ public com.google.protobuf.ByteString getCollectorClusterBytes() { java.lang.Object ref = collectorCluster_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); collectorCluster_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * The cluster manager cluster that hosts the LightStep collectors.
     * 
* * string collector_cluster = 1 [(.validate.rules) = { ... } * @param value The collectorCluster to set. * @return This builder for chaining. */ public Builder setCollectorCluster( java.lang.String value) { if (value == null) { throw new NullPointerException(); } collectorCluster_ = value; onChanged(); return this; } /** *
     * The cluster manager cluster that hosts the LightStep collectors.
     * 
* * string collector_cluster = 1 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearCollectorCluster() { collectorCluster_ = getDefaultInstance().getCollectorCluster(); onChanged(); return this; } /** *
     * The cluster manager cluster that hosts the LightStep collectors.
     * 
* * string collector_cluster = 1 [(.validate.rules) = { ... } * @param value The bytes for collectorCluster to set. * @return This builder for chaining. */ public Builder setCollectorClusterBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); collectorCluster_ = value; onChanged(); return this; } private java.lang.Object accessTokenFile_ = ""; /** *
     * File containing the access token to the `LightStep
     * <https://lightstep.com/>`_ API.
     * 
* * string access_token_file = 2 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"]; * @deprecated envoy.config.trace.v3.LightstepConfig.access_token_file is deprecated. * See envoy/config/trace/v3/lightstep.proto;l=49 * @return The accessTokenFile. */ @java.lang.Deprecated public java.lang.String getAccessTokenFile() { java.lang.Object ref = accessTokenFile_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); accessTokenFile_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     * File containing the access token to the `LightStep
     * <https://lightstep.com/>`_ API.
     * 
* * string access_token_file = 2 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"]; * @deprecated envoy.config.trace.v3.LightstepConfig.access_token_file is deprecated. * See envoy/config/trace/v3/lightstep.proto;l=49 * @return The bytes for accessTokenFile. */ @java.lang.Deprecated public com.google.protobuf.ByteString getAccessTokenFileBytes() { java.lang.Object ref = accessTokenFile_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); accessTokenFile_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * File containing the access token to the `LightStep
     * <https://lightstep.com/>`_ API.
     * 
* * string access_token_file = 2 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"]; * @deprecated envoy.config.trace.v3.LightstepConfig.access_token_file is deprecated. * See envoy/config/trace/v3/lightstep.proto;l=49 * @param value The accessTokenFile to set. * @return This builder for chaining. */ @java.lang.Deprecated public Builder setAccessTokenFile( java.lang.String value) { if (value == null) { throw new NullPointerException(); } accessTokenFile_ = value; onChanged(); return this; } /** *
     * File containing the access token to the `LightStep
     * <https://lightstep.com/>`_ API.
     * 
* * string access_token_file = 2 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"]; * @deprecated envoy.config.trace.v3.LightstepConfig.access_token_file is deprecated. * See envoy/config/trace/v3/lightstep.proto;l=49 * @return This builder for chaining. */ @java.lang.Deprecated public Builder clearAccessTokenFile() { accessTokenFile_ = getDefaultInstance().getAccessTokenFile(); onChanged(); return this; } /** *
     * File containing the access token to the `LightStep
     * <https://lightstep.com/>`_ API.
     * 
* * string access_token_file = 2 [deprecated = true, (.envoy.annotations.deprecated_at_minor_version) = "3.0"]; * @deprecated envoy.config.trace.v3.LightstepConfig.access_token_file is deprecated. * See envoy/config/trace/v3/lightstep.proto;l=49 * @param value The bytes for accessTokenFile to set. * @return This builder for chaining. */ @java.lang.Deprecated public Builder setAccessTokenFileBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); accessTokenFile_ = value; onChanged(); return this; } private io.envoyproxy.envoy.config.core.v3.DataSource accessToken_; private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.DataSource, io.envoyproxy.envoy.config.core.v3.DataSource.Builder, io.envoyproxy.envoy.config.core.v3.DataSourceOrBuilder> accessTokenBuilder_; /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; * @return Whether the accessToken field is set. */ public boolean hasAccessToken() { return accessTokenBuilder_ != null || accessToken_ != null; } /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; * @return The accessToken. */ public io.envoyproxy.envoy.config.core.v3.DataSource getAccessToken() { if (accessTokenBuilder_ == null) { return accessToken_ == null ? io.envoyproxy.envoy.config.core.v3.DataSource.getDefaultInstance() : accessToken_; } else { return accessTokenBuilder_.getMessage(); } } /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; */ public Builder setAccessToken(io.envoyproxy.envoy.config.core.v3.DataSource value) { if (accessTokenBuilder_ == null) { if (value == null) { throw new NullPointerException(); } accessToken_ = value; onChanged(); } else { accessTokenBuilder_.setMessage(value); } return this; } /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; */ public Builder setAccessToken( io.envoyproxy.envoy.config.core.v3.DataSource.Builder builderForValue) { if (accessTokenBuilder_ == null) { accessToken_ = builderForValue.build(); onChanged(); } else { accessTokenBuilder_.setMessage(builderForValue.build()); } return this; } /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; */ public Builder mergeAccessToken(io.envoyproxy.envoy.config.core.v3.DataSource value) { if (accessTokenBuilder_ == null) { if (accessToken_ != null) { accessToken_ = io.envoyproxy.envoy.config.core.v3.DataSource.newBuilder(accessToken_).mergeFrom(value).buildPartial(); } else { accessToken_ = value; } onChanged(); } else { accessTokenBuilder_.mergeFrom(value); } return this; } /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; */ public Builder clearAccessToken() { if (accessTokenBuilder_ == null) { accessToken_ = null; onChanged(); } else { accessToken_ = null; accessTokenBuilder_ = null; } return this; } /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; */ public io.envoyproxy.envoy.config.core.v3.DataSource.Builder getAccessTokenBuilder() { onChanged(); return getAccessTokenFieldBuilder().getBuilder(); } /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; */ public io.envoyproxy.envoy.config.core.v3.DataSourceOrBuilder getAccessTokenOrBuilder() { if (accessTokenBuilder_ != null) { return accessTokenBuilder_.getMessageOrBuilder(); } else { return accessToken_ == null ? io.envoyproxy.envoy.config.core.v3.DataSource.getDefaultInstance() : accessToken_; } } /** *
     * Access token to the `LightStep <https://lightstep.com/>`_ API.
     * 
* * .envoy.config.core.v3.DataSource access_token = 4; */ private com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.DataSource, io.envoyproxy.envoy.config.core.v3.DataSource.Builder, io.envoyproxy.envoy.config.core.v3.DataSourceOrBuilder> getAccessTokenFieldBuilder() { if (accessTokenBuilder_ == null) { accessTokenBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< io.envoyproxy.envoy.config.core.v3.DataSource, io.envoyproxy.envoy.config.core.v3.DataSource.Builder, io.envoyproxy.envoy.config.core.v3.DataSourceOrBuilder>( getAccessToken(), getParentForChildren(), isClean()); accessToken_ = null; } return accessTokenBuilder_; } private java.util.List propagationModes_ = java.util.Collections.emptyList(); private void ensurePropagationModesIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { propagationModes_ = new java.util.ArrayList(propagationModes_); bitField0_ |= 0x00000001; } } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @return A list containing the propagationModes. */ public java.util.List getPropagationModesList() { return new com.google.protobuf.Internal.ListAdapter< java.lang.Integer, io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode>(propagationModes_, propagationModes_converter_); } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @return The count of propagationModes. */ public int getPropagationModesCount() { return propagationModes_.size(); } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param index The index of the element to return. * @return The propagationModes at the given index. */ public io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode getPropagationModes(int index) { return propagationModes_converter_.convert(propagationModes_.get(index)); } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param index The index to set the value at. * @param value The propagationModes to set. * @return This builder for chaining. */ public Builder setPropagationModes( int index, io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode value) { if (value == null) { throw new NullPointerException(); } ensurePropagationModesIsMutable(); propagationModes_.set(index, value.getNumber()); onChanged(); return this; } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param value The propagationModes to add. * @return This builder for chaining. */ public Builder addPropagationModes(io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode value) { if (value == null) { throw new NullPointerException(); } ensurePropagationModesIsMutable(); propagationModes_.add(value.getNumber()); onChanged(); return this; } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param values The propagationModes to add. * @return This builder for chaining. */ public Builder addAllPropagationModes( java.lang.Iterable values) { ensurePropagationModesIsMutable(); for (io.envoyproxy.envoy.config.trace.v3.LightstepConfig.PropagationMode value : values) { propagationModes_.add(value.getNumber()); } onChanged(); return this; } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @return This builder for chaining. */ public Builder clearPropagationModes() { propagationModes_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @return A list containing the enum numeric values on the wire for propagationModes. */ public java.util.List getPropagationModesValueList() { return java.util.Collections.unmodifiableList(propagationModes_); } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param index The index of the value to return. * @return The enum numeric value on the wire of propagationModes at the given index. */ public int getPropagationModesValue(int index) { return propagationModes_.get(index); } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param index The index to set the value at. * @param value The enum numeric value on the wire for propagationModes to set. * @return This builder for chaining. */ public Builder setPropagationModesValue( int index, int value) { ensurePropagationModesIsMutable(); propagationModes_.set(index, value); onChanged(); return this; } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param value The enum numeric value on the wire for propagationModes to add. * @return This builder for chaining. */ public Builder addPropagationModesValue(int value) { ensurePropagationModesIsMutable(); propagationModes_.add(value); onChanged(); return this; } /** *
     * Propagation modes to use by LightStep's tracer.
     * 
* * repeated .envoy.config.trace.v3.LightstepConfig.PropagationMode propagation_modes = 3 [(.validate.rules) = { ... } * @param values The enum numeric values on the wire for propagationModes to add. * @return This builder for chaining. */ public Builder addAllPropagationModesValue( java.lang.Iterable values) { ensurePropagationModesIsMutable(); for (int value : values) { propagationModes_.add(value); } 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.trace.v3.LightstepConfig) } // @@protoc_insertion_point(class_scope:envoy.config.trace.v3.LightstepConfig) private static final io.envoyproxy.envoy.config.trace.v3.LightstepConfig DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.trace.v3.LightstepConfig(); } public static io.envoyproxy.envoy.config.trace.v3.LightstepConfig getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public LightstepConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new LightstepConfig(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.trace.v3.LightstepConfig getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy