Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: opentelemetry/proto/metrics/v1/metrics.proto
package io.opentelemetry.proto.metrics.v1;
/**
*
* A representation of an exemplar, which is a sample input measurement.
* Exemplars also hold information about the environment when the measurement
* was recorded, for example the span and trace ID of the active span when the
* exemplar was recorded.
*
*
* Protobuf type {@code opentelemetry.proto.metrics.v1.Exemplar}
*/
public final class Exemplar extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:opentelemetry.proto.metrics.v1.Exemplar)
ExemplarOrBuilder {
private static final long serialVersionUID = 0L;
// Use Exemplar.newBuilder() to construct.
private Exemplar(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Exemplar() {
filteredAttributes_ = java.util.Collections.emptyList();
spanId_ = com.google.protobuf.ByteString.EMPTY;
traceId_ = com.google.protobuf.ByteString.EMPTY;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new Exemplar();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Exemplar(
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 17: {
timeUnixNano_ = input.readFixed64();
break;
}
case 25: {
value_ = input.readDouble();
valueCase_ = 3;
break;
}
case 34: {
spanId_ = input.readBytes();
break;
}
case 42: {
traceId_ = input.readBytes();
break;
}
case 49: {
value_ = input.readSFixed64();
valueCase_ = 6;
break;
}
case 58: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
filteredAttributes_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000001;
}
filteredAttributes_.add(
input.readMessage(io.opentelemetry.proto.common.v1.KeyValue.parser(), extensionRegistry));
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)) {
filteredAttributes_ = java.util.Collections.unmodifiableList(filteredAttributes_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.opentelemetry.proto.metrics.v1.MetricsProto.internal_static_opentelemetry_proto_metrics_v1_Exemplar_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.opentelemetry.proto.metrics.v1.MetricsProto.internal_static_opentelemetry_proto_metrics_v1_Exemplar_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.opentelemetry.proto.metrics.v1.Exemplar.class, io.opentelemetry.proto.metrics.v1.Exemplar.Builder.class);
}
private int valueCase_ = 0;
private java.lang.Object value_;
public enum ValueCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
AS_DOUBLE(3),
AS_INT(6),
VALUE_NOT_SET(0);
private final int value;
private ValueCase(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 ValueCase valueOf(int value) {
return forNumber(value);
}
public static ValueCase forNumber(int value) {
switch (value) {
case 3: return AS_DOUBLE;
case 6: return AS_INT;
case 0: return VALUE_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ValueCase
getValueCase() {
return ValueCase.forNumber(
valueCase_);
}
public static final int FILTERED_ATTRIBUTES_FIELD_NUMBER = 7;
private java.util.List filteredAttributes_;
/**
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
*
* repeated .opentelemetry.proto.common.v1.KeyValue filtered_attributes = 7;
*/
@java.lang.Override
public int getFilteredAttributesCount() {
return filteredAttributes_.size();
}
/**
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
*
* repeated .opentelemetry.proto.common.v1.KeyValue filtered_attributes = 7;
*/
@java.lang.Override
public io.opentelemetry.proto.common.v1.KeyValueOrBuilder getFilteredAttributesOrBuilder(
int index) {
return filteredAttributes_.get(index);
}
public static final int TIME_UNIX_NANO_FIELD_NUMBER = 2;
private long timeUnixNano_;
/**
*
* time_unix_nano is the exact time when this exemplar was recorded
* Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January
* 1970.
*
*
* fixed64 time_unix_nano = 2;
* @return The timeUnixNano.
*/
@java.lang.Override
public long getTimeUnixNano() {
return timeUnixNano_;
}
public static final int AS_DOUBLE_FIELD_NUMBER = 3;
/**
* double as_double = 3;
* @return Whether the asDouble field is set.
*/
@java.lang.Override
public boolean hasAsDouble() {
return valueCase_ == 3;
}
/**
* double as_double = 3;
* @return The asDouble.
*/
@java.lang.Override
public double getAsDouble() {
if (valueCase_ == 3) {
return (java.lang.Double) value_;
}
return 0D;
}
public static final int AS_INT_FIELD_NUMBER = 6;
/**
* sfixed64 as_int = 6;
* @return Whether the asInt field is set.
*/
@java.lang.Override
public boolean hasAsInt() {
return valueCase_ == 6;
}
/**
* sfixed64 as_int = 6;
* @return The asInt.
*/
@java.lang.Override
public long getAsInt() {
if (valueCase_ == 6) {
return (java.lang.Long) value_;
}
return 0L;
}
public static final int SPAN_ID_FIELD_NUMBER = 4;
private com.google.protobuf.ByteString spanId_;
/**
*
* (Optional) Span ID of the exemplar trace.
* span_id may be missing if the measurement is not recorded inside a trace
* or if the trace is not sampled.
*
*
* bytes span_id = 4;
* @return The spanId.
*/
@java.lang.Override
public com.google.protobuf.ByteString getSpanId() {
return spanId_;
}
public static final int TRACE_ID_FIELD_NUMBER = 5;
private com.google.protobuf.ByteString traceId_;
/**
*
* (Optional) Trace ID of the exemplar trace.
* trace_id may be missing if the measurement is not recorded inside a trace
* or if the trace is not sampled.
*
*
* bytes trace_id = 5;
* @return The traceId.
*/
@java.lang.Override
public com.google.protobuf.ByteString getTraceId() {
return traceId_;
}
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 (timeUnixNano_ != 0L) {
output.writeFixed64(2, timeUnixNano_);
}
if (valueCase_ == 3) {
output.writeDouble(
3, (double)((java.lang.Double) value_));
}
if (!spanId_.isEmpty()) {
output.writeBytes(4, spanId_);
}
if (!traceId_.isEmpty()) {
output.writeBytes(5, traceId_);
}
if (valueCase_ == 6) {
output.writeSFixed64(
6, (long)((java.lang.Long) value_));
}
for (int i = 0; i < filteredAttributes_.size(); i++) {
output.writeMessage(7, filteredAttributes_.get(i));
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (timeUnixNano_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeFixed64Size(2, timeUnixNano_);
}
if (valueCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeDoubleSize(
3, (double)((java.lang.Double) value_));
}
if (!spanId_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(4, spanId_);
}
if (!traceId_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(5, traceId_);
}
if (valueCase_ == 6) {
size += com.google.protobuf.CodedOutputStream
.computeSFixed64Size(
6, (long)((java.lang.Long) value_));
}
for (int i = 0; i < filteredAttributes_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(7, filteredAttributes_.get(i));
}
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.opentelemetry.proto.metrics.v1.Exemplar)) {
return super.equals(obj);
}
io.opentelemetry.proto.metrics.v1.Exemplar other = (io.opentelemetry.proto.metrics.v1.Exemplar) obj;
if (!getFilteredAttributesList()
.equals(other.getFilteredAttributesList())) return false;
if (getTimeUnixNano()
!= other.getTimeUnixNano()) return false;
if (!getSpanId()
.equals(other.getSpanId())) return false;
if (!getTraceId()
.equals(other.getTraceId())) return false;
if (!getValueCase().equals(other.getValueCase())) return false;
switch (valueCase_) {
case 3:
if (java.lang.Double.doubleToLongBits(getAsDouble())
!= java.lang.Double.doubleToLongBits(
other.getAsDouble())) return false;
break;
case 6:
if (getAsInt()
!= other.getAsInt()) 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();
if (getFilteredAttributesCount() > 0) {
hash = (37 * hash) + FILTERED_ATTRIBUTES_FIELD_NUMBER;
hash = (53 * hash) + getFilteredAttributesList().hashCode();
}
hash = (37 * hash) + TIME_UNIX_NANO_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getTimeUnixNano());
hash = (37 * hash) + SPAN_ID_FIELD_NUMBER;
hash = (53 * hash) + getSpanId().hashCode();
hash = (37 * hash) + TRACE_ID_FIELD_NUMBER;
hash = (53 * hash) + getTraceId().hashCode();
switch (valueCase_) {
case 3:
hash = (37 * hash) + AS_DOUBLE_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
java.lang.Double.doubleToLongBits(getAsDouble()));
break;
case 6:
hash = (37 * hash) + AS_INT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getAsInt());
break;
case 0:
default:
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.opentelemetry.proto.metrics.v1.Exemplar parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar 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.opentelemetry.proto.metrics.v1.Exemplar parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar 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.opentelemetry.proto.metrics.v1.Exemplar parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.opentelemetry.proto.metrics.v1.Exemplar 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.opentelemetry.proto.metrics.v1.Exemplar 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;
}
/**
*
* A representation of an exemplar, which is a sample input measurement.
* Exemplars also hold information about the environment when the measurement
* was recorded, for example the span and trace ID of the active span when the
* exemplar was recorded.
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
*
* repeated .opentelemetry.proto.common.v1.KeyValue filtered_attributes = 7;
*/
public int getFilteredAttributesCount() {
if (filteredAttributesBuilder_ == null) {
return filteredAttributes_.size();
} else {
return filteredAttributesBuilder_.getCount();
}
}
/**
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
*
* repeated .opentelemetry.proto.common.v1.KeyValue filtered_attributes = 7;
*/
public Builder setFilteredAttributes(
int index, io.opentelemetry.proto.common.v1.KeyValue value) {
if (filteredAttributesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureFilteredAttributesIsMutable();
filteredAttributes_.set(index, value);
onChanged();
} else {
filteredAttributesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
*
* repeated .opentelemetry.proto.common.v1.KeyValue filtered_attributes = 7;
*/
public Builder addFilteredAttributes(io.opentelemetry.proto.common.v1.KeyValue value) {
if (filteredAttributesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureFilteredAttributesIsMutable();
filteredAttributes_.add(value);
onChanged();
} else {
filteredAttributesBuilder_.addMessage(value);
}
return this;
}
/**
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
*
* repeated .opentelemetry.proto.common.v1.KeyValue filtered_attributes = 7;
*/
public Builder addFilteredAttributes(
int index, io.opentelemetry.proto.common.v1.KeyValue value) {
if (filteredAttributesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureFilteredAttributesIsMutable();
filteredAttributes_.add(index, value);
onChanged();
} else {
filteredAttributesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
*
* repeated .opentelemetry.proto.common.v1.KeyValue filtered_attributes = 7;
*/
public io.opentelemetry.proto.common.v1.KeyValue.Builder getFilteredAttributesBuilder(
int index) {
return getFilteredAttributesFieldBuilder().getBuilder(index);
}
/**
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
*
* repeated .opentelemetry.proto.common.v1.KeyValue filtered_attributes = 7;
*/
public io.opentelemetry.proto.common.v1.KeyValueOrBuilder getFilteredAttributesOrBuilder(
int index) {
if (filteredAttributesBuilder_ == null) {
return filteredAttributes_.get(index); } else {
return filteredAttributesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* The set of key/value pairs that were filtered out by the aggregator, but
* recorded alongside the original measurement. Only key/value pairs that were
* filtered out by the aggregator should be included
*
* time_unix_nano is the exact time when this exemplar was recorded
* Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January
* 1970.
*
*
* fixed64 time_unix_nano = 2;
* @return The timeUnixNano.
*/
@java.lang.Override
public long getTimeUnixNano() {
return timeUnixNano_;
}
/**
*
* time_unix_nano is the exact time when this exemplar was recorded
* Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January
* 1970.
*
*
* fixed64 time_unix_nano = 2;
* @param value The timeUnixNano to set.
* @return This builder for chaining.
*/
public Builder setTimeUnixNano(long value) {
timeUnixNano_ = value;
onChanged();
return this;
}
/**
*
* time_unix_nano is the exact time when this exemplar was recorded
* Value is UNIX Epoch time in nanoseconds since 00:00:00 UTC on 1 January
* 1970.
*
*
* fixed64 time_unix_nano = 2;
* @return This builder for chaining.
*/
public Builder clearTimeUnixNano() {
timeUnixNano_ = 0L;
onChanged();
return this;
}
/**
* double as_double = 3;
* @return Whether the asDouble field is set.
*/
public boolean hasAsDouble() {
return valueCase_ == 3;
}
/**
* double as_double = 3;
* @return The asDouble.
*/
public double getAsDouble() {
if (valueCase_ == 3) {
return (java.lang.Double) value_;
}
return 0D;
}
/**
* double as_double = 3;
* @param value The asDouble to set.
* @return This builder for chaining.
*/
public Builder setAsDouble(double value) {
valueCase_ = 3;
value_ = value;
onChanged();
return this;
}
/**
* double as_double = 3;
* @return This builder for chaining.
*/
public Builder clearAsDouble() {
if (valueCase_ == 3) {
valueCase_ = 0;
value_ = null;
onChanged();
}
return this;
}
/**
* sfixed64 as_int = 6;
* @return Whether the asInt field is set.
*/
public boolean hasAsInt() {
return valueCase_ == 6;
}
/**
* sfixed64 as_int = 6;
* @return The asInt.
*/
public long getAsInt() {
if (valueCase_ == 6) {
return (java.lang.Long) value_;
}
return 0L;
}
/**
* sfixed64 as_int = 6;
* @param value The asInt to set.
* @return This builder for chaining.
*/
public Builder setAsInt(long value) {
valueCase_ = 6;
value_ = value;
onChanged();
return this;
}
/**
* sfixed64 as_int = 6;
* @return This builder for chaining.
*/
public Builder clearAsInt() {
if (valueCase_ == 6) {
valueCase_ = 0;
value_ = null;
onChanged();
}
return this;
}
private com.google.protobuf.ByteString spanId_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* (Optional) Span ID of the exemplar trace.
* span_id may be missing if the measurement is not recorded inside a trace
* or if the trace is not sampled.
*
* (Optional) Span ID of the exemplar trace.
* span_id may be missing if the measurement is not recorded inside a trace
* or if the trace is not sampled.
*
*
* bytes span_id = 4;
* @param value The spanId to set.
* @return This builder for chaining.
*/
public Builder setSpanId(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
spanId_ = value;
onChanged();
return this;
}
/**
*
* (Optional) Span ID of the exemplar trace.
* span_id may be missing if the measurement is not recorded inside a trace
* or if the trace is not sampled.
*
* (Optional) Trace ID of the exemplar trace.
* trace_id may be missing if the measurement is not recorded inside a trace
* or if the trace is not sampled.
*
* (Optional) Trace ID of the exemplar trace.
* trace_id may be missing if the measurement is not recorded inside a trace
* or if the trace is not sampled.
*
*
* bytes trace_id = 5;
* @param value The traceId to set.
* @return This builder for chaining.
*/
public Builder setTraceId(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
traceId_ = value;
onChanged();
return this;
}
/**
*
* (Optional) Trace ID of the exemplar trace.
* trace_id may be missing if the measurement is not recorded inside a trace
* or if the trace is not sampled.
*
*
* bytes trace_id = 5;
* @return This builder for chaining.
*/
public Builder clearTraceId() {
traceId_ = getDefaultInstance().getTraceId();
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:opentelemetry.proto.metrics.v1.Exemplar)
}
// @@protoc_insertion_point(class_scope:opentelemetry.proto.metrics.v1.Exemplar)
private static final io.opentelemetry.proto.metrics.v1.Exemplar DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.opentelemetry.proto.metrics.v1.Exemplar();
}
public static io.opentelemetry.proto.metrics.v1.Exemplar getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public Exemplar parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new Exemplar(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.opentelemetry.proto.metrics.v1.Exemplar getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}