com.google.apphosting.base.protos.LabelsProtos Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: labels.proto
package com.google.apphosting.base.protos;
public final class LabelsProtos {
private LabelsProtos() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions(
(com.google.protobuf.ExtensionRegistryLite) registry);
}
public interface LabelProtoOrBuilder extends
// @@protoc_insertion_point(interface_extends:cloud_trace.LabelProto)
com.google.protobuf.MessageOrBuilder {
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return Whether the key field is set.
*/
boolean hasKey();
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return The key.
*/
java.lang.String getKey();
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return The bytes for key.
*/
com.google.protobuf.ByteString
getKeyBytes();
/**
* string str_value = 2;
* @return Whether the strValue field is set.
*/
boolean hasStrValue();
/**
* string str_value = 2;
* @return The strValue.
*/
java.lang.String getStrValue();
/**
* string str_value = 2;
* @return The bytes for strValue.
*/
com.google.protobuf.ByteString
getStrValueBytes();
/**
* int64 int_value = 3;
* @return Whether the intValue field is set.
*/
boolean hasIntValue();
/**
* int64 int_value = 3;
* @return The intValue.
*/
long getIntValue();
/**
*
* The fingerprint of the value.
*
*
* uint64 value_hash_id = 5;
* @return Whether the valueHashId field is set.
*/
boolean hasValueHashId();
/**
*
* The fingerprint of the value.
*
*
* uint64 value_hash_id = 5;
* @return The valueHashId.
*/
long getValueHashId();
/**
* bool bool_value = 6;
* @return Whether the boolValue field is set.
*/
boolean hasBoolValue();
/**
* bool bool_value = 6;
* @return The boolValue.
*/
boolean getBoolValue();
/**
*
* Number of bytes truncanted from original str_value. Is required to support
* limits imposed by V2 API.
*
*
* optional int64 truncated_byte_count = 7;
* @return Whether the truncatedByteCount field is set.
*/
boolean hasTruncatedByteCount();
/**
*
* Number of bytes truncanted from original str_value. Is required to support
* limits imposed by V2 API.
*
*
* optional int64 truncated_byte_count = 7;
* @return The truncatedByteCount.
*/
long getTruncatedByteCount();
public com.google.apphosting.base.protos.LabelsProtos.LabelProto.IdCase getIdCase();
public com.google.apphosting.base.protos.LabelsProtos.LabelProto.ValueCase getValueCase();
}
/**
*
* A single key/value pair.
*
*
* Protobuf type {@code cloud_trace.LabelProto}
*/
public static final class LabelProto extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:cloud_trace.LabelProto)
LabelProtoOrBuilder {
private static final long serialVersionUID = 0L;
// Use LabelProto.newBuilder() to construct.
private LabelProto(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private LabelProto() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new LabelProto();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelProto_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelProto_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.apphosting.base.protos.LabelsProtos.LabelProto.class, com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder.class);
}
private int bitField0_;
private int idCase_ = 0;
private java.lang.Object id_;
public enum IdCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
KEY(1),
ID_NOT_SET(0);
private final int value;
private IdCase(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 IdCase valueOf(int value) {
return forNumber(value);
}
public static IdCase forNumber(int value) {
switch (value) {
case 1: return KEY;
case 0: return ID_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public IdCase
getIdCase() {
return IdCase.forNumber(
idCase_);
}
private int valueCase_ = 0;
private java.lang.Object value_;
public enum ValueCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
STR_VALUE(2),
INT_VALUE(3),
VALUE_HASH_ID(5),
BOOL_VALUE(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 2: return STR_VALUE;
case 3: return INT_VALUE;
case 5: return VALUE_HASH_ID;
case 6: return BOOL_VALUE;
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 KEY_FIELD_NUMBER = 1;
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return Whether the key field is set.
*/
public boolean hasKey() {
return idCase_ == 1;
}
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return The key.
*/
public java.lang.String getKey() {
java.lang.Object ref = "";
if (idCase_ == 1) {
ref = id_;
}
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 (bs.isValidUtf8() && (idCase_ == 1)) {
id_ = s;
}
return s;
}
}
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return The bytes for key.
*/
public com.google.protobuf.ByteString
getKeyBytes() {
java.lang.Object ref = "";
if (idCase_ == 1) {
ref = id_;
}
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (idCase_ == 1) {
id_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int STR_VALUE_FIELD_NUMBER = 2;
/**
* string str_value = 2;
* @return Whether the strValue field is set.
*/
public boolean hasStrValue() {
return valueCase_ == 2;
}
/**
* string str_value = 2;
* @return The strValue.
*/
public java.lang.String getStrValue() {
java.lang.Object ref = "";
if (valueCase_ == 2) {
ref = value_;
}
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 (bs.isValidUtf8() && (valueCase_ == 2)) {
value_ = s;
}
return s;
}
}
/**
* string str_value = 2;
* @return The bytes for strValue.
*/
public com.google.protobuf.ByteString
getStrValueBytes() {
java.lang.Object ref = "";
if (valueCase_ == 2) {
ref = value_;
}
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (valueCase_ == 2) {
value_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int INT_VALUE_FIELD_NUMBER = 3;
/**
* int64 int_value = 3;
* @return Whether the intValue field is set.
*/
@java.lang.Override
public boolean hasIntValue() {
return valueCase_ == 3;
}
/**
* int64 int_value = 3;
* @return The intValue.
*/
@java.lang.Override
public long getIntValue() {
if (valueCase_ == 3) {
return (java.lang.Long) value_;
}
return 0L;
}
public static final int VALUE_HASH_ID_FIELD_NUMBER = 5;
/**
*
* The fingerprint of the value.
*
*
* uint64 value_hash_id = 5;
* @return Whether the valueHashId field is set.
*/
@java.lang.Override
public boolean hasValueHashId() {
return valueCase_ == 5;
}
/**
*
* The fingerprint of the value.
*
*
* uint64 value_hash_id = 5;
* @return The valueHashId.
*/
@java.lang.Override
public long getValueHashId() {
if (valueCase_ == 5) {
return (java.lang.Long) value_;
}
return 0L;
}
public static final int BOOL_VALUE_FIELD_NUMBER = 6;
/**
* bool bool_value = 6;
* @return Whether the boolValue field is set.
*/
@java.lang.Override
public boolean hasBoolValue() {
return valueCase_ == 6;
}
/**
* bool bool_value = 6;
* @return The boolValue.
*/
@java.lang.Override
public boolean getBoolValue() {
if (valueCase_ == 6) {
return (java.lang.Boolean) value_;
}
return false;
}
public static final int TRUNCATED_BYTE_COUNT_FIELD_NUMBER = 7;
private long truncatedByteCount_ = 0L;
/**
*
* Number of bytes truncanted from original str_value. Is required to support
* limits imposed by V2 API.
*
*
* optional int64 truncated_byte_count = 7;
* @return Whether the truncatedByteCount field is set.
*/
@java.lang.Override
public boolean hasTruncatedByteCount() {
return ((bitField0_ & 0x00000020) != 0);
}
/**
*
* Number of bytes truncanted from original str_value. Is required to support
* limits imposed by V2 API.
*
*
* optional int64 truncated_byte_count = 7;
* @return The truncatedByteCount.
*/
@java.lang.Override
public long getTruncatedByteCount() {
return truncatedByteCount_;
}
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 (idCase_ == 1) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_);
}
if (valueCase_ == 2) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, value_);
}
if (valueCase_ == 3) {
output.writeInt64(
3, (long)((java.lang.Long) value_));
}
if (valueCase_ == 5) {
output.writeUInt64(
5, (long)((java.lang.Long) value_));
}
if (valueCase_ == 6) {
output.writeBool(
6, (boolean)((java.lang.Boolean) value_));
}
if (((bitField0_ & 0x00000020) != 0)) {
output.writeInt64(7, truncatedByteCount_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (idCase_ == 1) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_);
}
if (valueCase_ == 2) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, value_);
}
if (valueCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(
3, (long)((java.lang.Long) value_));
}
if (valueCase_ == 5) {
size += com.google.protobuf.CodedOutputStream
.computeUInt64Size(
5, (long)((java.lang.Long) value_));
}
if (valueCase_ == 6) {
size += com.google.protobuf.CodedOutputStream
.computeBoolSize(
6, (boolean)((java.lang.Boolean) value_));
}
if (((bitField0_ & 0x00000020) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(7, truncatedByteCount_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.apphosting.base.protos.LabelsProtos.LabelProto)) {
return super.equals(obj);
}
com.google.apphosting.base.protos.LabelsProtos.LabelProto other = (com.google.apphosting.base.protos.LabelsProtos.LabelProto) obj;
if (hasTruncatedByteCount() != other.hasTruncatedByteCount()) return false;
if (hasTruncatedByteCount()) {
if (getTruncatedByteCount()
!= other.getTruncatedByteCount()) return false;
}
if (!getIdCase().equals(other.getIdCase())) return false;
switch (idCase_) {
case 1:
if (!getKey()
.equals(other.getKey())) return false;
break;
case 0:
default:
}
if (!getValueCase().equals(other.getValueCase())) return false;
switch (valueCase_) {
case 2:
if (!getStrValue()
.equals(other.getStrValue())) return false;
break;
case 3:
if (getIntValue()
!= other.getIntValue()) return false;
break;
case 5:
if (getValueHashId()
!= other.getValueHashId()) return false;
break;
case 6:
if (getBoolValue()
!= other.getBoolValue()) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasTruncatedByteCount()) {
hash = (37 * hash) + TRUNCATED_BYTE_COUNT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getTruncatedByteCount());
}
switch (idCase_) {
case 1:
hash = (37 * hash) + KEY_FIELD_NUMBER;
hash = (53 * hash) + getKey().hashCode();
break;
case 0:
default:
}
switch (valueCase_) {
case 2:
hash = (37 * hash) + STR_VALUE_FIELD_NUMBER;
hash = (53 * hash) + getStrValue().hashCode();
break;
case 3:
hash = (37 * hash) + INT_VALUE_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getIntValue());
break;
case 5:
hash = (37 * hash) + VALUE_HASH_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getValueHashId());
break;
case 6:
hash = (37 * hash) + BOOL_VALUE_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getBoolValue());
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto 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 com.google.apphosting.base.protos.LabelsProtos.LabelProto parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto 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 com.google.apphosting.base.protos.LabelsProtos.LabelProto parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto 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(com.google.apphosting.base.protos.LabelsProtos.LabelProto 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 single key/value pair.
*
*
* Protobuf type {@code cloud_trace.LabelProto}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:cloud_trace.LabelProto)
com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelProto_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelProto_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.apphosting.base.protos.LabelsProtos.LabelProto.class, com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder.class);
}
// Construct using com.google.apphosting.base.protos.LabelsProtos.LabelProto.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
truncatedByteCount_ = 0L;
idCase_ = 0;
id_ = null;
valueCase_ = 0;
value_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelProto_descriptor;
}
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelProto getDefaultInstanceForType() {
return com.google.apphosting.base.protos.LabelsProtos.LabelProto.getDefaultInstance();
}
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelProto build() {
com.google.apphosting.base.protos.LabelsProtos.LabelProto result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelProto buildPartial() {
com.google.apphosting.base.protos.LabelsProtos.LabelProto result = new com.google.apphosting.base.protos.LabelsProtos.LabelProto(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(com.google.apphosting.base.protos.LabelsProtos.LabelProto result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000020) != 0)) {
result.truncatedByteCount_ = truncatedByteCount_;
to_bitField0_ |= 0x00000020;
}
result.bitField0_ |= to_bitField0_;
}
private void buildPartialOneofs(com.google.apphosting.base.protos.LabelsProtos.LabelProto result) {
result.idCase_ = idCase_;
result.id_ = this.id_;
result.valueCase_ = valueCase_;
result.value_ = this.value_;
}
@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 com.google.apphosting.base.protos.LabelsProtos.LabelProto) {
return mergeFrom((com.google.apphosting.base.protos.LabelsProtos.LabelProto)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.apphosting.base.protos.LabelsProtos.LabelProto other) {
if (other == com.google.apphosting.base.protos.LabelsProtos.LabelProto.getDefaultInstance()) return this;
if (other.hasTruncatedByteCount()) {
setTruncatedByteCount(other.getTruncatedByteCount());
}
switch (other.getIdCase()) {
case KEY: {
idCase_ = 1;
id_ = other.id_;
onChanged();
break;
}
case ID_NOT_SET: {
break;
}
}
switch (other.getValueCase()) {
case STR_VALUE: {
valueCase_ = 2;
value_ = other.value_;
onChanged();
break;
}
case INT_VALUE: {
setIntValue(other.getIntValue());
break;
}
case VALUE_HASH_ID: {
setValueHashId(other.getValueHashId());
break;
}
case BOOL_VALUE: {
setBoolValue(other.getBoolValue());
break;
}
case VALUE_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.protobuf.ByteString bs = input.readBytes();
idCase_ = 1;
id_ = bs;
break;
} // case 10
case 18: {
com.google.protobuf.ByteString bs = input.readBytes();
valueCase_ = 2;
value_ = bs;
break;
} // case 18
case 24: {
value_ = input.readInt64();
valueCase_ = 3;
break;
} // case 24
case 40: {
value_ = input.readUInt64();
valueCase_ = 5;
break;
} // case 40
case 48: {
value_ = input.readBool();
valueCase_ = 6;
break;
} // case 48
case 56: {
truncatedByteCount_ = input.readInt64();
bitField0_ |= 0x00000020;
break;
} // case 56
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int idCase_ = 0;
private java.lang.Object id_;
public IdCase
getIdCase() {
return IdCase.forNumber(
idCase_);
}
public Builder clearId() {
idCase_ = 0;
id_ = null;
onChanged();
return this;
}
private int valueCase_ = 0;
private java.lang.Object value_;
public ValueCase
getValueCase() {
return ValueCase.forNumber(
valueCase_);
}
public Builder clearValue() {
valueCase_ = 0;
value_ = null;
onChanged();
return this;
}
private int bitField0_;
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return Whether the key field is set.
*/
@java.lang.Override
public boolean hasKey() {
return idCase_ == 1;
}
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return The key.
*/
@java.lang.Override
public java.lang.String getKey() {
java.lang.Object ref = "";
if (idCase_ == 1) {
ref = id_;
}
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (idCase_ == 1) {
if (bs.isValidUtf8()) {
id_ = s;
}
}
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return The bytes for key.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getKeyBytes() {
java.lang.Object ref = "";
if (idCase_ == 1) {
ref = id_;
}
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (idCase_ == 1) {
id_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @param value The key to set.
* @return This builder for chaining.
*/
public Builder setKey(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
idCase_ = 1;
id_ = value;
onChanged();
return this;
}
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @return This builder for chaining.
*/
public Builder clearKey() {
if (idCase_ == 1) {
idCase_ = 0;
id_ = null;
onChanged();
}
return this;
}
/**
*
* TODO(36442493): unnest from the oneof.
* The size of the key is up to 128 bytes.
*
*
* string key = 1;
* @param value The bytes for key to set.
* @return This builder for chaining.
*/
public Builder setKeyBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
idCase_ = 1;
id_ = value;
onChanged();
return this;
}
/**
* string str_value = 2;
* @return Whether the strValue field is set.
*/
@java.lang.Override
public boolean hasStrValue() {
return valueCase_ == 2;
}
/**
* string str_value = 2;
* @return The strValue.
*/
@java.lang.Override
public java.lang.String getStrValue() {
java.lang.Object ref = "";
if (valueCase_ == 2) {
ref = value_;
}
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (valueCase_ == 2) {
if (bs.isValidUtf8()) {
value_ = s;
}
}
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string str_value = 2;
* @return The bytes for strValue.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getStrValueBytes() {
java.lang.Object ref = "";
if (valueCase_ == 2) {
ref = value_;
}
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (valueCase_ == 2) {
value_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string str_value = 2;
* @param value The strValue to set.
* @return This builder for chaining.
*/
public Builder setStrValue(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
valueCase_ = 2;
value_ = value;
onChanged();
return this;
}
/**
* string str_value = 2;
* @return This builder for chaining.
*/
public Builder clearStrValue() {
if (valueCase_ == 2) {
valueCase_ = 0;
value_ = null;
onChanged();
}
return this;
}
/**
* string str_value = 2;
* @param value The bytes for strValue to set.
* @return This builder for chaining.
*/
public Builder setStrValueBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
valueCase_ = 2;
value_ = value;
onChanged();
return this;
}
/**
* int64 int_value = 3;
* @return Whether the intValue field is set.
*/
public boolean hasIntValue() {
return valueCase_ == 3;
}
/**
* int64 int_value = 3;
* @return The intValue.
*/
public long getIntValue() {
if (valueCase_ == 3) {
return (java.lang.Long) value_;
}
return 0L;
}
/**
* int64 int_value = 3;
* @param value The intValue to set.
* @return This builder for chaining.
*/
public Builder setIntValue(long value) {
valueCase_ = 3;
value_ = value;
onChanged();
return this;
}
/**
* int64 int_value = 3;
* @return This builder for chaining.
*/
public Builder clearIntValue() {
if (valueCase_ == 3) {
valueCase_ = 0;
value_ = null;
onChanged();
}
return this;
}
/**
*
* The fingerprint of the value.
*
*
* uint64 value_hash_id = 5;
* @return Whether the valueHashId field is set.
*/
public boolean hasValueHashId() {
return valueCase_ == 5;
}
/**
*
* The fingerprint of the value.
*
*
* uint64 value_hash_id = 5;
* @return The valueHashId.
*/
public long getValueHashId() {
if (valueCase_ == 5) {
return (java.lang.Long) value_;
}
return 0L;
}
/**
*
* The fingerprint of the value.
*
*
* uint64 value_hash_id = 5;
* @param value The valueHashId to set.
* @return This builder for chaining.
*/
public Builder setValueHashId(long value) {
valueCase_ = 5;
value_ = value;
onChanged();
return this;
}
/**
*
* The fingerprint of the value.
*
*
* uint64 value_hash_id = 5;
* @return This builder for chaining.
*/
public Builder clearValueHashId() {
if (valueCase_ == 5) {
valueCase_ = 0;
value_ = null;
onChanged();
}
return this;
}
/**
* bool bool_value = 6;
* @return Whether the boolValue field is set.
*/
public boolean hasBoolValue() {
return valueCase_ == 6;
}
/**
* bool bool_value = 6;
* @return The boolValue.
*/
public boolean getBoolValue() {
if (valueCase_ == 6) {
return (java.lang.Boolean) value_;
}
return false;
}
/**
* bool bool_value = 6;
* @param value The boolValue to set.
* @return This builder for chaining.
*/
public Builder setBoolValue(boolean value) {
valueCase_ = 6;
value_ = value;
onChanged();
return this;
}
/**
* bool bool_value = 6;
* @return This builder for chaining.
*/
public Builder clearBoolValue() {
if (valueCase_ == 6) {
valueCase_ = 0;
value_ = null;
onChanged();
}
return this;
}
private long truncatedByteCount_ ;
/**
*
* Number of bytes truncanted from original str_value. Is required to support
* limits imposed by V2 API.
*
*
* optional int64 truncated_byte_count = 7;
* @return Whether the truncatedByteCount field is set.
*/
@java.lang.Override
public boolean hasTruncatedByteCount() {
return ((bitField0_ & 0x00000020) != 0);
}
/**
*
* Number of bytes truncanted from original str_value. Is required to support
* limits imposed by V2 API.
*
*
* optional int64 truncated_byte_count = 7;
* @return The truncatedByteCount.
*/
@java.lang.Override
public long getTruncatedByteCount() {
return truncatedByteCount_;
}
/**
*
* Number of bytes truncanted from original str_value. Is required to support
* limits imposed by V2 API.
*
*
* optional int64 truncated_byte_count = 7;
* @param value The truncatedByteCount to set.
* @return This builder for chaining.
*/
public Builder setTruncatedByteCount(long value) {
truncatedByteCount_ = value;
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
*
* Number of bytes truncanted from original str_value. Is required to support
* limits imposed by V2 API.
*
*
* optional int64 truncated_byte_count = 7;
* @return This builder for chaining.
*/
public Builder clearTruncatedByteCount() {
bitField0_ = (bitField0_ & ~0x00000020);
truncatedByteCount_ = 0L;
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:cloud_trace.LabelProto)
}
// @@protoc_insertion_point(class_scope:cloud_trace.LabelProto)
private static final com.google.apphosting.base.protos.LabelsProtos.LabelProto DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.apphosting.base.protos.LabelsProtos.LabelProto();
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelProto getDefaultInstance() {
return DEFAULT_INSTANCE;
}
@java.lang.Deprecated public static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public LabelProto parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelProto getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface LabelsProtoOrBuilder extends
// @@protoc_insertion_point(interface_extends:cloud_trace.LabelsProto)
com.google.protobuf.MessageOrBuilder {
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
java.util.List
getLabelList();
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
com.google.apphosting.base.protos.LabelsProtos.LabelProto getLabel(int index);
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
int getLabelCount();
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
java.util.List extends com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder>
getLabelOrBuilderList();
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder getLabelOrBuilder(
int index);
/**
*
* The number of labels that were discarded.
*
*
* optional int64 dropped_label_count = 2;
* @return Whether the droppedLabelCount field is set.
*/
boolean hasDroppedLabelCount();
/**
*
* The number of labels that were discarded.
*
*
* optional int64 dropped_label_count = 2;
* @return The droppedLabelCount.
*/
long getDroppedLabelCount();
}
/**
*
* A collection of labels.
*
*
* Protobuf type {@code cloud_trace.LabelsProto}
*/
public static final class LabelsProto extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:cloud_trace.LabelsProto)
LabelsProtoOrBuilder {
private static final long serialVersionUID = 0L;
// Use LabelsProto.newBuilder() to construct.
private LabelsProto(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private LabelsProto() {
label_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new LabelsProto();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelsProto_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelsProto_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.apphosting.base.protos.LabelsProtos.LabelsProto.class, com.google.apphosting.base.protos.LabelsProtos.LabelsProto.Builder.class);
}
private int bitField0_;
public static final int LABEL_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List label_;
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
@java.lang.Override
public java.util.List getLabelList() {
return label_;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
@java.lang.Override
public java.util.List extends com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder>
getLabelOrBuilderList() {
return label_;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
@java.lang.Override
public int getLabelCount() {
return label_.size();
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelProto getLabel(int index) {
return label_.get(index);
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder getLabelOrBuilder(
int index) {
return label_.get(index);
}
public static final int DROPPED_LABEL_COUNT_FIELD_NUMBER = 2;
private long droppedLabelCount_ = 0L;
/**
*
* The number of labels that were discarded.
*
*
* optional int64 dropped_label_count = 2;
* @return Whether the droppedLabelCount field is set.
*/
@java.lang.Override
public boolean hasDroppedLabelCount() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* The number of labels that were discarded.
*
*
* optional int64 dropped_label_count = 2;
* @return The droppedLabelCount.
*/
@java.lang.Override
public long getDroppedLabelCount() {
return droppedLabelCount_;
}
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 {
for (int i = 0; i < label_.size(); i++) {
output.writeMessage(1, label_.get(i));
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeInt64(2, droppedLabelCount_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < label_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, label_.get(i));
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(2, droppedLabelCount_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.apphosting.base.protos.LabelsProtos.LabelsProto)) {
return super.equals(obj);
}
com.google.apphosting.base.protos.LabelsProtos.LabelsProto other = (com.google.apphosting.base.protos.LabelsProtos.LabelsProto) obj;
if (!getLabelList()
.equals(other.getLabelList())) return false;
if (hasDroppedLabelCount() != other.hasDroppedLabelCount()) return false;
if (hasDroppedLabelCount()) {
if (getDroppedLabelCount()
!= other.getDroppedLabelCount()) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (getLabelCount() > 0) {
hash = (37 * hash) + LABEL_FIELD_NUMBER;
hash = (53 * hash) + getLabelList().hashCode();
}
if (hasDroppedLabelCount()) {
hash = (37 * hash) + DROPPED_LABEL_COUNT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getDroppedLabelCount());
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto 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 com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto 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 com.google.apphosting.base.protos.LabelsProtos.LabelsProto parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto 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(com.google.apphosting.base.protos.LabelsProtos.LabelsProto 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 collection of labels.
*
*
* Protobuf type {@code cloud_trace.LabelsProto}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:cloud_trace.LabelsProto)
com.google.apphosting.base.protos.LabelsProtos.LabelsProtoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelsProto_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelsProto_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.apphosting.base.protos.LabelsProtos.LabelsProto.class, com.google.apphosting.base.protos.LabelsProtos.LabelsProto.Builder.class);
}
// Construct using com.google.apphosting.base.protos.LabelsProtos.LabelsProto.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (labelBuilder_ == null) {
label_ = java.util.Collections.emptyList();
} else {
label_ = null;
labelBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
droppedLabelCount_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.apphosting.base.protos.LabelsProtos.internal_static_cloud_trace_LabelsProto_descriptor;
}
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelsProto getDefaultInstanceForType() {
return com.google.apphosting.base.protos.LabelsProtos.LabelsProto.getDefaultInstance();
}
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelsProto build() {
com.google.apphosting.base.protos.LabelsProtos.LabelsProto result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelsProto buildPartial() {
com.google.apphosting.base.protos.LabelsProtos.LabelsProto result = new com.google.apphosting.base.protos.LabelsProtos.LabelsProto(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.apphosting.base.protos.LabelsProtos.LabelsProto result) {
if (labelBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
label_ = java.util.Collections.unmodifiableList(label_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.label_ = label_;
} else {
result.label_ = labelBuilder_.build();
}
}
private void buildPartial0(com.google.apphosting.base.protos.LabelsProtos.LabelsProto result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.droppedLabelCount_ = droppedLabelCount_;
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.google.apphosting.base.protos.LabelsProtos.LabelsProto) {
return mergeFrom((com.google.apphosting.base.protos.LabelsProtos.LabelsProto)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.apphosting.base.protos.LabelsProtos.LabelsProto other) {
if (other == com.google.apphosting.base.protos.LabelsProtos.LabelsProto.getDefaultInstance()) return this;
if (labelBuilder_ == null) {
if (!other.label_.isEmpty()) {
if (label_.isEmpty()) {
label_ = other.label_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureLabelIsMutable();
label_.addAll(other.label_);
}
onChanged();
}
} else {
if (!other.label_.isEmpty()) {
if (labelBuilder_.isEmpty()) {
labelBuilder_.dispose();
labelBuilder_ = null;
label_ = other.label_;
bitField0_ = (bitField0_ & ~0x00000001);
labelBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getLabelFieldBuilder() : null;
} else {
labelBuilder_.addAllMessages(other.label_);
}
}
}
if (other.hasDroppedLabelCount()) {
setDroppedLabelCount(other.getDroppedLabelCount());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.apphosting.base.protos.LabelsProtos.LabelProto m =
input.readMessage(
com.google.apphosting.base.protos.LabelsProtos.LabelProto.PARSER,
extensionRegistry);
if (labelBuilder_ == null) {
ensureLabelIsMutable();
label_.add(m);
} else {
labelBuilder_.addMessage(m);
}
break;
} // case 10
case 16: {
droppedLabelCount_ = input.readInt64();
bitField0_ |= 0x00000002;
break;
} // case 16
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.util.List label_ =
java.util.Collections.emptyList();
private void ensureLabelIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
label_ = new java.util.ArrayList(label_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.apphosting.base.protos.LabelsProtos.LabelProto, com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder, com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder> labelBuilder_;
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public java.util.List getLabelList() {
if (labelBuilder_ == null) {
return java.util.Collections.unmodifiableList(label_);
} else {
return labelBuilder_.getMessageList();
}
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public int getLabelCount() {
if (labelBuilder_ == null) {
return label_.size();
} else {
return labelBuilder_.getCount();
}
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public com.google.apphosting.base.protos.LabelsProtos.LabelProto getLabel(int index) {
if (labelBuilder_ == null) {
return label_.get(index);
} else {
return labelBuilder_.getMessage(index);
}
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder setLabel(
int index, com.google.apphosting.base.protos.LabelsProtos.LabelProto value) {
if (labelBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureLabelIsMutable();
label_.set(index, value);
onChanged();
} else {
labelBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder setLabel(
int index, com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder builderForValue) {
if (labelBuilder_ == null) {
ensureLabelIsMutable();
label_.set(index, builderForValue.build());
onChanged();
} else {
labelBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder addLabel(com.google.apphosting.base.protos.LabelsProtos.LabelProto value) {
if (labelBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureLabelIsMutable();
label_.add(value);
onChanged();
} else {
labelBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder addLabel(
int index, com.google.apphosting.base.protos.LabelsProtos.LabelProto value) {
if (labelBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureLabelIsMutable();
label_.add(index, value);
onChanged();
} else {
labelBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder addLabel(
com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder builderForValue) {
if (labelBuilder_ == null) {
ensureLabelIsMutable();
label_.add(builderForValue.build());
onChanged();
} else {
labelBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder addLabel(
int index, com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder builderForValue) {
if (labelBuilder_ == null) {
ensureLabelIsMutable();
label_.add(index, builderForValue.build());
onChanged();
} else {
labelBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder addAllLabel(
java.lang.Iterable extends com.google.apphosting.base.protos.LabelsProtos.LabelProto> values) {
if (labelBuilder_ == null) {
ensureLabelIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, label_);
onChanged();
} else {
labelBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder clearLabel() {
if (labelBuilder_ == null) {
label_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
labelBuilder_.clear();
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public Builder removeLabel(int index) {
if (labelBuilder_ == null) {
ensureLabelIsMutable();
label_.remove(index);
onChanged();
} else {
labelBuilder_.remove(index);
}
return this;
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder getLabelBuilder(
int index) {
return getLabelFieldBuilder().getBuilder(index);
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder getLabelOrBuilder(
int index) {
if (labelBuilder_ == null) {
return label_.get(index); } else {
return labelBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public java.util.List extends com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder>
getLabelOrBuilderList() {
if (labelBuilder_ != null) {
return labelBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(label_);
}
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder addLabelBuilder() {
return getLabelFieldBuilder().addBuilder(
com.google.apphosting.base.protos.LabelsProtos.LabelProto.getDefaultInstance());
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder addLabelBuilder(
int index) {
return getLabelFieldBuilder().addBuilder(
index, com.google.apphosting.base.protos.LabelsProtos.LabelProto.getDefaultInstance());
}
/**
* repeated .cloud_trace.LabelProto label = 1;
*/
public java.util.List
getLabelBuilderList() {
return getLabelFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.apphosting.base.protos.LabelsProtos.LabelProto, com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder, com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder>
getLabelFieldBuilder() {
if (labelBuilder_ == null) {
labelBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.apphosting.base.protos.LabelsProtos.LabelProto, com.google.apphosting.base.protos.LabelsProtos.LabelProto.Builder, com.google.apphosting.base.protos.LabelsProtos.LabelProtoOrBuilder>(
label_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
label_ = null;
}
return labelBuilder_;
}
private long droppedLabelCount_ ;
/**
*
* The number of labels that were discarded.
*
*
* optional int64 dropped_label_count = 2;
* @return Whether the droppedLabelCount field is set.
*/
@java.lang.Override
public boolean hasDroppedLabelCount() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* The number of labels that were discarded.
*
*
* optional int64 dropped_label_count = 2;
* @return The droppedLabelCount.
*/
@java.lang.Override
public long getDroppedLabelCount() {
return droppedLabelCount_;
}
/**
*
* The number of labels that were discarded.
*
*
* optional int64 dropped_label_count = 2;
* @param value The droppedLabelCount to set.
* @return This builder for chaining.
*/
public Builder setDroppedLabelCount(long value) {
droppedLabelCount_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* The number of labels that were discarded.
*
*
* optional int64 dropped_label_count = 2;
* @return This builder for chaining.
*/
public Builder clearDroppedLabelCount() {
bitField0_ = (bitField0_ & ~0x00000002);
droppedLabelCount_ = 0L;
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:cloud_trace.LabelsProto)
}
// @@protoc_insertion_point(class_scope:cloud_trace.LabelsProto)
private static final com.google.apphosting.base.protos.LabelsProtos.LabelsProto DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.apphosting.base.protos.LabelsProtos.LabelsProto();
}
public static com.google.apphosting.base.protos.LabelsProtos.LabelsProto getDefaultInstance() {
return DEFAULT_INSTANCE;
}
@java.lang.Deprecated public static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public LabelsProto parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.apphosting.base.protos.LabelsProtos.LabelsProto getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_cloud_trace_LabelProto_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_cloud_trace_LabelProto_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_cloud_trace_LabelsProto_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_cloud_trace_LabelsProto_fieldAccessorTable;
public static com.google.protobuf.Descriptors.FileDescriptor
getDescriptor() {
return descriptor;
}
private static com.google.protobuf.Descriptors.FileDescriptor
descriptor;
static {
java.lang.String[] descriptorData = {
"\n\014labels.proto\022\013cloud_trace\"\264\001\n\nLabelPro" +
"to\022\r\n\003key\030\001 \001(\tH\000\022\023\n\tstr_value\030\002 \001(\tH\001\022\023" +
"\n\tint_value\030\003 \001(\003H\001\022\027\n\rvalue_hash_id\030\005 \001" +
"(\004H\001\022\024\n\nbool_value\030\006 \001(\010H\001\022\034\n\024truncated_" +
"byte_count\030\007 \001(\003B\004\n\002idB\007\n\005valueJ\004\010\004\020\005R\013k" +
"ey_hash_id\"R\n\013LabelsProto\022&\n\005label\030\001 \003(\013" +
"2\027.cloud_trace.LabelProto\022\033\n\023dropped_lab" +
"el_count\030\002 \001(\003B4\n!com.google.apphosting." +
"base.protosB\014LabelsProtos\370\001\001"
};
descriptor = com.google.protobuf.Descriptors.FileDescriptor
.internalBuildGeneratedFileFrom(descriptorData,
new com.google.protobuf.Descriptors.FileDescriptor[] {
});
internal_static_cloud_trace_LabelProto_descriptor =
getDescriptor().getMessageTypes().get(0);
internal_static_cloud_trace_LabelProto_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_cloud_trace_LabelProto_descriptor,
new java.lang.String[] { "Key", "StrValue", "IntValue", "ValueHashId", "BoolValue", "TruncatedByteCount", "Id", "Value", });
internal_static_cloud_trace_LabelsProto_descriptor =
getDescriptor().getMessageTypes().get(1);
internal_static_cloud_trace_LabelsProto_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_cloud_trace_LabelsProto_descriptor,
new java.lang.String[] { "Label", "DroppedLabelCount", });
}
// @@protoc_insertion_point(outer_class_scope)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy