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

io.opencensus.proto.metrics.v1.Point Maven / Gradle / Ivy

There is a newer version: 1.0.46
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: opencensus/proto/metrics/v1/metrics.proto

package io.opencensus.proto.metrics.v1;

/**
 * 
 * A timestamped measurement.
 * 
* * Protobuf type {@code opencensus.proto.metrics.v1.Point} */ public final class Point extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:opencensus.proto.metrics.v1.Point) PointOrBuilder { private static final long serialVersionUID = 0L; // Use Point.newBuilder() to construct. private Point(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private Point() { } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new Point(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private Point( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { com.google.protobuf.Timestamp.Builder subBuilder = null; if (timestamp_ != null) { subBuilder = timestamp_.toBuilder(); } timestamp_ = input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(timestamp_); timestamp_ = subBuilder.buildPartial(); } break; } case 16: { value_ = input.readInt64(); valueCase_ = 2; break; } case 25: { value_ = input.readDouble(); valueCase_ = 3; break; } case 34: { io.opencensus.proto.metrics.v1.DistributionValue.Builder subBuilder = null; if (valueCase_ == 4) { subBuilder = ((io.opencensus.proto.metrics.v1.DistributionValue) value_).toBuilder(); } value_ = input.readMessage(io.opencensus.proto.metrics.v1.DistributionValue.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom((io.opencensus.proto.metrics.v1.DistributionValue) value_); value_ = subBuilder.buildPartial(); } valueCase_ = 4; break; } case 42: { io.opencensus.proto.metrics.v1.SummaryValue.Builder subBuilder = null; if (valueCase_ == 5) { subBuilder = ((io.opencensus.proto.metrics.v1.SummaryValue) value_).toBuilder(); } value_ = input.readMessage(io.opencensus.proto.metrics.v1.SummaryValue.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom((io.opencensus.proto.metrics.v1.SummaryValue) value_); value_ = subBuilder.buildPartial(); } valueCase_ = 5; break; } default: { if (!parseUnknownField( input, unknownFields, extensionRegistry, tag)) { done = true; } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e).setUnfinishedMessage(this); } finally { this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.opencensus.proto.metrics.v1.MetricsProto.internal_static_opencensus_proto_metrics_v1_Point_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.opencensus.proto.metrics.v1.MetricsProto.internal_static_opencensus_proto_metrics_v1_Point_fieldAccessorTable .ensureFieldAccessorsInitialized( io.opencensus.proto.metrics.v1.Point.class, io.opencensus.proto.metrics.v1.Point.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 { INT64_VALUE(2), DOUBLE_VALUE(3), DISTRIBUTION_VALUE(4), SUMMARY_VALUE(5), 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 INT64_VALUE; case 3: return DOUBLE_VALUE; case 4: return DISTRIBUTION_VALUE; case 5: return SUMMARY_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 TIMESTAMP_FIELD_NUMBER = 1; private com.google.protobuf.Timestamp timestamp_; /** *
   * The moment when this point was recorded. Inclusive.
   * If not specified, the timestamp will be decided by the backend.
   * 
* * .google.protobuf.Timestamp timestamp = 1; * @return Whether the timestamp field is set. */ @java.lang.Override public boolean hasTimestamp() { return timestamp_ != null; } /** *
   * The moment when this point was recorded. Inclusive.
   * If not specified, the timestamp will be decided by the backend.
   * 
* * .google.protobuf.Timestamp timestamp = 1; * @return The timestamp. */ @java.lang.Override public com.google.protobuf.Timestamp getTimestamp() { return timestamp_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : timestamp_; } /** *
   * The moment when this point was recorded. Inclusive.
   * If not specified, the timestamp will be decided by the backend.
   * 
* * .google.protobuf.Timestamp timestamp = 1; */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getTimestampOrBuilder() { return getTimestamp(); } public static final int INT64_VALUE_FIELD_NUMBER = 2; /** *
   * A 64-bit integer.
   * 
* * int64 int64_value = 2; * @return Whether the int64Value field is set. */ @java.lang.Override public boolean hasInt64Value() { return valueCase_ == 2; } /** *
   * A 64-bit integer.
   * 
* * int64 int64_value = 2; * @return The int64Value. */ @java.lang.Override public long getInt64Value() { if (valueCase_ == 2) { return (java.lang.Long) value_; } return 0L; } public static final int DOUBLE_VALUE_FIELD_NUMBER = 3; /** *
   * A 64-bit double-precision floating-point number.
   * 
* * double double_value = 3; * @return Whether the doubleValue field is set. */ @java.lang.Override public boolean hasDoubleValue() { return valueCase_ == 3; } /** *
   * A 64-bit double-precision floating-point number.
   * 
* * double double_value = 3; * @return The doubleValue. */ @java.lang.Override public double getDoubleValue() { if (valueCase_ == 3) { return (java.lang.Double) value_; } return 0D; } public static final int DISTRIBUTION_VALUE_FIELD_NUMBER = 4; /** *
   * A distribution value.
   * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; * @return Whether the distributionValue field is set. */ @java.lang.Override public boolean hasDistributionValue() { return valueCase_ == 4; } /** *
   * A distribution value.
   * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; * @return The distributionValue. */ @java.lang.Override public io.opencensus.proto.metrics.v1.DistributionValue getDistributionValue() { if (valueCase_ == 4) { return (io.opencensus.proto.metrics.v1.DistributionValue) value_; } return io.opencensus.proto.metrics.v1.DistributionValue.getDefaultInstance(); } /** *
   * A distribution value.
   * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; */ @java.lang.Override public io.opencensus.proto.metrics.v1.DistributionValueOrBuilder getDistributionValueOrBuilder() { if (valueCase_ == 4) { return (io.opencensus.proto.metrics.v1.DistributionValue) value_; } return io.opencensus.proto.metrics.v1.DistributionValue.getDefaultInstance(); } public static final int SUMMARY_VALUE_FIELD_NUMBER = 5; /** *
   * A summary value. This is not recommended, since it cannot be aggregated.
   * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; * @return Whether the summaryValue field is set. */ @java.lang.Override public boolean hasSummaryValue() { return valueCase_ == 5; } /** *
   * A summary value. This is not recommended, since it cannot be aggregated.
   * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; * @return The summaryValue. */ @java.lang.Override public io.opencensus.proto.metrics.v1.SummaryValue getSummaryValue() { if (valueCase_ == 5) { return (io.opencensus.proto.metrics.v1.SummaryValue) value_; } return io.opencensus.proto.metrics.v1.SummaryValue.getDefaultInstance(); } /** *
   * A summary value. This is not recommended, since it cannot be aggregated.
   * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; */ @java.lang.Override public io.opencensus.proto.metrics.v1.SummaryValueOrBuilder getSummaryValueOrBuilder() { if (valueCase_ == 5) { return (io.opencensus.proto.metrics.v1.SummaryValue) value_; } return io.opencensus.proto.metrics.v1.SummaryValue.getDefaultInstance(); } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (timestamp_ != null) { output.writeMessage(1, getTimestamp()); } if (valueCase_ == 2) { output.writeInt64( 2, (long)((java.lang.Long) value_)); } if (valueCase_ == 3) { output.writeDouble( 3, (double)((java.lang.Double) value_)); } if (valueCase_ == 4) { output.writeMessage(4, (io.opencensus.proto.metrics.v1.DistributionValue) value_); } if (valueCase_ == 5) { output.writeMessage(5, (io.opencensus.proto.metrics.v1.SummaryValue) value_); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (timestamp_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(1, getTimestamp()); } if (valueCase_ == 2) { size += com.google.protobuf.CodedOutputStream .computeInt64Size( 2, (long)((java.lang.Long) value_)); } if (valueCase_ == 3) { size += com.google.protobuf.CodedOutputStream .computeDoubleSize( 3, (double)((java.lang.Double) value_)); } if (valueCase_ == 4) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(4, (io.opencensus.proto.metrics.v1.DistributionValue) value_); } if (valueCase_ == 5) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(5, (io.opencensus.proto.metrics.v1.SummaryValue) value_); } 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.opencensus.proto.metrics.v1.Point)) { return super.equals(obj); } io.opencensus.proto.metrics.v1.Point other = (io.opencensus.proto.metrics.v1.Point) obj; if (hasTimestamp() != other.hasTimestamp()) return false; if (hasTimestamp()) { if (!getTimestamp() .equals(other.getTimestamp())) return false; } if (!getValueCase().equals(other.getValueCase())) return false; switch (valueCase_) { case 2: if (getInt64Value() != other.getInt64Value()) return false; break; case 3: if (java.lang.Double.doubleToLongBits(getDoubleValue()) != java.lang.Double.doubleToLongBits( other.getDoubleValue())) return false; break; case 4: if (!getDistributionValue() .equals(other.getDistributionValue())) return false; break; case 5: if (!getSummaryValue() .equals(other.getSummaryValue())) 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 (hasTimestamp()) { hash = (37 * hash) + TIMESTAMP_FIELD_NUMBER; hash = (53 * hash) + getTimestamp().hashCode(); } switch (valueCase_) { case 2: hash = (37 * hash) + INT64_VALUE_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getInt64Value()); break; case 3: hash = (37 * hash) + DOUBLE_VALUE_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( java.lang.Double.doubleToLongBits(getDoubleValue())); break; case 4: hash = (37 * hash) + DISTRIBUTION_VALUE_FIELD_NUMBER; hash = (53 * hash) + getDistributionValue().hashCode(); break; case 5: hash = (37 * hash) + SUMMARY_VALUE_FIELD_NUMBER; hash = (53 * hash) + getSummaryValue().hashCode(); break; case 0: default: } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static io.opencensus.proto.metrics.v1.Point parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.opencensus.proto.metrics.v1.Point parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.opencensus.proto.metrics.v1.Point parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.opencensus.proto.metrics.v1.Point parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.opencensus.proto.metrics.v1.Point parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static io.opencensus.proto.metrics.v1.Point parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static io.opencensus.proto.metrics.v1.Point parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.opencensus.proto.metrics.v1.Point 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.opencensus.proto.metrics.v1.Point parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static io.opencensus.proto.metrics.v1.Point 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.opencensus.proto.metrics.v1.Point parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static io.opencensus.proto.metrics.v1.Point 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.opencensus.proto.metrics.v1.Point 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 timestamped measurement.
   * 
* * Protobuf type {@code opencensus.proto.metrics.v1.Point} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:opencensus.proto.metrics.v1.Point) io.opencensus.proto.metrics.v1.PointOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.opencensus.proto.metrics.v1.MetricsProto.internal_static_opencensus_proto_metrics_v1_Point_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.opencensus.proto.metrics.v1.MetricsProto.internal_static_opencensus_proto_metrics_v1_Point_fieldAccessorTable .ensureFieldAccessorsInitialized( io.opencensus.proto.metrics.v1.Point.class, io.opencensus.proto.metrics.v1.Point.Builder.class); } // Construct using io.opencensus.proto.metrics.v1.Point.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(); if (timestampBuilder_ == null) { timestamp_ = null; } else { timestamp_ = null; timestampBuilder_ = null; } valueCase_ = 0; value_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return io.opencensus.proto.metrics.v1.MetricsProto.internal_static_opencensus_proto_metrics_v1_Point_descriptor; } @java.lang.Override public io.opencensus.proto.metrics.v1.Point getDefaultInstanceForType() { return io.opencensus.proto.metrics.v1.Point.getDefaultInstance(); } @java.lang.Override public io.opencensus.proto.metrics.v1.Point build() { io.opencensus.proto.metrics.v1.Point result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public io.opencensus.proto.metrics.v1.Point buildPartial() { io.opencensus.proto.metrics.v1.Point result = new io.opencensus.proto.metrics.v1.Point(this); if (timestampBuilder_ == null) { result.timestamp_ = timestamp_; } else { result.timestamp_ = timestampBuilder_.build(); } if (valueCase_ == 2) { result.value_ = value_; } if (valueCase_ == 3) { result.value_ = value_; } if (valueCase_ == 4) { if (distributionValueBuilder_ == null) { result.value_ = value_; } else { result.value_ = distributionValueBuilder_.build(); } } if (valueCase_ == 5) { if (summaryValueBuilder_ == null) { result.value_ = value_; } else { result.value_ = summaryValueBuilder_.build(); } } result.valueCase_ = valueCase_; 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.opencensus.proto.metrics.v1.Point) { return mergeFrom((io.opencensus.proto.metrics.v1.Point)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(io.opencensus.proto.metrics.v1.Point other) { if (other == io.opencensus.proto.metrics.v1.Point.getDefaultInstance()) return this; if (other.hasTimestamp()) { mergeTimestamp(other.getTimestamp()); } switch (other.getValueCase()) { case INT64_VALUE: { setInt64Value(other.getInt64Value()); break; } case DOUBLE_VALUE: { setDoubleValue(other.getDoubleValue()); break; } case DISTRIBUTION_VALUE: { mergeDistributionValue(other.getDistributionValue()); break; } case SUMMARY_VALUE: { mergeSummaryValue(other.getSummaryValue()); break; } case VALUE_NOT_SET: { break; } } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { io.opencensus.proto.metrics.v1.Point parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (io.opencensus.proto.metrics.v1.Point) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } 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 com.google.protobuf.Timestamp timestamp_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> timestampBuilder_; /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; * @return Whether the timestamp field is set. */ public boolean hasTimestamp() { return timestampBuilder_ != null || timestamp_ != null; } /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; * @return The timestamp. */ public com.google.protobuf.Timestamp getTimestamp() { if (timestampBuilder_ == null) { return timestamp_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : timestamp_; } else { return timestampBuilder_.getMessage(); } } /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; */ public Builder setTimestamp(com.google.protobuf.Timestamp value) { if (timestampBuilder_ == null) { if (value == null) { throw new NullPointerException(); } timestamp_ = value; onChanged(); } else { timestampBuilder_.setMessage(value); } return this; } /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; */ public Builder setTimestamp( com.google.protobuf.Timestamp.Builder builderForValue) { if (timestampBuilder_ == null) { timestamp_ = builderForValue.build(); onChanged(); } else { timestampBuilder_.setMessage(builderForValue.build()); } return this; } /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; */ public Builder mergeTimestamp(com.google.protobuf.Timestamp value) { if (timestampBuilder_ == null) { if (timestamp_ != null) { timestamp_ = com.google.protobuf.Timestamp.newBuilder(timestamp_).mergeFrom(value).buildPartial(); } else { timestamp_ = value; } onChanged(); } else { timestampBuilder_.mergeFrom(value); } return this; } /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; */ public Builder clearTimestamp() { if (timestampBuilder_ == null) { timestamp_ = null; onChanged(); } else { timestamp_ = null; timestampBuilder_ = null; } return this; } /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; */ public com.google.protobuf.Timestamp.Builder getTimestampBuilder() { onChanged(); return getTimestampFieldBuilder().getBuilder(); } /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; */ public com.google.protobuf.TimestampOrBuilder getTimestampOrBuilder() { if (timestampBuilder_ != null) { return timestampBuilder_.getMessageOrBuilder(); } else { return timestamp_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : timestamp_; } } /** *
     * The moment when this point was recorded. Inclusive.
     * If not specified, the timestamp will be decided by the backend.
     * 
* * .google.protobuf.Timestamp timestamp = 1; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> getTimestampFieldBuilder() { if (timestampBuilder_ == null) { timestampBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( getTimestamp(), getParentForChildren(), isClean()); timestamp_ = null; } return timestampBuilder_; } /** *
     * A 64-bit integer.
     * 
* * int64 int64_value = 2; * @return Whether the int64Value field is set. */ public boolean hasInt64Value() { return valueCase_ == 2; } /** *
     * A 64-bit integer.
     * 
* * int64 int64_value = 2; * @return The int64Value. */ public long getInt64Value() { if (valueCase_ == 2) { return (java.lang.Long) value_; } return 0L; } /** *
     * A 64-bit integer.
     * 
* * int64 int64_value = 2; * @param value The int64Value to set. * @return This builder for chaining. */ public Builder setInt64Value(long value) { valueCase_ = 2; value_ = value; onChanged(); return this; } /** *
     * A 64-bit integer.
     * 
* * int64 int64_value = 2; * @return This builder for chaining. */ public Builder clearInt64Value() { if (valueCase_ == 2) { valueCase_ = 0; value_ = null; onChanged(); } return this; } /** *
     * A 64-bit double-precision floating-point number.
     * 
* * double double_value = 3; * @return Whether the doubleValue field is set. */ public boolean hasDoubleValue() { return valueCase_ == 3; } /** *
     * A 64-bit double-precision floating-point number.
     * 
* * double double_value = 3; * @return The doubleValue. */ public double getDoubleValue() { if (valueCase_ == 3) { return (java.lang.Double) value_; } return 0D; } /** *
     * A 64-bit double-precision floating-point number.
     * 
* * double double_value = 3; * @param value The doubleValue to set. * @return This builder for chaining. */ public Builder setDoubleValue(double value) { valueCase_ = 3; value_ = value; onChanged(); return this; } /** *
     * A 64-bit double-precision floating-point number.
     * 
* * double double_value = 3; * @return This builder for chaining. */ public Builder clearDoubleValue() { if (valueCase_ == 3) { valueCase_ = 0; value_ = null; onChanged(); } return this; } private com.google.protobuf.SingleFieldBuilderV3< io.opencensus.proto.metrics.v1.DistributionValue, io.opencensus.proto.metrics.v1.DistributionValue.Builder, io.opencensus.proto.metrics.v1.DistributionValueOrBuilder> distributionValueBuilder_; /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; * @return Whether the distributionValue field is set. */ @java.lang.Override public boolean hasDistributionValue() { return valueCase_ == 4; } /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; * @return The distributionValue. */ @java.lang.Override public io.opencensus.proto.metrics.v1.DistributionValue getDistributionValue() { if (distributionValueBuilder_ == null) { if (valueCase_ == 4) { return (io.opencensus.proto.metrics.v1.DistributionValue) value_; } return io.opencensus.proto.metrics.v1.DistributionValue.getDefaultInstance(); } else { if (valueCase_ == 4) { return distributionValueBuilder_.getMessage(); } return io.opencensus.proto.metrics.v1.DistributionValue.getDefaultInstance(); } } /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; */ public Builder setDistributionValue(io.opencensus.proto.metrics.v1.DistributionValue value) { if (distributionValueBuilder_ == null) { if (value == null) { throw new NullPointerException(); } value_ = value; onChanged(); } else { distributionValueBuilder_.setMessage(value); } valueCase_ = 4; return this; } /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; */ public Builder setDistributionValue( io.opencensus.proto.metrics.v1.DistributionValue.Builder builderForValue) { if (distributionValueBuilder_ == null) { value_ = builderForValue.build(); onChanged(); } else { distributionValueBuilder_.setMessage(builderForValue.build()); } valueCase_ = 4; return this; } /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; */ public Builder mergeDistributionValue(io.opencensus.proto.metrics.v1.DistributionValue value) { if (distributionValueBuilder_ == null) { if (valueCase_ == 4 && value_ != io.opencensus.proto.metrics.v1.DistributionValue.getDefaultInstance()) { value_ = io.opencensus.proto.metrics.v1.DistributionValue.newBuilder((io.opencensus.proto.metrics.v1.DistributionValue) value_) .mergeFrom(value).buildPartial(); } else { value_ = value; } onChanged(); } else { if (valueCase_ == 4) { distributionValueBuilder_.mergeFrom(value); } else { distributionValueBuilder_.setMessage(value); } } valueCase_ = 4; return this; } /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; */ public Builder clearDistributionValue() { if (distributionValueBuilder_ == null) { if (valueCase_ == 4) { valueCase_ = 0; value_ = null; onChanged(); } } else { if (valueCase_ == 4) { valueCase_ = 0; value_ = null; } distributionValueBuilder_.clear(); } return this; } /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; */ public io.opencensus.proto.metrics.v1.DistributionValue.Builder getDistributionValueBuilder() { return getDistributionValueFieldBuilder().getBuilder(); } /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; */ @java.lang.Override public io.opencensus.proto.metrics.v1.DistributionValueOrBuilder getDistributionValueOrBuilder() { if ((valueCase_ == 4) && (distributionValueBuilder_ != null)) { return distributionValueBuilder_.getMessageOrBuilder(); } else { if (valueCase_ == 4) { return (io.opencensus.proto.metrics.v1.DistributionValue) value_; } return io.opencensus.proto.metrics.v1.DistributionValue.getDefaultInstance(); } } /** *
     * A distribution value.
     * 
* * .opencensus.proto.metrics.v1.DistributionValue distribution_value = 4; */ private com.google.protobuf.SingleFieldBuilderV3< io.opencensus.proto.metrics.v1.DistributionValue, io.opencensus.proto.metrics.v1.DistributionValue.Builder, io.opencensus.proto.metrics.v1.DistributionValueOrBuilder> getDistributionValueFieldBuilder() { if (distributionValueBuilder_ == null) { if (!(valueCase_ == 4)) { value_ = io.opencensus.proto.metrics.v1.DistributionValue.getDefaultInstance(); } distributionValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< io.opencensus.proto.metrics.v1.DistributionValue, io.opencensus.proto.metrics.v1.DistributionValue.Builder, io.opencensus.proto.metrics.v1.DistributionValueOrBuilder>( (io.opencensus.proto.metrics.v1.DistributionValue) value_, getParentForChildren(), isClean()); value_ = null; } valueCase_ = 4; onChanged();; return distributionValueBuilder_; } private com.google.protobuf.SingleFieldBuilderV3< io.opencensus.proto.metrics.v1.SummaryValue, io.opencensus.proto.metrics.v1.SummaryValue.Builder, io.opencensus.proto.metrics.v1.SummaryValueOrBuilder> summaryValueBuilder_; /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; * @return Whether the summaryValue field is set. */ @java.lang.Override public boolean hasSummaryValue() { return valueCase_ == 5; } /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; * @return The summaryValue. */ @java.lang.Override public io.opencensus.proto.metrics.v1.SummaryValue getSummaryValue() { if (summaryValueBuilder_ == null) { if (valueCase_ == 5) { return (io.opencensus.proto.metrics.v1.SummaryValue) value_; } return io.opencensus.proto.metrics.v1.SummaryValue.getDefaultInstance(); } else { if (valueCase_ == 5) { return summaryValueBuilder_.getMessage(); } return io.opencensus.proto.metrics.v1.SummaryValue.getDefaultInstance(); } } /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; */ public Builder setSummaryValue(io.opencensus.proto.metrics.v1.SummaryValue value) { if (summaryValueBuilder_ == null) { if (value == null) { throw new NullPointerException(); } value_ = value; onChanged(); } else { summaryValueBuilder_.setMessage(value); } valueCase_ = 5; return this; } /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; */ public Builder setSummaryValue( io.opencensus.proto.metrics.v1.SummaryValue.Builder builderForValue) { if (summaryValueBuilder_ == null) { value_ = builderForValue.build(); onChanged(); } else { summaryValueBuilder_.setMessage(builderForValue.build()); } valueCase_ = 5; return this; } /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; */ public Builder mergeSummaryValue(io.opencensus.proto.metrics.v1.SummaryValue value) { if (summaryValueBuilder_ == null) { if (valueCase_ == 5 && value_ != io.opencensus.proto.metrics.v1.SummaryValue.getDefaultInstance()) { value_ = io.opencensus.proto.metrics.v1.SummaryValue.newBuilder((io.opencensus.proto.metrics.v1.SummaryValue) value_) .mergeFrom(value).buildPartial(); } else { value_ = value; } onChanged(); } else { if (valueCase_ == 5) { summaryValueBuilder_.mergeFrom(value); } else { summaryValueBuilder_.setMessage(value); } } valueCase_ = 5; return this; } /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; */ public Builder clearSummaryValue() { if (summaryValueBuilder_ == null) { if (valueCase_ == 5) { valueCase_ = 0; value_ = null; onChanged(); } } else { if (valueCase_ == 5) { valueCase_ = 0; value_ = null; } summaryValueBuilder_.clear(); } return this; } /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; */ public io.opencensus.proto.metrics.v1.SummaryValue.Builder getSummaryValueBuilder() { return getSummaryValueFieldBuilder().getBuilder(); } /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; */ @java.lang.Override public io.opencensus.proto.metrics.v1.SummaryValueOrBuilder getSummaryValueOrBuilder() { if ((valueCase_ == 5) && (summaryValueBuilder_ != null)) { return summaryValueBuilder_.getMessageOrBuilder(); } else { if (valueCase_ == 5) { return (io.opencensus.proto.metrics.v1.SummaryValue) value_; } return io.opencensus.proto.metrics.v1.SummaryValue.getDefaultInstance(); } } /** *
     * A summary value. This is not recommended, since it cannot be aggregated.
     * 
* * .opencensus.proto.metrics.v1.SummaryValue summary_value = 5; */ private com.google.protobuf.SingleFieldBuilderV3< io.opencensus.proto.metrics.v1.SummaryValue, io.opencensus.proto.metrics.v1.SummaryValue.Builder, io.opencensus.proto.metrics.v1.SummaryValueOrBuilder> getSummaryValueFieldBuilder() { if (summaryValueBuilder_ == null) { if (!(valueCase_ == 5)) { value_ = io.opencensus.proto.metrics.v1.SummaryValue.getDefaultInstance(); } summaryValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< io.opencensus.proto.metrics.v1.SummaryValue, io.opencensus.proto.metrics.v1.SummaryValue.Builder, io.opencensus.proto.metrics.v1.SummaryValueOrBuilder>( (io.opencensus.proto.metrics.v1.SummaryValue) value_, getParentForChildren(), isClean()); value_ = null; } valueCase_ = 5; onChanged();; return summaryValueBuilder_; } @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:opencensus.proto.metrics.v1.Point) } // @@protoc_insertion_point(class_scope:opencensus.proto.metrics.v1.Point) private static final io.opencensus.proto.metrics.v1.Point DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new io.opencensus.proto.metrics.v1.Point(); } public static io.opencensus.proto.metrics.v1.Point getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public Point parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new Point(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.opencensus.proto.metrics.v1.Point getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy