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

apache.rocketmq.v1.NotifyClientTerminationRequest Maven / Gradle / Ivy

There is a newer version: 2.0.7.Final
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: apache/rocketmq/v1/service.proto

package apache.rocketmq.v1;

/**
 * Protobuf type {@code apache.rocketmq.v1.NotifyClientTerminationRequest}
 */
public final class NotifyClientTerminationRequest extends
    com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:apache.rocketmq.v1.NotifyClientTerminationRequest)
    NotifyClientTerminationRequestOrBuilder {
private static final long serialVersionUID = 0L;
  // Use NotifyClientTerminationRequest.newBuilder() to construct.
  private NotifyClientTerminationRequest(com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3.Builder builder) {
    super(builder);
  }
  private NotifyClientTerminationRequest() {
    clientId_ = "";
  }

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

  @java.lang.Override
  public final com.aliyun.openservices.ons.shaded.com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  private NotifyClientTerminationRequest(
      com.aliyun.openservices.ons.shaded.com.google.protobuf.CodedInputStream input,
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException {
    this();
    if (extensionRegistry == null) {
      throw new java.lang.NullPointerException();
    }
    com.aliyun.openservices.ons.shaded.com.google.protobuf.UnknownFieldSet.Builder unknownFields =
        com.aliyun.openservices.ons.shaded.com.google.protobuf.UnknownFieldSet.newBuilder();
    try {
      boolean done = false;
      while (!done) {
        int tag = input.readTag();
        switch (tag) {
          case 0:
            done = true;
            break;
          case 10: {
            apache.rocketmq.v1.Resource.Builder subBuilder = null;
            if (groupCase_ == 1) {
              subBuilder = ((apache.rocketmq.v1.Resource) group_).toBuilder();
            }
            group_ =
                input.readMessage(apache.rocketmq.v1.Resource.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom((apache.rocketmq.v1.Resource) group_);
              group_ = subBuilder.buildPartial();
            }
            groupCase_ = 1;
            break;
          }
          case 18: {
            apache.rocketmq.v1.Resource.Builder subBuilder = null;
            if (groupCase_ == 2) {
              subBuilder = ((apache.rocketmq.v1.Resource) group_).toBuilder();
            }
            group_ =
                input.readMessage(apache.rocketmq.v1.Resource.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom((apache.rocketmq.v1.Resource) group_);
              group_ = subBuilder.buildPartial();
            }
            groupCase_ = 2;
            break;
          }
          case 26: {
            java.lang.String s = input.readStringRequireUtf8();

            clientId_ = s;
            break;
          }
          default: {
            if (!parseUnknownField(
                input, unknownFields, extensionRegistry, tag)) {
              done = true;
            }
            break;
          }
        }
      }
    } catch (com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException e) {
      throw e.setUnfinishedMessage(this);
    } catch (java.io.IOException e) {
      throw new com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException(
          e).setUnfinishedMessage(this);
    } finally {
      this.unknownFields = unknownFields.build();
      makeExtensionsImmutable();
    }
  }
  public static final com.aliyun.openservices.ons.shaded.com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return apache.rocketmq.v1.MQService.internal_static_apache_rocketmq_v1_NotifyClientTerminationRequest_descriptor;
  }

  @java.lang.Override
  protected com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return apache.rocketmq.v1.MQService.internal_static_apache_rocketmq_v1_NotifyClientTerminationRequest_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            apache.rocketmq.v1.NotifyClientTerminationRequest.class, apache.rocketmq.v1.NotifyClientTerminationRequest.Builder.class);
  }

  private int groupCase_ = 0;
  private java.lang.Object group_;
  public enum GroupCase
      implements com.aliyun.openservices.ons.shaded.com.google.protobuf.Internal.EnumLite,
          com.aliyun.openservices.ons.shaded.com.google.protobuf.AbstractMessage.InternalOneOfEnum {
    PRODUCER_GROUP(1),
    CONSUMER_GROUP(2),
    GROUP_NOT_SET(0);
    private final int value;
    private GroupCase(int value) {
      this.value = value;
    }
    /**
     * @param value The number of the enum to look for.
     * @return The enum associated with the given number.
     * @deprecated Use {@link #forNumber(int)} instead.
     */
    @java.lang.Deprecated
    public static GroupCase valueOf(int value) {
      return forNumber(value);
    }

    public static GroupCase forNumber(int value) {
      switch (value) {
        case 1: return PRODUCER_GROUP;
        case 2: return CONSUMER_GROUP;
        case 0: return GROUP_NOT_SET;
        default: return null;
      }
    }
    public int getNumber() {
      return this.value;
    }
  };

  public GroupCase
  getGroupCase() {
    return GroupCase.forNumber(
        groupCase_);
  }

  public static final int PRODUCER_GROUP_FIELD_NUMBER = 1;
  /**
   * .apache.rocketmq.v1.Resource producer_group = 1;
   * @return Whether the producerGroup field is set.
   */
  @java.lang.Override
  public boolean hasProducerGroup() {
    return groupCase_ == 1;
  }
  /**
   * .apache.rocketmq.v1.Resource producer_group = 1;
   * @return The producerGroup.
   */
  @java.lang.Override
  public apache.rocketmq.v1.Resource getProducerGroup() {
    if (groupCase_ == 1) {
       return (apache.rocketmq.v1.Resource) group_;
    }
    return apache.rocketmq.v1.Resource.getDefaultInstance();
  }
  /**
   * .apache.rocketmq.v1.Resource producer_group = 1;
   */
  @java.lang.Override
  public apache.rocketmq.v1.ResourceOrBuilder getProducerGroupOrBuilder() {
    if (groupCase_ == 1) {
       return (apache.rocketmq.v1.Resource) group_;
    }
    return apache.rocketmq.v1.Resource.getDefaultInstance();
  }

  public static final int CONSUMER_GROUP_FIELD_NUMBER = 2;
  /**
   * .apache.rocketmq.v1.Resource consumer_group = 2;
   * @return Whether the consumerGroup field is set.
   */
  @java.lang.Override
  public boolean hasConsumerGroup() {
    return groupCase_ == 2;
  }
  /**
   * .apache.rocketmq.v1.Resource consumer_group = 2;
   * @return The consumerGroup.
   */
  @java.lang.Override
  public apache.rocketmq.v1.Resource getConsumerGroup() {
    if (groupCase_ == 2) {
       return (apache.rocketmq.v1.Resource) group_;
    }
    return apache.rocketmq.v1.Resource.getDefaultInstance();
  }
  /**
   * .apache.rocketmq.v1.Resource consumer_group = 2;
   */
  @java.lang.Override
  public apache.rocketmq.v1.ResourceOrBuilder getConsumerGroupOrBuilder() {
    if (groupCase_ == 2) {
       return (apache.rocketmq.v1.Resource) group_;
    }
    return apache.rocketmq.v1.Resource.getDefaultInstance();
  }

  public static final int CLIENT_ID_FIELD_NUMBER = 3;
  private volatile java.lang.Object clientId_;
  /**
   * string client_id = 3;
   * @return The clientId.
   */
  @java.lang.Override
  public java.lang.String getClientId() {
    java.lang.Object ref = clientId_;
    if (ref instanceof java.lang.String) {
      return (java.lang.String) ref;
    } else {
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString bs = 
          (com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString) ref;
      java.lang.String s = bs.toStringUtf8();
      clientId_ = s;
      return s;
    }
  }
  /**
   * string client_id = 3;
   * @return The bytes for clientId.
   */
  @java.lang.Override
  public com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString
      getClientIdBytes() {
    java.lang.Object ref = clientId_;
    if (ref instanceof java.lang.String) {
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString b = 
          com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      clientId_ = b;
      return b;
    } else {
      return (com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString) ref;
    }
  }

  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.aliyun.openservices.ons.shaded.com.google.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    if (groupCase_ == 1) {
      output.writeMessage(1, (apache.rocketmq.v1.Resource) group_);
    }
    if (groupCase_ == 2) {
      output.writeMessage(2, (apache.rocketmq.v1.Resource) group_);
    }
    if (!getClientIdBytes().isEmpty()) {
      com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3.writeString(output, 3, clientId_);
    }
    unknownFields.writeTo(output);
  }

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

    size = 0;
    if (groupCase_ == 1) {
      size += com.aliyun.openservices.ons.shaded.com.google.protobuf.CodedOutputStream
        .computeMessageSize(1, (apache.rocketmq.v1.Resource) group_);
    }
    if (groupCase_ == 2) {
      size += com.aliyun.openservices.ons.shaded.com.google.protobuf.CodedOutputStream
        .computeMessageSize(2, (apache.rocketmq.v1.Resource) group_);
    }
    if (!getClientIdBytes().isEmpty()) {
      size += com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3.computeStringSize(3, clientId_);
    }
    size += unknownFields.getSerializedSize();
    memoizedSize = size;
    return size;
  }

  @java.lang.Override
  public boolean equals(final java.lang.Object obj) {
    if (obj == this) {
     return true;
    }
    if (!(obj instanceof apache.rocketmq.v1.NotifyClientTerminationRequest)) {
      return super.equals(obj);
    }
    apache.rocketmq.v1.NotifyClientTerminationRequest other = (apache.rocketmq.v1.NotifyClientTerminationRequest) obj;

    if (!getClientId()
        .equals(other.getClientId())) return false;
    if (!getGroupCase().equals(other.getGroupCase())) return false;
    switch (groupCase_) {
      case 1:
        if (!getProducerGroup()
            .equals(other.getProducerGroup())) return false;
        break;
      case 2:
        if (!getConsumerGroup()
            .equals(other.getConsumerGroup())) return false;
        break;
      case 0:
      default:
    }
    if (!unknownFields.equals(other.unknownFields)) return false;
    return true;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptor().hashCode();
    hash = (37 * hash) + CLIENT_ID_FIELD_NUMBER;
    hash = (53 * hash) + getClientId().hashCode();
    switch (groupCase_) {
      case 1:
        hash = (37 * hash) + PRODUCER_GROUP_FIELD_NUMBER;
        hash = (53 * hash) + getProducerGroup().hashCode();
        break;
      case 2:
        hash = (37 * hash) + CONSUMER_GROUP_FIELD_NUMBER;
        hash = (53 * hash) + getConsumerGroup().hashCode();
        break;
      case 0:
      default:
    }
    hash = (29 * hash) + unknownFields.hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(
      java.nio.ByteBuffer data)
      throws com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(
      java.nio.ByteBuffer data,
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString data)
      throws com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString data,
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(byte[] data)
      throws com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(
      byte[] data,
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(
      java.io.InputStream input,
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseDelimitedFrom(
      java.io.InputStream input,
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(
      com.aliyun.openservices.ons.shaded.com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static apache.rocketmq.v1.NotifyClientTerminationRequest parseFrom(
      com.aliyun.openservices.ons.shaded.com.google.protobuf.CodedInputStream input,
      com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.aliyun.openservices.ons.shaded.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(apache.rocketmq.v1.NotifyClientTerminationRequest 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.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * Protobuf type {@code apache.rocketmq.v1.NotifyClientTerminationRequest}
   */
  public static final class Builder extends
      com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3.Builder implements
      // @@protoc_insertion_point(builder_implements:apache.rocketmq.v1.NotifyClientTerminationRequest)
      apache.rocketmq.v1.NotifyClientTerminationRequestOrBuilder {
    public static final com.aliyun.openservices.ons.shaded.com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return apache.rocketmq.v1.MQService.internal_static_apache_rocketmq_v1_NotifyClientTerminationRequest_descriptor;
    }

    @java.lang.Override
    protected com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return apache.rocketmq.v1.MQService.internal_static_apache_rocketmq_v1_NotifyClientTerminationRequest_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              apache.rocketmq.v1.NotifyClientTerminationRequest.class, apache.rocketmq.v1.NotifyClientTerminationRequest.Builder.class);
    }

    // Construct using apache.rocketmq.v1.NotifyClientTerminationRequest.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(
        com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }
    private void maybeForceBuilderInitialization() {
      if (com.aliyun.openservices.ons.shaded.com.google.protobuf.GeneratedMessageV3
              .alwaysUseFieldBuilders) {
      }
    }
    @java.lang.Override
    public Builder clear() {
      super.clear();
      clientId_ = "";

      groupCase_ = 0;
      group_ = null;
      return this;
    }

    @java.lang.Override
    public com.aliyun.openservices.ons.shaded.com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return apache.rocketmq.v1.MQService.internal_static_apache_rocketmq_v1_NotifyClientTerminationRequest_descriptor;
    }

    @java.lang.Override
    public apache.rocketmq.v1.NotifyClientTerminationRequest getDefaultInstanceForType() {
      return apache.rocketmq.v1.NotifyClientTerminationRequest.getDefaultInstance();
    }

    @java.lang.Override
    public apache.rocketmq.v1.NotifyClientTerminationRequest build() {
      apache.rocketmq.v1.NotifyClientTerminationRequest result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public apache.rocketmq.v1.NotifyClientTerminationRequest buildPartial() {
      apache.rocketmq.v1.NotifyClientTerminationRequest result = new apache.rocketmq.v1.NotifyClientTerminationRequest(this);
      if (groupCase_ == 1) {
        if (producerGroupBuilder_ == null) {
          result.group_ = group_;
        } else {
          result.group_ = producerGroupBuilder_.build();
        }
      }
      if (groupCase_ == 2) {
        if (consumerGroupBuilder_ == null) {
          result.group_ = group_;
        } else {
          result.group_ = consumerGroupBuilder_.build();
        }
      }
      result.clientId_ = clientId_;
      result.groupCase_ = groupCase_;
      onBuilt();
      return result;
    }

    @java.lang.Override
    public Builder clone() {
      return super.clone();
    }
    @java.lang.Override
    public Builder setField(
        com.aliyun.openservices.ons.shaded.com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.setField(field, value);
    }
    @java.lang.Override
    public Builder clearField(
        com.aliyun.openservices.ons.shaded.com.google.protobuf.Descriptors.FieldDescriptor field) {
      return super.clearField(field);
    }
    @java.lang.Override
    public Builder clearOneof(
        com.aliyun.openservices.ons.shaded.com.google.protobuf.Descriptors.OneofDescriptor oneof) {
      return super.clearOneof(oneof);
    }
    @java.lang.Override
    public Builder setRepeatedField(
        com.aliyun.openservices.ons.shaded.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.aliyun.openservices.ons.shaded.com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.addRepeatedField(field, value);
    }
    @java.lang.Override
    public Builder mergeFrom(com.aliyun.openservices.ons.shaded.com.google.protobuf.Message other) {
      if (other instanceof apache.rocketmq.v1.NotifyClientTerminationRequest) {
        return mergeFrom((apache.rocketmq.v1.NotifyClientTerminationRequest)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(apache.rocketmq.v1.NotifyClientTerminationRequest other) {
      if (other == apache.rocketmq.v1.NotifyClientTerminationRequest.getDefaultInstance()) return this;
      if (!other.getClientId().isEmpty()) {
        clientId_ = other.clientId_;
        onChanged();
      }
      switch (other.getGroupCase()) {
        case PRODUCER_GROUP: {
          mergeProducerGroup(other.getProducerGroup());
          break;
        }
        case CONSUMER_GROUP: {
          mergeConsumerGroup(other.getConsumerGroup());
          break;
        }
        case GROUP_NOT_SET: {
          break;
        }
      }
      this.mergeUnknownFields(other.unknownFields);
      onChanged();
      return this;
    }

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

    @java.lang.Override
    public Builder mergeFrom(
        com.aliyun.openservices.ons.shaded.com.google.protobuf.CodedInputStream input,
        com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      apache.rocketmq.v1.NotifyClientTerminationRequest parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (apache.rocketmq.v1.NotifyClientTerminationRequest) e.getUnfinishedMessage();
        throw e.unwrapIOException();
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }
    private int groupCase_ = 0;
    private java.lang.Object group_;
    public GroupCase
        getGroupCase() {
      return GroupCase.forNumber(
          groupCase_);
    }

    public Builder clearGroup() {
      groupCase_ = 0;
      group_ = null;
      onChanged();
      return this;
    }


    private com.aliyun.openservices.ons.shaded.com.google.protobuf.SingleFieldBuilderV3<
        apache.rocketmq.v1.Resource, apache.rocketmq.v1.Resource.Builder, apache.rocketmq.v1.ResourceOrBuilder> producerGroupBuilder_;
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     * @return Whether the producerGroup field is set.
     */
    @java.lang.Override
    public boolean hasProducerGroup() {
      return groupCase_ == 1;
    }
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     * @return The producerGroup.
     */
    @java.lang.Override
    public apache.rocketmq.v1.Resource getProducerGroup() {
      if (producerGroupBuilder_ == null) {
        if (groupCase_ == 1) {
          return (apache.rocketmq.v1.Resource) group_;
        }
        return apache.rocketmq.v1.Resource.getDefaultInstance();
      } else {
        if (groupCase_ == 1) {
          return producerGroupBuilder_.getMessage();
        }
        return apache.rocketmq.v1.Resource.getDefaultInstance();
      }
    }
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     */
    public Builder setProducerGroup(apache.rocketmq.v1.Resource value) {
      if (producerGroupBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        group_ = value;
        onChanged();
      } else {
        producerGroupBuilder_.setMessage(value);
      }
      groupCase_ = 1;
      return this;
    }
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     */
    public Builder setProducerGroup(
        apache.rocketmq.v1.Resource.Builder builderForValue) {
      if (producerGroupBuilder_ == null) {
        group_ = builderForValue.build();
        onChanged();
      } else {
        producerGroupBuilder_.setMessage(builderForValue.build());
      }
      groupCase_ = 1;
      return this;
    }
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     */
    public Builder mergeProducerGroup(apache.rocketmq.v1.Resource value) {
      if (producerGroupBuilder_ == null) {
        if (groupCase_ == 1 &&
            group_ != apache.rocketmq.v1.Resource.getDefaultInstance()) {
          group_ = apache.rocketmq.v1.Resource.newBuilder((apache.rocketmq.v1.Resource) group_)
              .mergeFrom(value).buildPartial();
        } else {
          group_ = value;
        }
        onChanged();
      } else {
        if (groupCase_ == 1) {
          producerGroupBuilder_.mergeFrom(value);
        }
        producerGroupBuilder_.setMessage(value);
      }
      groupCase_ = 1;
      return this;
    }
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     */
    public Builder clearProducerGroup() {
      if (producerGroupBuilder_ == null) {
        if (groupCase_ == 1) {
          groupCase_ = 0;
          group_ = null;
          onChanged();
        }
      } else {
        if (groupCase_ == 1) {
          groupCase_ = 0;
          group_ = null;
        }
        producerGroupBuilder_.clear();
      }
      return this;
    }
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     */
    public apache.rocketmq.v1.Resource.Builder getProducerGroupBuilder() {
      return getProducerGroupFieldBuilder().getBuilder();
    }
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     */
    @java.lang.Override
    public apache.rocketmq.v1.ResourceOrBuilder getProducerGroupOrBuilder() {
      if ((groupCase_ == 1) && (producerGroupBuilder_ != null)) {
        return producerGroupBuilder_.getMessageOrBuilder();
      } else {
        if (groupCase_ == 1) {
          return (apache.rocketmq.v1.Resource) group_;
        }
        return apache.rocketmq.v1.Resource.getDefaultInstance();
      }
    }
    /**
     * .apache.rocketmq.v1.Resource producer_group = 1;
     */
    private com.aliyun.openservices.ons.shaded.com.google.protobuf.SingleFieldBuilderV3<
        apache.rocketmq.v1.Resource, apache.rocketmq.v1.Resource.Builder, apache.rocketmq.v1.ResourceOrBuilder> 
        getProducerGroupFieldBuilder() {
      if (producerGroupBuilder_ == null) {
        if (!(groupCase_ == 1)) {
          group_ = apache.rocketmq.v1.Resource.getDefaultInstance();
        }
        producerGroupBuilder_ = new com.aliyun.openservices.ons.shaded.com.google.protobuf.SingleFieldBuilderV3<
            apache.rocketmq.v1.Resource, apache.rocketmq.v1.Resource.Builder, apache.rocketmq.v1.ResourceOrBuilder>(
                (apache.rocketmq.v1.Resource) group_,
                getParentForChildren(),
                isClean());
        group_ = null;
      }
      groupCase_ = 1;
      onChanged();;
      return producerGroupBuilder_;
    }

    private com.aliyun.openservices.ons.shaded.com.google.protobuf.SingleFieldBuilderV3<
        apache.rocketmq.v1.Resource, apache.rocketmq.v1.Resource.Builder, apache.rocketmq.v1.ResourceOrBuilder> consumerGroupBuilder_;
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     * @return Whether the consumerGroup field is set.
     */
    @java.lang.Override
    public boolean hasConsumerGroup() {
      return groupCase_ == 2;
    }
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     * @return The consumerGroup.
     */
    @java.lang.Override
    public apache.rocketmq.v1.Resource getConsumerGroup() {
      if (consumerGroupBuilder_ == null) {
        if (groupCase_ == 2) {
          return (apache.rocketmq.v1.Resource) group_;
        }
        return apache.rocketmq.v1.Resource.getDefaultInstance();
      } else {
        if (groupCase_ == 2) {
          return consumerGroupBuilder_.getMessage();
        }
        return apache.rocketmq.v1.Resource.getDefaultInstance();
      }
    }
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     */
    public Builder setConsumerGroup(apache.rocketmq.v1.Resource value) {
      if (consumerGroupBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        group_ = value;
        onChanged();
      } else {
        consumerGroupBuilder_.setMessage(value);
      }
      groupCase_ = 2;
      return this;
    }
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     */
    public Builder setConsumerGroup(
        apache.rocketmq.v1.Resource.Builder builderForValue) {
      if (consumerGroupBuilder_ == null) {
        group_ = builderForValue.build();
        onChanged();
      } else {
        consumerGroupBuilder_.setMessage(builderForValue.build());
      }
      groupCase_ = 2;
      return this;
    }
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     */
    public Builder mergeConsumerGroup(apache.rocketmq.v1.Resource value) {
      if (consumerGroupBuilder_ == null) {
        if (groupCase_ == 2 &&
            group_ != apache.rocketmq.v1.Resource.getDefaultInstance()) {
          group_ = apache.rocketmq.v1.Resource.newBuilder((apache.rocketmq.v1.Resource) group_)
              .mergeFrom(value).buildPartial();
        } else {
          group_ = value;
        }
        onChanged();
      } else {
        if (groupCase_ == 2) {
          consumerGroupBuilder_.mergeFrom(value);
        }
        consumerGroupBuilder_.setMessage(value);
      }
      groupCase_ = 2;
      return this;
    }
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     */
    public Builder clearConsumerGroup() {
      if (consumerGroupBuilder_ == null) {
        if (groupCase_ == 2) {
          groupCase_ = 0;
          group_ = null;
          onChanged();
        }
      } else {
        if (groupCase_ == 2) {
          groupCase_ = 0;
          group_ = null;
        }
        consumerGroupBuilder_.clear();
      }
      return this;
    }
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     */
    public apache.rocketmq.v1.Resource.Builder getConsumerGroupBuilder() {
      return getConsumerGroupFieldBuilder().getBuilder();
    }
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     */
    @java.lang.Override
    public apache.rocketmq.v1.ResourceOrBuilder getConsumerGroupOrBuilder() {
      if ((groupCase_ == 2) && (consumerGroupBuilder_ != null)) {
        return consumerGroupBuilder_.getMessageOrBuilder();
      } else {
        if (groupCase_ == 2) {
          return (apache.rocketmq.v1.Resource) group_;
        }
        return apache.rocketmq.v1.Resource.getDefaultInstance();
      }
    }
    /**
     * .apache.rocketmq.v1.Resource consumer_group = 2;
     */
    private com.aliyun.openservices.ons.shaded.com.google.protobuf.SingleFieldBuilderV3<
        apache.rocketmq.v1.Resource, apache.rocketmq.v1.Resource.Builder, apache.rocketmq.v1.ResourceOrBuilder> 
        getConsumerGroupFieldBuilder() {
      if (consumerGroupBuilder_ == null) {
        if (!(groupCase_ == 2)) {
          group_ = apache.rocketmq.v1.Resource.getDefaultInstance();
        }
        consumerGroupBuilder_ = new com.aliyun.openservices.ons.shaded.com.google.protobuf.SingleFieldBuilderV3<
            apache.rocketmq.v1.Resource, apache.rocketmq.v1.Resource.Builder, apache.rocketmq.v1.ResourceOrBuilder>(
                (apache.rocketmq.v1.Resource) group_,
                getParentForChildren(),
                isClean());
        group_ = null;
      }
      groupCase_ = 2;
      onChanged();;
      return consumerGroupBuilder_;
    }

    private java.lang.Object clientId_ = "";
    /**
     * string client_id = 3;
     * @return The clientId.
     */
    public java.lang.String getClientId() {
      java.lang.Object ref = clientId_;
      if (!(ref instanceof java.lang.String)) {
        com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString bs =
            (com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        clientId_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * string client_id = 3;
     * @return The bytes for clientId.
     */
    public com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString
        getClientIdBytes() {
      java.lang.Object ref = clientId_;
      if (ref instanceof String) {
        com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString b = 
            com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        clientId_ = b;
        return b;
      } else {
        return (com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * string client_id = 3;
     * @param value The clientId to set.
     * @return This builder for chaining.
     */
    public Builder setClientId(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      clientId_ = value;
      onChanged();
      return this;
    }
    /**
     * string client_id = 3;
     * @return This builder for chaining.
     */
    public Builder clearClientId() {
      
      clientId_ = getDefaultInstance().getClientId();
      onChanged();
      return this;
    }
    /**
     * string client_id = 3;
     * @param value The bytes for clientId to set.
     * @return This builder for chaining.
     */
    public Builder setClientIdBytes(
        com.aliyun.openservices.ons.shaded.com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      clientId_ = value;
      onChanged();
      return this;
    }
    @java.lang.Override
    public final Builder setUnknownFields(
        final com.aliyun.openservices.ons.shaded.com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFields(unknownFields);
    }

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


    // @@protoc_insertion_point(builder_scope:apache.rocketmq.v1.NotifyClientTerminationRequest)
  }

  // @@protoc_insertion_point(class_scope:apache.rocketmq.v1.NotifyClientTerminationRequest)
  private static final apache.rocketmq.v1.NotifyClientTerminationRequest DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new apache.rocketmq.v1.NotifyClientTerminationRequest();
  }

  public static apache.rocketmq.v1.NotifyClientTerminationRequest getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.aliyun.openservices.ons.shaded.com.google.protobuf.Parser
      PARSER = new com.aliyun.openservices.ons.shaded.com.google.protobuf.AbstractParser() {
    @java.lang.Override
    public NotifyClientTerminationRequest parsePartialFrom(
        com.aliyun.openservices.ons.shaded.com.google.protobuf.CodedInputStream input,
        com.aliyun.openservices.ons.shaded.com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.aliyun.openservices.ons.shaded.com.google.protobuf.InvalidProtocolBufferException {
      return new NotifyClientTerminationRequest(input, extensionRegistry);
    }
  };

  public static com.aliyun.openservices.ons.shaded.com.google.protobuf.Parser parser() {
    return PARSER;
  }

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

  @java.lang.Override
  public apache.rocketmq.v1.NotifyClientTerminationRequest getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy