/*
 * Copyright 2020 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/bigtable/admin/v2/bigtable_instance_admin.proto

package com.google.bigtable.admin.v2;

/**
 *
 *
 * <pre>
 * The metadata for the Operation returned by CreateInstance.
 * </pre>
 *
 * Protobuf type {@code google.bigtable.admin.v2.CreateInstanceMetadata}
 */
public final class CreateInstanceMetadata extends com.google.protobuf.GeneratedMessageV3
    implements
    // @@protoc_insertion_point(message_implements:google.bigtable.admin.v2.CreateInstanceMetadata)
    CreateInstanceMetadataOrBuilder {
  private static final long serialVersionUID = 0L;
  // Use CreateInstanceMetadata.newBuilder() to construct.
  private CreateInstanceMetadata(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
    super(builder);
  }

  private CreateInstanceMetadata() {}

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

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
    return this.unknownFields;
  }

  private CreateInstanceMetadata(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    this();
    if (extensionRegistry == null) {
      throw new java.lang.NullPointerException();
    }
    com.google.protobuf.UnknownFieldSet.Builder unknownFields =
        com.google.protobuf.UnknownFieldSet.newBuilder();
    try {
      boolean done = false;
      while (!done) {
        int tag = input.readTag();
        switch (tag) {
          case 0:
            done = true;
            break;
          case 10:
            {
              com.google.bigtable.admin.v2.CreateInstanceRequest.Builder subBuilder = null;
              if (originalRequest_ != null) {
                subBuilder = originalRequest_.toBuilder();
              }
              originalRequest_ =
                  input.readMessage(
                      com.google.bigtable.admin.v2.CreateInstanceRequest.parser(),
                      extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(originalRequest_);
                originalRequest_ = subBuilder.buildPartial();
              }

              break;
            }
          case 18:
            {
              com.google.protobuf.Timestamp.Builder subBuilder = null;
              if (requestTime_ != null) {
                subBuilder = requestTime_.toBuilder();
              }
              requestTime_ =
                  input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(requestTime_);
                requestTime_ = subBuilder.buildPartial();
              }

              break;
            }
          case 26:
            {
              com.google.protobuf.Timestamp.Builder subBuilder = null;
              if (finishTime_ != null) {
                subBuilder = finishTime_.toBuilder();
              }
              finishTime_ =
                  input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(finishTime_);
                finishTime_ = subBuilder.buildPartial();
              }

              break;
            }
          default:
            {
              if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
        }
      }
    } catch (com.google.protobuf.InvalidProtocolBufferException e) {
      throw e.setUnfinishedMessage(this);
    } catch (java.io.IOException e) {
      throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
    } finally {
      this.unknownFields = unknownFields.build();
      makeExtensionsImmutable();
    }
  }

  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
    return com.google.bigtable.admin.v2.BigtableInstanceAdminProto
        .internal_static_google_bigtable_admin_v2_CreateInstanceMetadata_descriptor;
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.google.bigtable.admin.v2.BigtableInstanceAdminProto
        .internal_static_google_bigtable_admin_v2_CreateInstanceMetadata_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.google.bigtable.admin.v2.CreateInstanceMetadata.class,
            com.google.bigtable.admin.v2.CreateInstanceMetadata.Builder.class);
  }

  public static final int ORIGINAL_REQUEST_FIELD_NUMBER = 1;
  private com.google.bigtable.admin.v2.CreateInstanceRequest originalRequest_;
  /**
   *
   *
   * <pre>
   * The request that prompted the initiation of this CreateInstance operation.
   * </pre>
   *
   * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
   *
   * @return Whether the originalRequest field is set.
   */
  @java.lang.Override
  public boolean hasOriginalRequest() {
    return originalRequest_ != null;
  }
  /**
   *
   *
   * <pre>
   * The request that prompted the initiation of this CreateInstance operation.
   * </pre>
   *
   * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
   *
   * @return The originalRequest.
   */
  @java.lang.Override
  public com.google.bigtable.admin.v2.CreateInstanceRequest getOriginalRequest() {
    return originalRequest_ == null
        ? com.google.bigtable.admin.v2.CreateInstanceRequest.getDefaultInstance()
        : originalRequest_;
  }
  /**
   *
   *
   * <pre>
   * The request that prompted the initiation of this CreateInstance operation.
   * </pre>
   *
   * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
   */
  @java.lang.Override
  public com.google.bigtable.admin.v2.CreateInstanceRequestOrBuilder getOriginalRequestOrBuilder() {
    return getOriginalRequest();
  }

  public static final int REQUEST_TIME_FIELD_NUMBER = 2;
  private com.google.protobuf.Timestamp requestTime_;
  /**
   *
   *
   * <pre>
   * The time at which the original request was received.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp request_time = 2;</code>
   *
   * @return Whether the requestTime field is set.
   */
  @java.lang.Override
  public boolean hasRequestTime() {
    return requestTime_ != null;
  }
  /**
   *
   *
   * <pre>
   * The time at which the original request was received.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp request_time = 2;</code>
   *
   * @return The requestTime.
   */
  @java.lang.Override
  public com.google.protobuf.Timestamp getRequestTime() {
    return requestTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : requestTime_;
  }
  /**
   *
   *
   * <pre>
   * The time at which the original request was received.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp request_time = 2;</code>
   */
  @java.lang.Override
  public com.google.protobuf.TimestampOrBuilder getRequestTimeOrBuilder() {
    return getRequestTime();
  }

  public static final int FINISH_TIME_FIELD_NUMBER = 3;
  private com.google.protobuf.Timestamp finishTime_;
  /**
   *
   *
   * <pre>
   * The time at which the operation failed or was completed successfully.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp finish_time = 3;</code>
   *
   * @return Whether the finishTime field is set.
   */
  @java.lang.Override
  public boolean hasFinishTime() {
    return finishTime_ != null;
  }
  /**
   *
   *
   * <pre>
   * The time at which the operation failed or was completed successfully.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp finish_time = 3;</code>
   *
   * @return The finishTime.
   */
  @java.lang.Override
  public com.google.protobuf.Timestamp getFinishTime() {
    return finishTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : finishTime_;
  }
  /**
   *
   *
   * <pre>
   * The time at which the operation failed or was completed successfully.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp finish_time = 3;</code>
   */
  @java.lang.Override
  public com.google.protobuf.TimestampOrBuilder getFinishTimeOrBuilder() {
    return getFinishTime();
  }

  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 (originalRequest_ != null) {
      output.writeMessage(1, getOriginalRequest());
    }
    if (requestTime_ != null) {
      output.writeMessage(2, getRequestTime());
    }
    if (finishTime_ != null) {
      output.writeMessage(3, getFinishTime());
    }
    unknownFields.writeTo(output);
  }

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

    size = 0;
    if (originalRequest_ != null) {
      size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getOriginalRequest());
    }
    if (requestTime_ != null) {
      size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getRequestTime());
    }
    if (finishTime_ != null) {
      size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFinishTime());
    }
    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 com.google.bigtable.admin.v2.CreateInstanceMetadata)) {
      return super.equals(obj);
    }
    com.google.bigtable.admin.v2.CreateInstanceMetadata other =
        (com.google.bigtable.admin.v2.CreateInstanceMetadata) obj;

    if (hasOriginalRequest() != other.hasOriginalRequest()) return false;
    if (hasOriginalRequest()) {
      if (!getOriginalRequest().equals(other.getOriginalRequest())) return false;
    }
    if (hasRequestTime() != other.hasRequestTime()) return false;
    if (hasRequestTime()) {
      if (!getRequestTime().equals(other.getRequestTime())) return false;
    }
    if (hasFinishTime() != other.hasFinishTime()) return false;
    if (hasFinishTime()) {
      if (!getFinishTime().equals(other.getFinishTime())) return false;
    }
    if (!unknownFields.equals(other.unknownFields)) return false;
    return true;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptor().hashCode();
    if (hasOriginalRequest()) {
      hash = (37 * hash) + ORIGINAL_REQUEST_FIELD_NUMBER;
      hash = (53 * hash) + getOriginalRequest().hashCode();
    }
    if (hasRequestTime()) {
      hash = (37 * hash) + REQUEST_TIME_FIELD_NUMBER;
      hash = (53 * hash) + getRequestTime().hashCode();
    }
    if (hasFinishTime()) {
      hash = (37 * hash) + FINISH_TIME_FIELD_NUMBER;
      hash = (53 * hash) + getFinishTime().hashCode();
    }
    hash = (29 * hash) + unknownFields.hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      java.io.InputStream input) throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
        PARSER, input, extensionRegistry);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseDelimitedFrom(
      java.io.InputStream input) throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseDelimitedFrom(
      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
        PARSER, input, extensionRegistry);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      com.google.protobuf.CodedInputStream input) throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
        PARSER, input, extensionRegistry);
  }

  @java.lang.Override
  public Builder newBuilderForType() {
    return newBuilder();
  }

  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }

  public static Builder newBuilder(com.google.bigtable.admin.v2.CreateInstanceMetadata 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;
  }
  /**
   *
   *
   * <pre>
   * The metadata for the Operation returned by CreateInstance.
   * </pre>
   *
   * Protobuf type {@code google.bigtable.admin.v2.CreateInstanceMetadata}
   */
  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder>
      implements
      // @@protoc_insertion_point(builder_implements:google.bigtable.admin.v2.CreateInstanceMetadata)
      com.google.bigtable.admin.v2.CreateInstanceMetadataOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
      return com.google.bigtable.admin.v2.BigtableInstanceAdminProto
          .internal_static_google_bigtable_admin_v2_CreateInstanceMetadata_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.bigtable.admin.v2.BigtableInstanceAdminProto
          .internal_static_google_bigtable_admin_v2_CreateInstanceMetadata_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.bigtable.admin.v2.CreateInstanceMetadata.class,
              com.google.bigtable.admin.v2.CreateInstanceMetadata.Builder.class);
    }

    // Construct using com.google.bigtable.admin.v2.CreateInstanceMetadata.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

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

    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {}
    }

    @java.lang.Override
    public Builder clear() {
      super.clear();
      if (originalRequestBuilder_ == null) {
        originalRequest_ = null;
      } else {
        originalRequest_ = null;
        originalRequestBuilder_ = null;
      }
      if (requestTimeBuilder_ == null) {
        requestTime_ = null;
      } else {
        requestTime_ = null;
        requestTimeBuilder_ = null;
      }
      if (finishTimeBuilder_ == null) {
        finishTime_ = null;
      } else {
        finishTime_ = null;
        finishTimeBuilder_ = null;
      }
      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
      return com.google.bigtable.admin.v2.BigtableInstanceAdminProto
          .internal_static_google_bigtable_admin_v2_CreateInstanceMetadata_descriptor;
    }

    @java.lang.Override
    public com.google.bigtable.admin.v2.CreateInstanceMetadata getDefaultInstanceForType() {
      return com.google.bigtable.admin.v2.CreateInstanceMetadata.getDefaultInstance();
    }

    @java.lang.Override
    public com.google.bigtable.admin.v2.CreateInstanceMetadata build() {
      com.google.bigtable.admin.v2.CreateInstanceMetadata result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public com.google.bigtable.admin.v2.CreateInstanceMetadata buildPartial() {
      com.google.bigtable.admin.v2.CreateInstanceMetadata result =
          new com.google.bigtable.admin.v2.CreateInstanceMetadata(this);
      if (originalRequestBuilder_ == null) {
        result.originalRequest_ = originalRequest_;
      } else {
        result.originalRequest_ = originalRequestBuilder_.build();
      }
      if (requestTimeBuilder_ == null) {
        result.requestTime_ = requestTime_;
      } else {
        result.requestTime_ = requestTimeBuilder_.build();
      }
      if (finishTimeBuilder_ == null) {
        result.finishTime_ = finishTime_;
      } else {
        result.finishTime_ = finishTimeBuilder_.build();
      }
      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 com.google.bigtable.admin.v2.CreateInstanceMetadata) {
        return mergeFrom((com.google.bigtable.admin.v2.CreateInstanceMetadata) other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.google.bigtable.admin.v2.CreateInstanceMetadata other) {
      if (other == com.google.bigtable.admin.v2.CreateInstanceMetadata.getDefaultInstance())
        return this;
      if (other.hasOriginalRequest()) {
        mergeOriginalRequest(other.getOriginalRequest());
      }
      if (other.hasRequestTime()) {
        mergeRequestTime(other.getRequestTime());
      }
      if (other.hasFinishTime()) {
        mergeFinishTime(other.getFinishTime());
      }
      this.mergeUnknownFields(other.unknownFields);
      onChanged();
      return this;
    }

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

    @java.lang.Override
    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      com.google.bigtable.admin.v2.CreateInstanceMetadata parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage =
            (com.google.bigtable.admin.v2.CreateInstanceMetadata) e.getUnfinishedMessage();
        throw e.unwrapIOException();
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }

    private com.google.bigtable.admin.v2.CreateInstanceRequest originalRequest_;
    private com.google.protobuf.SingleFieldBuilderV3<
            com.google.bigtable.admin.v2.CreateInstanceRequest,
            com.google.bigtable.admin.v2.CreateInstanceRequest.Builder,
            com.google.bigtable.admin.v2.CreateInstanceRequestOrBuilder>
        originalRequestBuilder_;
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     *
     * @return Whether the originalRequest field is set.
     */
    public boolean hasOriginalRequest() {
      return originalRequestBuilder_ != null || originalRequest_ != null;
    }
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     *
     * @return The originalRequest.
     */
    public com.google.bigtable.admin.v2.CreateInstanceRequest getOriginalRequest() {
      if (originalRequestBuilder_ == null) {
        return originalRequest_ == null
            ? com.google.bigtable.admin.v2.CreateInstanceRequest.getDefaultInstance()
            : originalRequest_;
      } else {
        return originalRequestBuilder_.getMessage();
      }
    }
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     */
    public Builder setOriginalRequest(com.google.bigtable.admin.v2.CreateInstanceRequest value) {
      if (originalRequestBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        originalRequest_ = value;
        onChanged();
      } else {
        originalRequestBuilder_.setMessage(value);
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     */
    public Builder setOriginalRequest(
        com.google.bigtable.admin.v2.CreateInstanceRequest.Builder builderForValue) {
      if (originalRequestBuilder_ == null) {
        originalRequest_ = builderForValue.build();
        onChanged();
      } else {
        originalRequestBuilder_.setMessage(builderForValue.build());
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     */
    public Builder mergeOriginalRequest(com.google.bigtable.admin.v2.CreateInstanceRequest value) {
      if (originalRequestBuilder_ == null) {
        if (originalRequest_ != null) {
          originalRequest_ =
              com.google.bigtable.admin.v2.CreateInstanceRequest.newBuilder(originalRequest_)
                  .mergeFrom(value)
                  .buildPartial();
        } else {
          originalRequest_ = value;
        }
        onChanged();
      } else {
        originalRequestBuilder_.mergeFrom(value);
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     */
    public Builder clearOriginalRequest() {
      if (originalRequestBuilder_ == null) {
        originalRequest_ = null;
        onChanged();
      } else {
        originalRequest_ = null;
        originalRequestBuilder_ = null;
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     */
    public com.google.bigtable.admin.v2.CreateInstanceRequest.Builder getOriginalRequestBuilder() {

      onChanged();
      return getOriginalRequestFieldBuilder().getBuilder();
    }
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     */
    public com.google.bigtable.admin.v2.CreateInstanceRequestOrBuilder
        getOriginalRequestOrBuilder() {
      if (originalRequestBuilder_ != null) {
        return originalRequestBuilder_.getMessageOrBuilder();
      } else {
        return originalRequest_ == null
            ? com.google.bigtable.admin.v2.CreateInstanceRequest.getDefaultInstance()
            : originalRequest_;
      }
    }
    /**
     *
     *
     * <pre>
     * The request that prompted the initiation of this CreateInstance operation.
     * </pre>
     *
     * <code>.google.bigtable.admin.v2.CreateInstanceRequest original_request = 1;</code>
     */
    private com.google.protobuf.SingleFieldBuilderV3<
            com.google.bigtable.admin.v2.CreateInstanceRequest,
            com.google.bigtable.admin.v2.CreateInstanceRequest.Builder,
            com.google.bigtable.admin.v2.CreateInstanceRequestOrBuilder>
        getOriginalRequestFieldBuilder() {
      if (originalRequestBuilder_ == null) {
        originalRequestBuilder_ =
            new com.google.protobuf.SingleFieldBuilderV3<
                com.google.bigtable.admin.v2.CreateInstanceRequest,
                com.google.bigtable.admin.v2.CreateInstanceRequest.Builder,
                com.google.bigtable.admin.v2.CreateInstanceRequestOrBuilder>(
                getOriginalRequest(), getParentForChildren(), isClean());
        originalRequest_ = null;
      }
      return originalRequestBuilder_;
    }

    private com.google.protobuf.Timestamp requestTime_;
    private com.google.protobuf.SingleFieldBuilderV3<
            com.google.protobuf.Timestamp,
            com.google.protobuf.Timestamp.Builder,
            com.google.protobuf.TimestampOrBuilder>
        requestTimeBuilder_;
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     *
     * @return Whether the requestTime field is set.
     */
    public boolean hasRequestTime() {
      return requestTimeBuilder_ != null || requestTime_ != null;
    }
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     *
     * @return The requestTime.
     */
    public com.google.protobuf.Timestamp getRequestTime() {
      if (requestTimeBuilder_ == null) {
        return requestTime_ == null
            ? com.google.protobuf.Timestamp.getDefaultInstance()
            : requestTime_;
      } else {
        return requestTimeBuilder_.getMessage();
      }
    }
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     */
    public Builder setRequestTime(com.google.protobuf.Timestamp value) {
      if (requestTimeBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        requestTime_ = value;
        onChanged();
      } else {
        requestTimeBuilder_.setMessage(value);
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     */
    public Builder setRequestTime(com.google.protobuf.Timestamp.Builder builderForValue) {
      if (requestTimeBuilder_ == null) {
        requestTime_ = builderForValue.build();
        onChanged();
      } else {
        requestTimeBuilder_.setMessage(builderForValue.build());
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     */
    public Builder mergeRequestTime(com.google.protobuf.Timestamp value) {
      if (requestTimeBuilder_ == null) {
        if (requestTime_ != null) {
          requestTime_ =
              com.google.protobuf.Timestamp.newBuilder(requestTime_)
                  .mergeFrom(value)
                  .buildPartial();
        } else {
          requestTime_ = value;
        }
        onChanged();
      } else {
        requestTimeBuilder_.mergeFrom(value);
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     */
    public Builder clearRequestTime() {
      if (requestTimeBuilder_ == null) {
        requestTime_ = null;
        onChanged();
      } else {
        requestTime_ = null;
        requestTimeBuilder_ = null;
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     */
    public com.google.protobuf.Timestamp.Builder getRequestTimeBuilder() {

      onChanged();
      return getRequestTimeFieldBuilder().getBuilder();
    }
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     */
    public com.google.protobuf.TimestampOrBuilder getRequestTimeOrBuilder() {
      if (requestTimeBuilder_ != null) {
        return requestTimeBuilder_.getMessageOrBuilder();
      } else {
        return requestTime_ == null
            ? com.google.protobuf.Timestamp.getDefaultInstance()
            : requestTime_;
      }
    }
    /**
     *
     *
     * <pre>
     * The time at which the original request was received.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp request_time = 2;</code>
     */
    private com.google.protobuf.SingleFieldBuilderV3<
            com.google.protobuf.Timestamp,
            com.google.protobuf.Timestamp.Builder,
            com.google.protobuf.TimestampOrBuilder>
        getRequestTimeFieldBuilder() {
      if (requestTimeBuilder_ == null) {
        requestTimeBuilder_ =
            new com.google.protobuf.SingleFieldBuilderV3<
                com.google.protobuf.Timestamp,
                com.google.protobuf.Timestamp.Builder,
                com.google.protobuf.TimestampOrBuilder>(
                getRequestTime(), getParentForChildren(), isClean());
        requestTime_ = null;
      }
      return requestTimeBuilder_;
    }

    private com.google.protobuf.Timestamp finishTime_;
    private com.google.protobuf.SingleFieldBuilderV3<
            com.google.protobuf.Timestamp,
            com.google.protobuf.Timestamp.Builder,
            com.google.protobuf.TimestampOrBuilder>
        finishTimeBuilder_;
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     *
     * @return Whether the finishTime field is set.
     */
    public boolean hasFinishTime() {
      return finishTimeBuilder_ != null || finishTime_ != null;
    }
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     *
     * @return The finishTime.
     */
    public com.google.protobuf.Timestamp getFinishTime() {
      if (finishTimeBuilder_ == null) {
        return finishTime_ == null
            ? com.google.protobuf.Timestamp.getDefaultInstance()
            : finishTime_;
      } else {
        return finishTimeBuilder_.getMessage();
      }
    }
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     */
    public Builder setFinishTime(com.google.protobuf.Timestamp value) {
      if (finishTimeBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        finishTime_ = value;
        onChanged();
      } else {
        finishTimeBuilder_.setMessage(value);
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     */
    public Builder setFinishTime(com.google.protobuf.Timestamp.Builder builderForValue) {
      if (finishTimeBuilder_ == null) {
        finishTime_ = builderForValue.build();
        onChanged();
      } else {
        finishTimeBuilder_.setMessage(builderForValue.build());
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     */
    public Builder mergeFinishTime(com.google.protobuf.Timestamp value) {
      if (finishTimeBuilder_ == null) {
        if (finishTime_ != null) {
          finishTime_ =
              com.google.protobuf.Timestamp.newBuilder(finishTime_).mergeFrom(value).buildPartial();
        } else {
          finishTime_ = value;
        }
        onChanged();
      } else {
        finishTimeBuilder_.mergeFrom(value);
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     */
    public Builder clearFinishTime() {
      if (finishTimeBuilder_ == null) {
        finishTime_ = null;
        onChanged();
      } else {
        finishTime_ = null;
        finishTimeBuilder_ = null;
      }

      return this;
    }
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     */
    public com.google.protobuf.Timestamp.Builder getFinishTimeBuilder() {

      onChanged();
      return getFinishTimeFieldBuilder().getBuilder();
    }
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     */
    public com.google.protobuf.TimestampOrBuilder getFinishTimeOrBuilder() {
      if (finishTimeBuilder_ != null) {
        return finishTimeBuilder_.getMessageOrBuilder();
      } else {
        return finishTime_ == null
            ? com.google.protobuf.Timestamp.getDefaultInstance()
            : finishTime_;
      }
    }
    /**
     *
     *
     * <pre>
     * The time at which the operation failed or was completed successfully.
     * </pre>
     *
     * <code>.google.protobuf.Timestamp finish_time = 3;</code>
     */
    private com.google.protobuf.SingleFieldBuilderV3<
            com.google.protobuf.Timestamp,
            com.google.protobuf.Timestamp.Builder,
            com.google.protobuf.TimestampOrBuilder>
        getFinishTimeFieldBuilder() {
      if (finishTimeBuilder_ == null) {
        finishTimeBuilder_ =
            new com.google.protobuf.SingleFieldBuilderV3<
                com.google.protobuf.Timestamp,
                com.google.protobuf.Timestamp.Builder,
                com.google.protobuf.TimestampOrBuilder>(
                getFinishTime(), getParentForChildren(), isClean());
        finishTime_ = null;
      }
      return finishTimeBuilder_;
    }

    @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:google.bigtable.admin.v2.CreateInstanceMetadata)
  }

  // @@protoc_insertion_point(class_scope:google.bigtable.admin.v2.CreateInstanceMetadata)
  private static final com.google.bigtable.admin.v2.CreateInstanceMetadata DEFAULT_INSTANCE;

  static {
    DEFAULT_INSTANCE = new com.google.bigtable.admin.v2.CreateInstanceMetadata();
  }

  public static com.google.bigtable.admin.v2.CreateInstanceMetadata getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser<CreateInstanceMetadata> PARSER =
      new com.google.protobuf.AbstractParser<CreateInstanceMetadata>() {
        @java.lang.Override
        public CreateInstanceMetadata parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new CreateInstanceMetadata(input, extensionRegistry);
        }
      };

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

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

  @java.lang.Override
  public com.google.bigtable.admin.v2.CreateInstanceMetadata getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }
}
