// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: timedregion.proto

package cosmos.trace;

public final class Timings {
  private Timings() {}
  public static void registerAllExtensions(
      com.google.protobuf.ExtensionRegistry registry) {
  }
  public interface TimedRegionsOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required uint64 begin = 1;
    /**
     * <code>required uint64 begin = 1;</code>
     */
    boolean hasBegin();
    /**
     * <code>required uint64 begin = 1;</code>
     */
    long getBegin();

    // required string uuid = 2;
    /**
     * <code>required string uuid = 2;</code>
     */
    boolean hasUuid();
    /**
     * <code>required string uuid = 2;</code>
     */
    java.lang.String getUuid();
    /**
     * <code>required string uuid = 2;</code>
     */
    com.google.protobuf.ByteString
        getUuidBytes();

    // repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    java.util.List<cosmos.trace.Timings.TimedRegions.TimingMetadata> 
        getMetadataList();
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    cosmos.trace.Timings.TimedRegions.TimingMetadata getMetadata(int index);
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    int getMetadataCount();
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    java.util.List<? extends cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder> 
        getMetadataOrBuilderList();
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder getMetadataOrBuilder(
        int index);

    // repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    java.util.List<cosmos.trace.Timings.TimedRegions.TimedRegion> 
        getRegionList();
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    cosmos.trace.Timings.TimedRegions.TimedRegion getRegion(int index);
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    int getRegionCount();
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    java.util.List<? extends cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder> 
        getRegionOrBuilderList();
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder getRegionOrBuilder(
        int index);
  }
  /**
   * Protobuf type {@code cosmos.trace.TimedRegions}
   */
  public static final class TimedRegions extends
      com.google.protobuf.GeneratedMessage
      implements TimedRegionsOrBuilder {
    // Use TimedRegions.newBuilder() to construct.
    private TimedRegions(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private TimedRegions(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final TimedRegions defaultInstance;
    public static TimedRegions getDefaultInstance() {
      return defaultInstance;
    }

    public TimedRegions getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private TimedRegions(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 8: {
              bitField0_ |= 0x00000001;
              begin_ = input.readUInt64();
              break;
            }
            case 18: {
              bitField0_ |= 0x00000002;
              uuid_ = input.readBytes();
              break;
            }
            case 26: {
              if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
                metadata_ = new java.util.ArrayList<cosmos.trace.Timings.TimedRegions.TimingMetadata>();
                mutable_bitField0_ |= 0x00000004;
              }
              metadata_.add(input.readMessage(cosmos.trace.Timings.TimedRegions.TimingMetadata.PARSER, extensionRegistry));
              break;
            }
            case 34: {
              if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
                region_ = new java.util.ArrayList<cosmos.trace.Timings.TimedRegions.TimedRegion>();
                mutable_bitField0_ |= 0x00000008;
              }
              region_.add(input.readMessage(cosmos.trace.Timings.TimedRegions.TimedRegion.PARSER, extensionRegistry));
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
          metadata_ = java.util.Collections.unmodifiableList(metadata_);
        }
        if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
          region_ = java.util.Collections.unmodifiableList(region_);
        }
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              cosmos.trace.Timings.TimedRegions.class, cosmos.trace.Timings.TimedRegions.Builder.class);
    }

    public static com.google.protobuf.Parser<TimedRegions> PARSER =
        new com.google.protobuf.AbstractParser<TimedRegions>() {
      public TimedRegions parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new TimedRegions(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<TimedRegions> getParserForType() {
      return PARSER;
    }

    public interface TimedRegionOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // required string description = 1;
      /**
       * <code>required string description = 1;</code>
       */
      boolean hasDescription();
      /**
       * <code>required string description = 1;</code>
       */
      java.lang.String getDescription();
      /**
       * <code>required string description = 1;</code>
       */
      com.google.protobuf.ByteString
          getDescriptionBytes();

      // required uint64 duration = 2;
      /**
       * <code>required uint64 duration = 2;</code>
       */
      boolean hasDuration();
      /**
       * <code>required uint64 duration = 2;</code>
       */
      long getDuration();
    }
    /**
     * Protobuf type {@code cosmos.trace.TimedRegions.TimedRegion}
     */
    public static final class TimedRegion extends
        com.google.protobuf.GeneratedMessage
        implements TimedRegionOrBuilder {
      // Use TimedRegion.newBuilder() to construct.
      private TimedRegion(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private TimedRegion(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final TimedRegion defaultInstance;
      public static TimedRegion getDefaultInstance() {
        return defaultInstance;
      }

      public TimedRegion getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private TimedRegion(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                description_ = input.readBytes();
                break;
              }
              case 16: {
                bitField0_ |= 0x00000002;
                duration_ = input.readUInt64();
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimedRegion_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimedRegion_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                cosmos.trace.Timings.TimedRegions.TimedRegion.class, cosmos.trace.Timings.TimedRegions.TimedRegion.Builder.class);
      }

      public static com.google.protobuf.Parser<TimedRegion> PARSER =
          new com.google.protobuf.AbstractParser<TimedRegion>() {
        public TimedRegion parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new TimedRegion(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<TimedRegion> getParserForType() {
        return PARSER;
      }

      private int bitField0_;
      // required string description = 1;
      public static final int DESCRIPTION_FIELD_NUMBER = 1;
      private java.lang.Object description_;
      /**
       * <code>required string description = 1;</code>
       */
      public boolean hasDescription() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required string description = 1;</code>
       */
      public java.lang.String getDescription() {
        java.lang.Object ref = description_;
        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()) {
            description_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string description = 1;</code>
       */
      public com.google.protobuf.ByteString
          getDescriptionBytes() {
        java.lang.Object ref = description_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          description_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // required uint64 duration = 2;
      public static final int DURATION_FIELD_NUMBER = 2;
      private long duration_;
      /**
       * <code>required uint64 duration = 2;</code>
       */
      public boolean hasDuration() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required uint64 duration = 2;</code>
       */
      public long getDuration() {
        return duration_;
      }

      private void initFields() {
        description_ = "";
        duration_ = 0L;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (!hasDescription()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasDuration()) {
          memoizedIsInitialized = 0;
          return false;
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeBytes(1, getDescriptionBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeUInt64(2, duration_);
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(1, getDescriptionBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeUInt64Size(2, duration_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static cosmos.trace.Timings.TimedRegions.TimedRegion parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(cosmos.trace.Timings.TimedRegions.TimedRegion prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code cosmos.trace.TimedRegions.TimedRegion}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimedRegion_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimedRegion_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  cosmos.trace.Timings.TimedRegions.TimedRegion.class, cosmos.trace.Timings.TimedRegions.TimedRegion.Builder.class);
        }

        // Construct using cosmos.trace.Timings.TimedRegions.TimedRegion.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          description_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          duration_ = 0L;
          bitField0_ = (bitField0_ & ~0x00000002);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimedRegion_descriptor;
        }

        public cosmos.trace.Timings.TimedRegions.TimedRegion getDefaultInstanceForType() {
          return cosmos.trace.Timings.TimedRegions.TimedRegion.getDefaultInstance();
        }

        public cosmos.trace.Timings.TimedRegions.TimedRegion build() {
          cosmos.trace.Timings.TimedRegions.TimedRegion result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public cosmos.trace.Timings.TimedRegions.TimedRegion buildPartial() {
          cosmos.trace.Timings.TimedRegions.TimedRegion result = new cosmos.trace.Timings.TimedRegions.TimedRegion(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.description_ = description_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.duration_ = duration_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof cosmos.trace.Timings.TimedRegions.TimedRegion) {
            return mergeFrom((cosmos.trace.Timings.TimedRegions.TimedRegion)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(cosmos.trace.Timings.TimedRegions.TimedRegion other) {
          if (other == cosmos.trace.Timings.TimedRegions.TimedRegion.getDefaultInstance()) return this;
          if (other.hasDescription()) {
            bitField0_ |= 0x00000001;
            description_ = other.description_;
            onChanged();
          }
          if (other.hasDuration()) {
            setDuration(other.getDuration());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (!hasDescription()) {
            
            return false;
          }
          if (!hasDuration()) {
            
            return false;
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          cosmos.trace.Timings.TimedRegions.TimedRegion parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (cosmos.trace.Timings.TimedRegions.TimedRegion) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // required string description = 1;
        private java.lang.Object description_ = "";
        /**
         * <code>required string description = 1;</code>
         */
        public boolean hasDescription() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required string description = 1;</code>
         */
        public java.lang.String getDescription() {
          java.lang.Object ref = description_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            description_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string description = 1;</code>
         */
        public com.google.protobuf.ByteString
            getDescriptionBytes() {
          java.lang.Object ref = description_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            description_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string description = 1;</code>
         */
        public Builder setDescription(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          description_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string description = 1;</code>
         */
        public Builder clearDescription() {
          bitField0_ = (bitField0_ & ~0x00000001);
          description_ = getDefaultInstance().getDescription();
          onChanged();
          return this;
        }
        /**
         * <code>required string description = 1;</code>
         */
        public Builder setDescriptionBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          description_ = value;
          onChanged();
          return this;
        }

        // required uint64 duration = 2;
        private long duration_ ;
        /**
         * <code>required uint64 duration = 2;</code>
         */
        public boolean hasDuration() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>required uint64 duration = 2;</code>
         */
        public long getDuration() {
          return duration_;
        }
        /**
         * <code>required uint64 duration = 2;</code>
         */
        public Builder setDuration(long value) {
          bitField0_ |= 0x00000002;
          duration_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required uint64 duration = 2;</code>
         */
        public Builder clearDuration() {
          bitField0_ = (bitField0_ & ~0x00000002);
          duration_ = 0L;
          onChanged();
          return this;
        }

        // @@protoc_insertion_point(builder_scope:cosmos.trace.TimedRegions.TimedRegion)
      }

      static {
        defaultInstance = new TimedRegion(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:cosmos.trace.TimedRegions.TimedRegion)
    }

    public interface TimingMetadataOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // required string name = 1;
      /**
       * <code>required string name = 1;</code>
       */
      boolean hasName();
      /**
       * <code>required string name = 1;</code>
       */
      java.lang.String getName();
      /**
       * <code>required string name = 1;</code>
       */
      com.google.protobuf.ByteString
          getNameBytes();

      // required string value = 2;
      /**
       * <code>required string value = 2;</code>
       */
      boolean hasValue();
      /**
       * <code>required string value = 2;</code>
       */
      java.lang.String getValue();
      /**
       * <code>required string value = 2;</code>
       */
      com.google.protobuf.ByteString
          getValueBytes();
    }
    /**
     * Protobuf type {@code cosmos.trace.TimedRegions.TimingMetadata}
     */
    public static final class TimingMetadata extends
        com.google.protobuf.GeneratedMessage
        implements TimingMetadataOrBuilder {
      // Use TimingMetadata.newBuilder() to construct.
      private TimingMetadata(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private TimingMetadata(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final TimingMetadata defaultInstance;
      public static TimingMetadata getDefaultInstance() {
        return defaultInstance;
      }

      public TimingMetadata getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private TimingMetadata(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                name_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                value_ = input.readBytes();
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimingMetadata_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimingMetadata_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                cosmos.trace.Timings.TimedRegions.TimingMetadata.class, cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder.class);
      }

      public static com.google.protobuf.Parser<TimingMetadata> PARSER =
          new com.google.protobuf.AbstractParser<TimingMetadata>() {
        public TimingMetadata parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new TimingMetadata(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<TimingMetadata> getParserForType() {
        return PARSER;
      }

      private int bitField0_;
      // required string name = 1;
      public static final int NAME_FIELD_NUMBER = 1;
      private java.lang.Object name_;
      /**
       * <code>required string name = 1;</code>
       */
      public boolean hasName() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required string name = 1;</code>
       */
      public java.lang.String getName() {
        java.lang.Object ref = name_;
        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()) {
            name_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string name = 1;</code>
       */
      public com.google.protobuf.ByteString
          getNameBytes() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // required string value = 2;
      public static final int VALUE_FIELD_NUMBER = 2;
      private java.lang.Object value_;
      /**
       * <code>required string value = 2;</code>
       */
      public boolean hasValue() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required string value = 2;</code>
       */
      public java.lang.String getValue() {
        java.lang.Object 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()) {
            value_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string value = 2;</code>
       */
      public com.google.protobuf.ByteString
          getValueBytes() {
        java.lang.Object ref = value_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          value_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      private void initFields() {
        name_ = "";
        value_ = "";
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (!hasName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasValue()) {
          memoizedIsInitialized = 0;
          return false;
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeBytes(1, getNameBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getValueBytes());
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(1, getNameBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getValueBytes());
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static cosmos.trace.Timings.TimedRegions.TimingMetadata parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(cosmos.trace.Timings.TimedRegions.TimingMetadata prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code cosmos.trace.TimedRegions.TimingMetadata}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimingMetadata_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimingMetadata_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  cosmos.trace.Timings.TimedRegions.TimingMetadata.class, cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder.class);
        }

        // Construct using cosmos.trace.Timings.TimedRegions.TimingMetadata.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          value_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_TimingMetadata_descriptor;
        }

        public cosmos.trace.Timings.TimedRegions.TimingMetadata getDefaultInstanceForType() {
          return cosmos.trace.Timings.TimedRegions.TimingMetadata.getDefaultInstance();
        }

        public cosmos.trace.Timings.TimedRegions.TimingMetadata build() {
          cosmos.trace.Timings.TimedRegions.TimingMetadata result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public cosmos.trace.Timings.TimedRegions.TimingMetadata buildPartial() {
          cosmos.trace.Timings.TimedRegions.TimingMetadata result = new cosmos.trace.Timings.TimedRegions.TimingMetadata(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.name_ = name_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.value_ = value_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof cosmos.trace.Timings.TimedRegions.TimingMetadata) {
            return mergeFrom((cosmos.trace.Timings.TimedRegions.TimingMetadata)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(cosmos.trace.Timings.TimedRegions.TimingMetadata other) {
          if (other == cosmos.trace.Timings.TimedRegions.TimingMetadata.getDefaultInstance()) return this;
          if (other.hasName()) {
            bitField0_ |= 0x00000001;
            name_ = other.name_;
            onChanged();
          }
          if (other.hasValue()) {
            bitField0_ |= 0x00000002;
            value_ = other.value_;
            onChanged();
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (!hasName()) {
            
            return false;
          }
          if (!hasValue()) {
            
            return false;
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          cosmos.trace.Timings.TimedRegions.TimingMetadata parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (cosmos.trace.Timings.TimedRegions.TimingMetadata) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // required string name = 1;
        private java.lang.Object name_ = "";
        /**
         * <code>required string name = 1;</code>
         */
        public boolean hasName() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required string name = 1;</code>
         */
        public java.lang.String getName() {
          java.lang.Object ref = name_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string name = 1;</code>
         */
        public com.google.protobuf.ByteString
            getNameBytes() {
          java.lang.Object ref = name_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            name_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string name = 1;</code>
         */
        public Builder setName(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          name_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string name = 1;</code>
         */
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        /**
         * <code>required string name = 1;</code>
         */
        public Builder setNameBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          name_ = value;
          onChanged();
          return this;
        }

        // required string value = 2;
        private java.lang.Object value_ = "";
        /**
         * <code>required string value = 2;</code>
         */
        public boolean hasValue() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>required string value = 2;</code>
         */
        public java.lang.String getValue() {
          java.lang.Object ref = value_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            value_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string value = 2;</code>
         */
        public com.google.protobuf.ByteString
            getValueBytes() {
          java.lang.Object ref = value_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            value_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string value = 2;</code>
         */
        public Builder setValue(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          value_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string value = 2;</code>
         */
        public Builder clearValue() {
          bitField0_ = (bitField0_ & ~0x00000002);
          value_ = getDefaultInstance().getValue();
          onChanged();
          return this;
        }
        /**
         * <code>required string value = 2;</code>
         */
        public Builder setValueBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          value_ = value;
          onChanged();
          return this;
        }

        // @@protoc_insertion_point(builder_scope:cosmos.trace.TimedRegions.TimingMetadata)
      }

      static {
        defaultInstance = new TimingMetadata(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:cosmos.trace.TimedRegions.TimingMetadata)
    }

    private int bitField0_;
    // required uint64 begin = 1;
    public static final int BEGIN_FIELD_NUMBER = 1;
    private long begin_;
    /**
     * <code>required uint64 begin = 1;</code>
     */
    public boolean hasBegin() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required uint64 begin = 1;</code>
     */
    public long getBegin() {
      return begin_;
    }

    // required string uuid = 2;
    public static final int UUID_FIELD_NUMBER = 2;
    private java.lang.Object uuid_;
    /**
     * <code>required string uuid = 2;</code>
     */
    public boolean hasUuid() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>required string uuid = 2;</code>
     */
    public java.lang.String getUuid() {
      java.lang.Object ref = uuid_;
      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()) {
          uuid_ = s;
        }
        return s;
      }
    }
    /**
     * <code>required string uuid = 2;</code>
     */
    public com.google.protobuf.ByteString
        getUuidBytes() {
      java.lang.Object ref = uuid_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        uuid_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;
    public static final int METADATA_FIELD_NUMBER = 3;
    private java.util.List<cosmos.trace.Timings.TimedRegions.TimingMetadata> metadata_;
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    public java.util.List<cosmos.trace.Timings.TimedRegions.TimingMetadata> getMetadataList() {
      return metadata_;
    }
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    public java.util.List<? extends cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder> 
        getMetadataOrBuilderList() {
      return metadata_;
    }
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    public int getMetadataCount() {
      return metadata_.size();
    }
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    public cosmos.trace.Timings.TimedRegions.TimingMetadata getMetadata(int index) {
      return metadata_.get(index);
    }
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
     */
    public cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder getMetadataOrBuilder(
        int index) {
      return metadata_.get(index);
    }

    // repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;
    public static final int REGION_FIELD_NUMBER = 4;
    private java.util.List<cosmos.trace.Timings.TimedRegions.TimedRegion> region_;
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    public java.util.List<cosmos.trace.Timings.TimedRegions.TimedRegion> getRegionList() {
      return region_;
    }
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    public java.util.List<? extends cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder> 
        getRegionOrBuilderList() {
      return region_;
    }
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    public int getRegionCount() {
      return region_.size();
    }
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    public cosmos.trace.Timings.TimedRegions.TimedRegion getRegion(int index) {
      return region_.get(index);
    }
    /**
     * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
     */
    public cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder getRegionOrBuilder(
        int index) {
      return region_.get(index);
    }

    private void initFields() {
      begin_ = 0L;
      uuid_ = "";
      metadata_ = java.util.Collections.emptyList();
      region_ = java.util.Collections.emptyList();
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasBegin()) {
        memoizedIsInitialized = 0;
        return false;
      }
      if (!hasUuid()) {
        memoizedIsInitialized = 0;
        return false;
      }
      for (int i = 0; i < getMetadataCount(); i++) {
        if (!getMetadata(i).isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      for (int i = 0; i < getRegionCount(); i++) {
        if (!getRegion(i).isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeUInt64(1, begin_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeBytes(2, getUuidBytes());
      }
      for (int i = 0; i < metadata_.size(); i++) {
        output.writeMessage(3, metadata_.get(i));
      }
      for (int i = 0; i < region_.size(); i++) {
        output.writeMessage(4, region_.get(i));
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt64Size(1, begin_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(2, getUuidBytes());
      }
      for (int i = 0; i < metadata_.size(); i++) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(3, metadata_.get(i));
      }
      for (int i = 0; i < region_.size(); i++) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(4, region_.get(i));
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static cosmos.trace.Timings.TimedRegions parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static cosmos.trace.Timings.TimedRegions parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static cosmos.trace.Timings.TimedRegions parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static cosmos.trace.Timings.TimedRegions parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static cosmos.trace.Timings.TimedRegions parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static cosmos.trace.Timings.TimedRegions parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static cosmos.trace.Timings.TimedRegions parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static cosmos.trace.Timings.TimedRegions parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static cosmos.trace.Timings.TimedRegions parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static cosmos.trace.Timings.TimedRegions parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(cosmos.trace.Timings.TimedRegions prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code cosmos.trace.TimedRegions}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements cosmos.trace.Timings.TimedRegionsOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                cosmos.trace.Timings.TimedRegions.class, cosmos.trace.Timings.TimedRegions.Builder.class);
      }

      // Construct using cosmos.trace.Timings.TimedRegions.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          getMetadataFieldBuilder();
          getRegionFieldBuilder();
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        begin_ = 0L;
        bitField0_ = (bitField0_ & ~0x00000001);
        uuid_ = "";
        bitField0_ = (bitField0_ & ~0x00000002);
        if (metadataBuilder_ == null) {
          metadata_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000004);
        } else {
          metadataBuilder_.clear();
        }
        if (regionBuilder_ == null) {
          region_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000008);
        } else {
          regionBuilder_.clear();
        }
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return cosmos.trace.Timings.internal_static_cosmos_trace_TimedRegions_descriptor;
      }

      public cosmos.trace.Timings.TimedRegions getDefaultInstanceForType() {
        return cosmos.trace.Timings.TimedRegions.getDefaultInstance();
      }

      public cosmos.trace.Timings.TimedRegions build() {
        cosmos.trace.Timings.TimedRegions result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public cosmos.trace.Timings.TimedRegions buildPartial() {
        cosmos.trace.Timings.TimedRegions result = new cosmos.trace.Timings.TimedRegions(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.begin_ = begin_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.uuid_ = uuid_;
        if (metadataBuilder_ == null) {
          if (((bitField0_ & 0x00000004) == 0x00000004)) {
            metadata_ = java.util.Collections.unmodifiableList(metadata_);
            bitField0_ = (bitField0_ & ~0x00000004);
          }
          result.metadata_ = metadata_;
        } else {
          result.metadata_ = metadataBuilder_.build();
        }
        if (regionBuilder_ == null) {
          if (((bitField0_ & 0x00000008) == 0x00000008)) {
            region_ = java.util.Collections.unmodifiableList(region_);
            bitField0_ = (bitField0_ & ~0x00000008);
          }
          result.region_ = region_;
        } else {
          result.region_ = regionBuilder_.build();
        }
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof cosmos.trace.Timings.TimedRegions) {
          return mergeFrom((cosmos.trace.Timings.TimedRegions)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(cosmos.trace.Timings.TimedRegions other) {
        if (other == cosmos.trace.Timings.TimedRegions.getDefaultInstance()) return this;
        if (other.hasBegin()) {
          setBegin(other.getBegin());
        }
        if (other.hasUuid()) {
          bitField0_ |= 0x00000002;
          uuid_ = other.uuid_;
          onChanged();
        }
        if (metadataBuilder_ == null) {
          if (!other.metadata_.isEmpty()) {
            if (metadata_.isEmpty()) {
              metadata_ = other.metadata_;
              bitField0_ = (bitField0_ & ~0x00000004);
            } else {
              ensureMetadataIsMutable();
              metadata_.addAll(other.metadata_);
            }
            onChanged();
          }
        } else {
          if (!other.metadata_.isEmpty()) {
            if (metadataBuilder_.isEmpty()) {
              metadataBuilder_.dispose();
              metadataBuilder_ = null;
              metadata_ = other.metadata_;
              bitField0_ = (bitField0_ & ~0x00000004);
              metadataBuilder_ = 
                com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                   getMetadataFieldBuilder() : null;
            } else {
              metadataBuilder_.addAllMessages(other.metadata_);
            }
          }
        }
        if (regionBuilder_ == null) {
          if (!other.region_.isEmpty()) {
            if (region_.isEmpty()) {
              region_ = other.region_;
              bitField0_ = (bitField0_ & ~0x00000008);
            } else {
              ensureRegionIsMutable();
              region_.addAll(other.region_);
            }
            onChanged();
          }
        } else {
          if (!other.region_.isEmpty()) {
            if (regionBuilder_.isEmpty()) {
              regionBuilder_.dispose();
              regionBuilder_ = null;
              region_ = other.region_;
              bitField0_ = (bitField0_ & ~0x00000008);
              regionBuilder_ = 
                com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                   getRegionFieldBuilder() : null;
            } else {
              regionBuilder_.addAllMessages(other.region_);
            }
          }
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasBegin()) {
          
          return false;
        }
        if (!hasUuid()) {
          
          return false;
        }
        for (int i = 0; i < getMetadataCount(); i++) {
          if (!getMetadata(i).isInitialized()) {
            
            return false;
          }
        }
        for (int i = 0; i < getRegionCount(); i++) {
          if (!getRegion(i).isInitialized()) {
            
            return false;
          }
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        cosmos.trace.Timings.TimedRegions parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (cosmos.trace.Timings.TimedRegions) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required uint64 begin = 1;
      private long begin_ ;
      /**
       * <code>required uint64 begin = 1;</code>
       */
      public boolean hasBegin() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required uint64 begin = 1;</code>
       */
      public long getBegin() {
        return begin_;
      }
      /**
       * <code>required uint64 begin = 1;</code>
       */
      public Builder setBegin(long value) {
        bitField0_ |= 0x00000001;
        begin_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required uint64 begin = 1;</code>
       */
      public Builder clearBegin() {
        bitField0_ = (bitField0_ & ~0x00000001);
        begin_ = 0L;
        onChanged();
        return this;
      }

      // required string uuid = 2;
      private java.lang.Object uuid_ = "";
      /**
       * <code>required string uuid = 2;</code>
       */
      public boolean hasUuid() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required string uuid = 2;</code>
       */
      public java.lang.String getUuid() {
        java.lang.Object ref = uuid_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          uuid_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>required string uuid = 2;</code>
       */
      public com.google.protobuf.ByteString
          getUuidBytes() {
        java.lang.Object ref = uuid_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          uuid_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>required string uuid = 2;</code>
       */
      public Builder setUuid(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        uuid_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required string uuid = 2;</code>
       */
      public Builder clearUuid() {
        bitField0_ = (bitField0_ & ~0x00000002);
        uuid_ = getDefaultInstance().getUuid();
        onChanged();
        return this;
      }
      /**
       * <code>required string uuid = 2;</code>
       */
      public Builder setUuidBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        uuid_ = value;
        onChanged();
        return this;
      }

      // repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;
      private java.util.List<cosmos.trace.Timings.TimedRegions.TimingMetadata> metadata_ =
        java.util.Collections.emptyList();
      private void ensureMetadataIsMutable() {
        if (!((bitField0_ & 0x00000004) == 0x00000004)) {
          metadata_ = new java.util.ArrayList<cosmos.trace.Timings.TimedRegions.TimingMetadata>(metadata_);
          bitField0_ |= 0x00000004;
         }
      }

      private com.google.protobuf.RepeatedFieldBuilder<
          cosmos.trace.Timings.TimedRegions.TimingMetadata, cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder, cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder> metadataBuilder_;

      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public java.util.List<cosmos.trace.Timings.TimedRegions.TimingMetadata> getMetadataList() {
        if (metadataBuilder_ == null) {
          return java.util.Collections.unmodifiableList(metadata_);
        } else {
          return metadataBuilder_.getMessageList();
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public int getMetadataCount() {
        if (metadataBuilder_ == null) {
          return metadata_.size();
        } else {
          return metadataBuilder_.getCount();
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimingMetadata getMetadata(int index) {
        if (metadataBuilder_ == null) {
          return metadata_.get(index);
        } else {
          return metadataBuilder_.getMessage(index);
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder setMetadata(
          int index, cosmos.trace.Timings.TimedRegions.TimingMetadata value) {
        if (metadataBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureMetadataIsMutable();
          metadata_.set(index, value);
          onChanged();
        } else {
          metadataBuilder_.setMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder setMetadata(
          int index, cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder builderForValue) {
        if (metadataBuilder_ == null) {
          ensureMetadataIsMutable();
          metadata_.set(index, builderForValue.build());
          onChanged();
        } else {
          metadataBuilder_.setMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder addMetadata(cosmos.trace.Timings.TimedRegions.TimingMetadata value) {
        if (metadataBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureMetadataIsMutable();
          metadata_.add(value);
          onChanged();
        } else {
          metadataBuilder_.addMessage(value);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder addMetadata(
          int index, cosmos.trace.Timings.TimedRegions.TimingMetadata value) {
        if (metadataBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureMetadataIsMutable();
          metadata_.add(index, value);
          onChanged();
        } else {
          metadataBuilder_.addMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder addMetadata(
          cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder builderForValue) {
        if (metadataBuilder_ == null) {
          ensureMetadataIsMutable();
          metadata_.add(builderForValue.build());
          onChanged();
        } else {
          metadataBuilder_.addMessage(builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder addMetadata(
          int index, cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder builderForValue) {
        if (metadataBuilder_ == null) {
          ensureMetadataIsMutable();
          metadata_.add(index, builderForValue.build());
          onChanged();
        } else {
          metadataBuilder_.addMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder addAllMetadata(
          java.lang.Iterable<? extends cosmos.trace.Timings.TimedRegions.TimingMetadata> values) {
        if (metadataBuilder_ == null) {
          ensureMetadataIsMutable();
          super.addAll(values, metadata_);
          onChanged();
        } else {
          metadataBuilder_.addAllMessages(values);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder clearMetadata() {
        if (metadataBuilder_ == null) {
          metadata_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000004);
          onChanged();
        } else {
          metadataBuilder_.clear();
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public Builder removeMetadata(int index) {
        if (metadataBuilder_ == null) {
          ensureMetadataIsMutable();
          metadata_.remove(index);
          onChanged();
        } else {
          metadataBuilder_.remove(index);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder getMetadataBuilder(
          int index) {
        return getMetadataFieldBuilder().getBuilder(index);
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder getMetadataOrBuilder(
          int index) {
        if (metadataBuilder_ == null) {
          return metadata_.get(index);  } else {
          return metadataBuilder_.getMessageOrBuilder(index);
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public java.util.List<? extends cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder> 
           getMetadataOrBuilderList() {
        if (metadataBuilder_ != null) {
          return metadataBuilder_.getMessageOrBuilderList();
        } else {
          return java.util.Collections.unmodifiableList(metadata_);
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder addMetadataBuilder() {
        return getMetadataFieldBuilder().addBuilder(
            cosmos.trace.Timings.TimedRegions.TimingMetadata.getDefaultInstance());
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder addMetadataBuilder(
          int index) {
        return getMetadataFieldBuilder().addBuilder(
            index, cosmos.trace.Timings.TimedRegions.TimingMetadata.getDefaultInstance());
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimingMetadata metadata = 3;</code>
       */
      public java.util.List<cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder> 
           getMetadataBuilderList() {
        return getMetadataFieldBuilder().getBuilderList();
      }
      private com.google.protobuf.RepeatedFieldBuilder<
          cosmos.trace.Timings.TimedRegions.TimingMetadata, cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder, cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder> 
          getMetadataFieldBuilder() {
        if (metadataBuilder_ == null) {
          metadataBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
              cosmos.trace.Timings.TimedRegions.TimingMetadata, cosmos.trace.Timings.TimedRegions.TimingMetadata.Builder, cosmos.trace.Timings.TimedRegions.TimingMetadataOrBuilder>(
                  metadata_,
                  ((bitField0_ & 0x00000004) == 0x00000004),
                  getParentForChildren(),
                  isClean());
          metadata_ = null;
        }
        return metadataBuilder_;
      }

      // repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;
      private java.util.List<cosmos.trace.Timings.TimedRegions.TimedRegion> region_ =
        java.util.Collections.emptyList();
      private void ensureRegionIsMutable() {
        if (!((bitField0_ & 0x00000008) == 0x00000008)) {
          region_ = new java.util.ArrayList<cosmos.trace.Timings.TimedRegions.TimedRegion>(region_);
          bitField0_ |= 0x00000008;
         }
      }

      private com.google.protobuf.RepeatedFieldBuilder<
          cosmos.trace.Timings.TimedRegions.TimedRegion, cosmos.trace.Timings.TimedRegions.TimedRegion.Builder, cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder> regionBuilder_;

      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public java.util.List<cosmos.trace.Timings.TimedRegions.TimedRegion> getRegionList() {
        if (regionBuilder_ == null) {
          return java.util.Collections.unmodifiableList(region_);
        } else {
          return regionBuilder_.getMessageList();
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public int getRegionCount() {
        if (regionBuilder_ == null) {
          return region_.size();
        } else {
          return regionBuilder_.getCount();
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimedRegion getRegion(int index) {
        if (regionBuilder_ == null) {
          return region_.get(index);
        } else {
          return regionBuilder_.getMessage(index);
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder setRegion(
          int index, cosmos.trace.Timings.TimedRegions.TimedRegion value) {
        if (regionBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureRegionIsMutable();
          region_.set(index, value);
          onChanged();
        } else {
          regionBuilder_.setMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder setRegion(
          int index, cosmos.trace.Timings.TimedRegions.TimedRegion.Builder builderForValue) {
        if (regionBuilder_ == null) {
          ensureRegionIsMutable();
          region_.set(index, builderForValue.build());
          onChanged();
        } else {
          regionBuilder_.setMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder addRegion(cosmos.trace.Timings.TimedRegions.TimedRegion value) {
        if (regionBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureRegionIsMutable();
          region_.add(value);
          onChanged();
        } else {
          regionBuilder_.addMessage(value);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder addRegion(
          int index, cosmos.trace.Timings.TimedRegions.TimedRegion value) {
        if (regionBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureRegionIsMutable();
          region_.add(index, value);
          onChanged();
        } else {
          regionBuilder_.addMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder addRegion(
          cosmos.trace.Timings.TimedRegions.TimedRegion.Builder builderForValue) {
        if (regionBuilder_ == null) {
          ensureRegionIsMutable();
          region_.add(builderForValue.build());
          onChanged();
        } else {
          regionBuilder_.addMessage(builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder addRegion(
          int index, cosmos.trace.Timings.TimedRegions.TimedRegion.Builder builderForValue) {
        if (regionBuilder_ == null) {
          ensureRegionIsMutable();
          region_.add(index, builderForValue.build());
          onChanged();
        } else {
          regionBuilder_.addMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder addAllRegion(
          java.lang.Iterable<? extends cosmos.trace.Timings.TimedRegions.TimedRegion> values) {
        if (regionBuilder_ == null) {
          ensureRegionIsMutable();
          super.addAll(values, region_);
          onChanged();
        } else {
          regionBuilder_.addAllMessages(values);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder clearRegion() {
        if (regionBuilder_ == null) {
          region_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000008);
          onChanged();
        } else {
          regionBuilder_.clear();
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public Builder removeRegion(int index) {
        if (regionBuilder_ == null) {
          ensureRegionIsMutable();
          region_.remove(index);
          onChanged();
        } else {
          regionBuilder_.remove(index);
        }
        return this;
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimedRegion.Builder getRegionBuilder(
          int index) {
        return getRegionFieldBuilder().getBuilder(index);
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder getRegionOrBuilder(
          int index) {
        if (regionBuilder_ == null) {
          return region_.get(index);  } else {
          return regionBuilder_.getMessageOrBuilder(index);
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public java.util.List<? extends cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder> 
           getRegionOrBuilderList() {
        if (regionBuilder_ != null) {
          return regionBuilder_.getMessageOrBuilderList();
        } else {
          return java.util.Collections.unmodifiableList(region_);
        }
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimedRegion.Builder addRegionBuilder() {
        return getRegionFieldBuilder().addBuilder(
            cosmos.trace.Timings.TimedRegions.TimedRegion.getDefaultInstance());
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public cosmos.trace.Timings.TimedRegions.TimedRegion.Builder addRegionBuilder(
          int index) {
        return getRegionFieldBuilder().addBuilder(
            index, cosmos.trace.Timings.TimedRegions.TimedRegion.getDefaultInstance());
      }
      /**
       * <code>repeated .cosmos.trace.TimedRegions.TimedRegion region = 4;</code>
       */
      public java.util.List<cosmos.trace.Timings.TimedRegions.TimedRegion.Builder> 
           getRegionBuilderList() {
        return getRegionFieldBuilder().getBuilderList();
      }
      private com.google.protobuf.RepeatedFieldBuilder<
          cosmos.trace.Timings.TimedRegions.TimedRegion, cosmos.trace.Timings.TimedRegions.TimedRegion.Builder, cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder> 
          getRegionFieldBuilder() {
        if (regionBuilder_ == null) {
          regionBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
              cosmos.trace.Timings.TimedRegions.TimedRegion, cosmos.trace.Timings.TimedRegions.TimedRegion.Builder, cosmos.trace.Timings.TimedRegions.TimedRegionOrBuilder>(
                  region_,
                  ((bitField0_ & 0x00000008) == 0x00000008),
                  getParentForChildren(),
                  isClean());
          region_ = null;
        }
        return regionBuilder_;
      }

      // @@protoc_insertion_point(builder_scope:cosmos.trace.TimedRegions)
    }

    static {
      defaultInstance = new TimedRegions(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:cosmos.trace.TimedRegions)
  }

  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_cosmos_trace_TimedRegions_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_cosmos_trace_TimedRegions_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_cosmos_trace_TimedRegions_TimedRegion_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_cosmos_trace_TimedRegions_TimedRegion_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_cosmos_trace_TimedRegions_TimingMetadata_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_cosmos_trace_TimedRegions_TimingMetadata_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\021timedregion.proto\022\014cosmos.trace\"\205\002\n\014Ti" +
      "medRegions\022\r\n\005begin\030\001 \002(\004\022\014\n\004uuid\030\002 \002(\t\022" +
      ";\n\010metadata\030\003 \003(\0132).cosmos.trace.TimedRe" +
      "gions.TimingMetadata\0226\n\006region\030\004 \003(\0132&.c" +
      "osmos.trace.TimedRegions.TimedRegion\0324\n\013" +
      "TimedRegion\022\023\n\013description\030\001 \002(\t\022\020\n\010dura" +
      "tion\030\002 \002(\004\032-\n\016TimingMetadata\022\014\n\004name\030\001 \002" +
      "(\t\022\r\n\005value\030\002 \002(\tB\013B\007TimingsH\001"
    };
    com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
      new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
        public com.google.protobuf.ExtensionRegistry assignDescriptors(
            com.google.protobuf.Descriptors.FileDescriptor root) {
          descriptor = root;
          internal_static_cosmos_trace_TimedRegions_descriptor =
            getDescriptor().getMessageTypes().get(0);
          internal_static_cosmos_trace_TimedRegions_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_cosmos_trace_TimedRegions_descriptor,
              new java.lang.String[] { "Begin", "Uuid", "Metadata", "Region", });
          internal_static_cosmos_trace_TimedRegions_TimedRegion_descriptor =
            internal_static_cosmos_trace_TimedRegions_descriptor.getNestedTypes().get(0);
          internal_static_cosmos_trace_TimedRegions_TimedRegion_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_cosmos_trace_TimedRegions_TimedRegion_descriptor,
              new java.lang.String[] { "Description", "Duration", });
          internal_static_cosmos_trace_TimedRegions_TimingMetadata_descriptor =
            internal_static_cosmos_trace_TimedRegions_descriptor.getNestedTypes().get(1);
          internal_static_cosmos_trace_TimedRegions_TimingMetadata_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_cosmos_trace_TimedRegions_TimingMetadata_descriptor,
              new java.lang.String[] { "Name", "Value", });
          return null;
        }
      };
    com.google.protobuf.Descriptors.FileDescriptor
      .internalBuildGeneratedFileFrom(descriptorData,
        new com.google.protobuf.Descriptors.FileDescriptor[] {
        }, assigner);
  }

  // @@protoc_insertion_point(outer_class_scope)
}
