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

de.tum.cit.ase.athena.protobuf.Segment Maven / Gradle / Ivy

The newest version!
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: clustering.proto

package de.tum.cit.ase.athena.protobuf;

/**
 * Protobuf type {@code Segment}
 */
public final class Segment extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:Segment)
    SegmentOrBuilder {
private static final long serialVersionUID = 0L;
  // Use Segment.newBuilder() to construct.
  private Segment(com.google.protobuf.GeneratedMessageV3.Builder builder) {
    super(builder);
  }
  private Segment() {
    id_ = "";
    text_ = "";
  }

  @java.lang.Override
  @SuppressWarnings({"unused"})
  protected java.lang.Object newInstance(
      UnusedPrivateParameter unused) {
    return new Segment();
  }

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return de.tum.cit.ase.athena.protobuf.Clustering.internal_static_Segment_descriptor;
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return de.tum.cit.ase.athena.protobuf.Clustering.internal_static_Segment_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            de.tum.cit.ase.athena.protobuf.Segment.class, de.tum.cit.ase.athena.protobuf.Segment.Builder.class);
  }

  private int bitField0_;
  public static final int ID_FIELD_NUMBER = 1;
  private volatile java.lang.Object id_;
  /**
   * string id = 1;
   * @return The id.
   */
  @java.lang.Override
  public java.lang.String getId() {
    java.lang.Object ref = id_;
    if (ref instanceof java.lang.String) {
      return (java.lang.String) ref;
    } else {
      com.google.protobuf.ByteString bs = 
          (com.google.protobuf.ByteString) ref;
      java.lang.String s = bs.toStringUtf8();
      id_ = s;
      return s;
    }
  }
  /**
   * string id = 1;
   * @return The bytes for id.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getIdBytes() {
    java.lang.Object ref = id_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      id_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int SUBMISSIONID_FIELD_NUMBER = 2;
  private int submissionId_;
  /**
   * optional int32 submissionId = 2;
   * @return Whether the submissionId field is set.
   */
  @java.lang.Override
  public boolean hasSubmissionId() {
    return ((bitField0_ & 0x00000001) != 0);
  }
  /**
   * optional int32 submissionId = 2;
   * @return The submissionId.
   */
  @java.lang.Override
  public int getSubmissionId() {
    return submissionId_;
  }

  public static final int TEXT_FIELD_NUMBER = 3;
  private volatile java.lang.Object text_;
  /**
   * optional string text = 3;
   * @return Whether the text field is set.
   */
  @java.lang.Override
  public boolean hasText() {
    return ((bitField0_ & 0x00000002) != 0);
  }
  /**
   * optional string text = 3;
   * @return The text.
   */
  @java.lang.Override
  public java.lang.String getText() {
    java.lang.Object ref = text_;
    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();
      text_ = s;
      return s;
    }
  }
  /**
   * optional string text = 3;
   * @return The bytes for text.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getTextBytes() {
    java.lang.Object ref = text_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      text_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int STARTINDEX_FIELD_NUMBER = 4;
  private int startIndex_;
  /**
   * optional int32 startIndex = 4;
   * @return Whether the startIndex field is set.
   */
  @java.lang.Override
  public boolean hasStartIndex() {
    return ((bitField0_ & 0x00000004) != 0);
  }
  /**
   * optional int32 startIndex = 4;
   * @return The startIndex.
   */
  @java.lang.Override
  public int getStartIndex() {
    return startIndex_;
  }

  public static final int ENDINDEX_FIELD_NUMBER = 5;
  private int endIndex_;
  /**
   * optional int32 endIndex = 5;
   * @return Whether the endIndex field is set.
   */
  @java.lang.Override
  public boolean hasEndIndex() {
    return ((bitField0_ & 0x00000008) != 0);
  }
  /**
   * optional int32 endIndex = 5;
   * @return The endIndex.
   */
  @java.lang.Override
  public int getEndIndex() {
    return endIndex_;
  }

  private byte memoizedIsInitialized = -1;
  @java.lang.Override
  public final boolean isInitialized() {
    byte isInitialized = memoizedIsInitialized;
    if (isInitialized == 1) return true;
    if (isInitialized == 0) return false;

    memoizedIsInitialized = 1;
    return true;
  }

  @java.lang.Override
  public void writeTo(com.google.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_);
    }
    if (((bitField0_ & 0x00000001) != 0)) {
      output.writeInt32(2, submissionId_);
    }
    if (((bitField0_ & 0x00000002) != 0)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 3, text_);
    }
    if (((bitField0_ & 0x00000004) != 0)) {
      output.writeInt32(4, startIndex_);
    }
    if (((bitField0_ & 0x00000008) != 0)) {
      output.writeInt32(5, endIndex_);
    }
    getUnknownFields().writeTo(output);
  }

  @java.lang.Override
  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_);
    }
    if (((bitField0_ & 0x00000001) != 0)) {
      size += com.google.protobuf.CodedOutputStream
        .computeInt32Size(2, submissionId_);
    }
    if (((bitField0_ & 0x00000002) != 0)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, text_);
    }
    if (((bitField0_ & 0x00000004) != 0)) {
      size += com.google.protobuf.CodedOutputStream
        .computeInt32Size(4, startIndex_);
    }
    if (((bitField0_ & 0x00000008) != 0)) {
      size += com.google.protobuf.CodedOutputStream
        .computeInt32Size(5, endIndex_);
    }
    size += getUnknownFields().getSerializedSize();
    memoizedSize = size;
    return size;
  }

  @java.lang.Override
  public boolean equals(final java.lang.Object obj) {
    if (obj == this) {
     return true;
    }
    if (!(obj instanceof de.tum.cit.ase.athena.protobuf.Segment)) {
      return super.equals(obj);
    }
    de.tum.cit.ase.athena.protobuf.Segment other = (de.tum.cit.ase.athena.protobuf.Segment) obj;

    if (!getId()
        .equals(other.getId())) return false;
    if (hasSubmissionId() != other.hasSubmissionId()) return false;
    if (hasSubmissionId()) {
      if (getSubmissionId()
          != other.getSubmissionId()) return false;
    }
    if (hasText() != other.hasText()) return false;
    if (hasText()) {
      if (!getText()
          .equals(other.getText())) return false;
    }
    if (hasStartIndex() != other.hasStartIndex()) return false;
    if (hasStartIndex()) {
      if (getStartIndex()
          != other.getStartIndex()) return false;
    }
    if (hasEndIndex() != other.hasEndIndex()) return false;
    if (hasEndIndex()) {
      if (getEndIndex()
          != other.getEndIndex()) return false;
    }
    if (!getUnknownFields().equals(other.getUnknownFields())) return false;
    return true;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptor().hashCode();
    hash = (37 * hash) + ID_FIELD_NUMBER;
    hash = (53 * hash) + getId().hashCode();
    if (hasSubmissionId()) {
      hash = (37 * hash) + SUBMISSIONID_FIELD_NUMBER;
      hash = (53 * hash) + getSubmissionId();
    }
    if (hasText()) {
      hash = (37 * hash) + TEXT_FIELD_NUMBER;
      hash = (53 * hash) + getText().hashCode();
    }
    if (hasStartIndex()) {
      hash = (37 * hash) + STARTINDEX_FIELD_NUMBER;
      hash = (53 * hash) + getStartIndex();
    }
    if (hasEndIndex()) {
      hash = (37 * hash) + ENDINDEX_FIELD_NUMBER;
      hash = (53 * hash) + getEndIndex();
    }
    hash = (29 * hash) + getUnknownFields().hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseDelimitedFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static de.tum.cit.ase.athena.protobuf.Segment parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  @java.lang.Override
  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(de.tum.cit.ase.athena.protobuf.Segment prototype) {
    return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
  }
  @java.lang.Override
  public Builder toBuilder() {
    return this == DEFAULT_INSTANCE
        ? new Builder() : new Builder().mergeFrom(this);
  }

  @java.lang.Override
  protected Builder newBuilderForType(
      com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * Protobuf type {@code Segment}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder implements
      // @@protoc_insertion_point(builder_implements:Segment)
      de.tum.cit.ase.athena.protobuf.SegmentOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return de.tum.cit.ase.athena.protobuf.Clustering.internal_static_Segment_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return de.tum.cit.ase.athena.protobuf.Clustering.internal_static_Segment_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              de.tum.cit.ase.athena.protobuf.Segment.class, de.tum.cit.ase.athena.protobuf.Segment.Builder.class);
    }

    // Construct using de.tum.cit.ase.athena.protobuf.Segment.newBuilder()
    private Builder() {

    }

    private Builder(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);

    }
    @java.lang.Override
    public Builder clear() {
      super.clear();
      id_ = "";

      submissionId_ = 0;
      bitField0_ = (bitField0_ & ~0x00000001);
      text_ = "";
      bitField0_ = (bitField0_ & ~0x00000002);
      startIndex_ = 0;
      bitField0_ = (bitField0_ & ~0x00000004);
      endIndex_ = 0;
      bitField0_ = (bitField0_ & ~0x00000008);
      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return de.tum.cit.ase.athena.protobuf.Clustering.internal_static_Segment_descriptor;
    }

    @java.lang.Override
    public de.tum.cit.ase.athena.protobuf.Segment getDefaultInstanceForType() {
      return de.tum.cit.ase.athena.protobuf.Segment.getDefaultInstance();
    }

    @java.lang.Override
    public de.tum.cit.ase.athena.protobuf.Segment build() {
      de.tum.cit.ase.athena.protobuf.Segment result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public de.tum.cit.ase.athena.protobuf.Segment buildPartial() {
      de.tum.cit.ase.athena.protobuf.Segment result = new de.tum.cit.ase.athena.protobuf.Segment(this);
      int from_bitField0_ = bitField0_;
      int to_bitField0_ = 0;
      result.id_ = id_;
      if (((from_bitField0_ & 0x00000001) != 0)) {
        result.submissionId_ = submissionId_;
        to_bitField0_ |= 0x00000001;
      }
      if (((from_bitField0_ & 0x00000002) != 0)) {
        to_bitField0_ |= 0x00000002;
      }
      result.text_ = text_;
      if (((from_bitField0_ & 0x00000004) != 0)) {
        result.startIndex_ = startIndex_;
        to_bitField0_ |= 0x00000004;
      }
      if (((from_bitField0_ & 0x00000008) != 0)) {
        result.endIndex_ = endIndex_;
        to_bitField0_ |= 0x00000008;
      }
      result.bitField0_ = to_bitField0_;
      onBuilt();
      return result;
    }

    @java.lang.Override
    public Builder clone() {
      return super.clone();
    }
    @java.lang.Override
    public Builder setField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.setField(field, value);
    }
    @java.lang.Override
    public Builder clearField(
        com.google.protobuf.Descriptors.FieldDescriptor field) {
      return super.clearField(field);
    }
    @java.lang.Override
    public Builder clearOneof(
        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
      return super.clearOneof(oneof);
    }
    @java.lang.Override
    public Builder setRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        int index, java.lang.Object value) {
      return super.setRepeatedField(field, index, value);
    }
    @java.lang.Override
    public Builder addRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.addRepeatedField(field, value);
    }
    @java.lang.Override
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof de.tum.cit.ase.athena.protobuf.Segment) {
        return mergeFrom((de.tum.cit.ase.athena.protobuf.Segment)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(de.tum.cit.ase.athena.protobuf.Segment other) {
      if (other == de.tum.cit.ase.athena.protobuf.Segment.getDefaultInstance()) return this;
      if (!other.getId().isEmpty()) {
        id_ = other.id_;
        onChanged();
      }
      if (other.hasSubmissionId()) {
        setSubmissionId(other.getSubmissionId());
      }
      if (other.hasText()) {
        bitField0_ |= 0x00000002;
        text_ = other.text_;
        onChanged();
      }
      if (other.hasStartIndex()) {
        setStartIndex(other.getStartIndex());
      }
      if (other.hasEndIndex()) {
        setEndIndex(other.getEndIndex());
      }
      this.mergeUnknownFields(other.getUnknownFields());
      onChanged();
      return this;
    }

    @java.lang.Override
    public final boolean isInitialized() {
      return true;
    }

    @java.lang.Override
    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            case 10: {
              id_ = input.readStringRequireUtf8();

              break;
            } // case 10
            case 16: {
              submissionId_ = input.readInt32();
              bitField0_ |= 0x00000001;
              break;
            } // case 16
            case 26: {
              text_ = input.readStringRequireUtf8();
              bitField0_ |= 0x00000002;
              break;
            } // case 26
            case 32: {
              startIndex_ = input.readInt32();
              bitField0_ |= 0x00000004;
              break;
            } // case 32
            case 40: {
              endIndex_ = input.readInt32();
              bitField0_ |= 0x00000008;
              break;
            } // case 40
            default: {
              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
                done = true; // was an endgroup tag
              }
              break;
            } // default:
          } // switch (tag)
        } // while (!done)
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.unwrapIOException();
      } finally {
        onChanged();
      } // finally
      return this;
    }
    private int bitField0_;

    private java.lang.Object id_ = "";
    /**
     * string id = 1;
     * @return The id.
     */
    public java.lang.String getId() {
      java.lang.Object ref = id_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        id_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * string id = 1;
     * @return The bytes for id.
     */
    public com.google.protobuf.ByteString
        getIdBytes() {
      java.lang.Object ref = id_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        id_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * string id = 1;
     * @param value The id to set.
     * @return This builder for chaining.
     */
    public Builder setId(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      id_ = value;
      onChanged();
      return this;
    }
    /**
     * string id = 1;
     * @return This builder for chaining.
     */
    public Builder clearId() {
      
      id_ = getDefaultInstance().getId();
      onChanged();
      return this;
    }
    /**
     * string id = 1;
     * @param value The bytes for id to set.
     * @return This builder for chaining.
     */
    public Builder setIdBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      id_ = value;
      onChanged();
      return this;
    }

    private int submissionId_ ;
    /**
     * optional int32 submissionId = 2;
     * @return Whether the submissionId field is set.
     */
    @java.lang.Override
    public boolean hasSubmissionId() {
      return ((bitField0_ & 0x00000001) != 0);
    }
    /**
     * optional int32 submissionId = 2;
     * @return The submissionId.
     */
    @java.lang.Override
    public int getSubmissionId() {
      return submissionId_;
    }
    /**
     * optional int32 submissionId = 2;
     * @param value The submissionId to set.
     * @return This builder for chaining.
     */
    public Builder setSubmissionId(int value) {
      bitField0_ |= 0x00000001;
      submissionId_ = value;
      onChanged();
      return this;
    }
    /**
     * optional int32 submissionId = 2;
     * @return This builder for chaining.
     */
    public Builder clearSubmissionId() {
      bitField0_ = (bitField0_ & ~0x00000001);
      submissionId_ = 0;
      onChanged();
      return this;
    }

    private java.lang.Object text_ = "";
    /**
     * optional string text = 3;
     * @return Whether the text field is set.
     */
    public boolean hasText() {
      return ((bitField0_ & 0x00000002) != 0);
    }
    /**
     * optional string text = 3;
     * @return The text.
     */
    public java.lang.String getText() {
      java.lang.Object ref = text_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        text_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * optional string text = 3;
     * @return The bytes for text.
     */
    public com.google.protobuf.ByteString
        getTextBytes() {
      java.lang.Object ref = text_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        text_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * optional string text = 3;
     * @param value The text to set.
     * @return This builder for chaining.
     */
    public Builder setText(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
      text_ = value;
      onChanged();
      return this;
    }
    /**
     * optional string text = 3;
     * @return This builder for chaining.
     */
    public Builder clearText() {
      bitField0_ = (bitField0_ & ~0x00000002);
      text_ = getDefaultInstance().getText();
      onChanged();
      return this;
    }
    /**
     * optional string text = 3;
     * @param value The bytes for text to set.
     * @return This builder for chaining.
     */
    public Builder setTextBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      bitField0_ |= 0x00000002;
      text_ = value;
      onChanged();
      return this;
    }

    private int startIndex_ ;
    /**
     * optional int32 startIndex = 4;
     * @return Whether the startIndex field is set.
     */
    @java.lang.Override
    public boolean hasStartIndex() {
      return ((bitField0_ & 0x00000004) != 0);
    }
    /**
     * optional int32 startIndex = 4;
     * @return The startIndex.
     */
    @java.lang.Override
    public int getStartIndex() {
      return startIndex_;
    }
    /**
     * optional int32 startIndex = 4;
     * @param value The startIndex to set.
     * @return This builder for chaining.
     */
    public Builder setStartIndex(int value) {
      bitField0_ |= 0x00000004;
      startIndex_ = value;
      onChanged();
      return this;
    }
    /**
     * optional int32 startIndex = 4;
     * @return This builder for chaining.
     */
    public Builder clearStartIndex() {
      bitField0_ = (bitField0_ & ~0x00000004);
      startIndex_ = 0;
      onChanged();
      return this;
    }

    private int endIndex_ ;
    /**
     * optional int32 endIndex = 5;
     * @return Whether the endIndex field is set.
     */
    @java.lang.Override
    public boolean hasEndIndex() {
      return ((bitField0_ & 0x00000008) != 0);
    }
    /**
     * optional int32 endIndex = 5;
     * @return The endIndex.
     */
    @java.lang.Override
    public int getEndIndex() {
      return endIndex_;
    }
    /**
     * optional int32 endIndex = 5;
     * @param value The endIndex to set.
     * @return This builder for chaining.
     */
    public Builder setEndIndex(int value) {
      bitField0_ |= 0x00000008;
      endIndex_ = value;
      onChanged();
      return this;
    }
    /**
     * optional int32 endIndex = 5;
     * @return This builder for chaining.
     */
    public Builder clearEndIndex() {
      bitField0_ = (bitField0_ & ~0x00000008);
      endIndex_ = 0;
      onChanged();
      return this;
    }
    @java.lang.Override
    public final Builder setUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFields(unknownFields);
    }

    @java.lang.Override
    public final Builder mergeUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.mergeUnknownFields(unknownFields);
    }


    // @@protoc_insertion_point(builder_scope:Segment)
  }

  // @@protoc_insertion_point(class_scope:Segment)
  private static final de.tum.cit.ase.athena.protobuf.Segment DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new de.tum.cit.ase.athena.protobuf.Segment();
  }

  public static de.tum.cit.ase.athena.protobuf.Segment getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser
      PARSER = new com.google.protobuf.AbstractParser() {
    @java.lang.Override
    public Segment parsePartialFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      Builder builder = newBuilder();
      try {
        builder.mergeFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(builder.buildPartial());
      } catch (com.google.protobuf.UninitializedMessageException e) {
        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(e)
            .setUnfinishedMessage(builder.buildPartial());
      }
      return builder.buildPartial();
    }
  };

  public static com.google.protobuf.Parser parser() {
    return PARSER;
  }

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

  @java.lang.Override
  public de.tum.cit.ase.athena.protobuf.Segment getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy