/*
 * 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/dataflow/v1beta3/templates.proto

package com.google.dataflow.v1beta3;

/**
 *
 *
 * <pre>
 * The environment values to set at runtime.
 * </pre>
 *
 * Protobuf type {@code google.dataflow.v1beta3.RuntimeEnvironment}
 */
public final class RuntimeEnvironment extends com.google.protobuf.GeneratedMessageV3
    implements
    // @@protoc_insertion_point(message_implements:google.dataflow.v1beta3.RuntimeEnvironment)
    RuntimeEnvironmentOrBuilder {
  private static final long serialVersionUID = 0L;
  // Use RuntimeEnvironment.newBuilder() to construct.
  private RuntimeEnvironment(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
    super(builder);
  }

  private RuntimeEnvironment() {
    zone_ = "";
    serviceAccountEmail_ = "";
    tempLocation_ = "";
    machineType_ = "";
    additionalExperiments_ = com.google.protobuf.LazyStringArrayList.EMPTY;
    network_ = "";
    subnetwork_ = "";
    kmsKeyName_ = "";
    ipConfiguration_ = 0;
    workerRegion_ = "";
    workerZone_ = "";
  }

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

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

  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
    return com.google.dataflow.v1beta3.TemplatesProto
        .internal_static_google_dataflow_v1beta3_RuntimeEnvironment_descriptor;
  }

  @SuppressWarnings({"rawtypes"})
  @java.lang.Override
  protected com.google.protobuf.MapField internalGetMapField(int number) {
    switch (number) {
      case 10:
        return internalGetAdditionalUserLabels();
      default:
        throw new RuntimeException("Invalid map field number: " + number);
    }
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.google.dataflow.v1beta3.TemplatesProto
        .internal_static_google_dataflow_v1beta3_RuntimeEnvironment_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.google.dataflow.v1beta3.RuntimeEnvironment.class,
            com.google.dataflow.v1beta3.RuntimeEnvironment.Builder.class);
  }

  public static final int NUM_WORKERS_FIELD_NUMBER = 11;
  private int numWorkers_;
  /**
   *
   *
   * <pre>
   * The initial number of Google Compute Engine instnaces for the job.
   * </pre>
   *
   * <code>int32 num_workers = 11;</code>
   *
   * @return The numWorkers.
   */
  @java.lang.Override
  public int getNumWorkers() {
    return numWorkers_;
  }

  public static final int MAX_WORKERS_FIELD_NUMBER = 1;
  private int maxWorkers_;
  /**
   *
   *
   * <pre>
   * The maximum number of Google Compute Engine instances to be made
   * available to your pipeline during execution, from 1 to 1000.
   * </pre>
   *
   * <code>int32 max_workers = 1;</code>
   *
   * @return The maxWorkers.
   */
  @java.lang.Override
  public int getMaxWorkers() {
    return maxWorkers_;
  }

  public static final int ZONE_FIELD_NUMBER = 2;
  private volatile java.lang.Object zone_;
  /**
   *
   *
   * <pre>
   * The Compute Engine [availability
   * zone](https://cloud.google.com/compute/docs/regions-zones/regions-zones)
   * for launching worker instances to run your pipeline.
   * In the future, worker_zone will take precedence.
   * </pre>
   *
   * <code>string zone = 2;</code>
   *
   * @return The zone.
   */
  @java.lang.Override
  public java.lang.String getZone() {
    java.lang.Object ref = zone_;
    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();
      zone_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * The Compute Engine [availability
   * zone](https://cloud.google.com/compute/docs/regions-zones/regions-zones)
   * for launching worker instances to run your pipeline.
   * In the future, worker_zone will take precedence.
   * </pre>
   *
   * <code>string zone = 2;</code>
   *
   * @return The bytes for zone.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getZoneBytes() {
    java.lang.Object ref = zone_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      zone_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int SERVICE_ACCOUNT_EMAIL_FIELD_NUMBER = 3;
  private volatile java.lang.Object serviceAccountEmail_;
  /**
   *
   *
   * <pre>
   * The email address of the service account to run the job as.
   * </pre>
   *
   * <code>string service_account_email = 3;</code>
   *
   * @return The serviceAccountEmail.
   */
  @java.lang.Override
  public java.lang.String getServiceAccountEmail() {
    java.lang.Object ref = serviceAccountEmail_;
    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();
      serviceAccountEmail_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * The email address of the service account to run the job as.
   * </pre>
   *
   * <code>string service_account_email = 3;</code>
   *
   * @return The bytes for serviceAccountEmail.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getServiceAccountEmailBytes() {
    java.lang.Object ref = serviceAccountEmail_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      serviceAccountEmail_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int TEMP_LOCATION_FIELD_NUMBER = 4;
  private volatile java.lang.Object tempLocation_;
  /**
   *
   *
   * <pre>
   * The Cloud Storage path to use for temporary files.
   * Must be a valid Cloud Storage URL, beginning with `gs://`.
   * </pre>
   *
   * <code>string temp_location = 4;</code>
   *
   * @return The tempLocation.
   */
  @java.lang.Override
  public java.lang.String getTempLocation() {
    java.lang.Object ref = tempLocation_;
    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();
      tempLocation_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * The Cloud Storage path to use for temporary files.
   * Must be a valid Cloud Storage URL, beginning with `gs://`.
   * </pre>
   *
   * <code>string temp_location = 4;</code>
   *
   * @return The bytes for tempLocation.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getTempLocationBytes() {
    java.lang.Object ref = tempLocation_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      tempLocation_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int BYPASS_TEMP_DIR_VALIDATION_FIELD_NUMBER = 5;
  private boolean bypassTempDirValidation_;
  /**
   *
   *
   * <pre>
   * Whether to bypass the safety checks for the job's temporary directory.
   * Use with caution.
   * </pre>
   *
   * <code>bool bypass_temp_dir_validation = 5;</code>
   *
   * @return The bypassTempDirValidation.
   */
  @java.lang.Override
  public boolean getBypassTempDirValidation() {
    return bypassTempDirValidation_;
  }

  public static final int MACHINE_TYPE_FIELD_NUMBER = 6;
  private volatile java.lang.Object machineType_;
  /**
   *
   *
   * <pre>
   * The machine type to use for the job. Defaults to the value from the
   * template if not specified.
   * </pre>
   *
   * <code>string machine_type = 6;</code>
   *
   * @return The machineType.
   */
  @java.lang.Override
  public java.lang.String getMachineType() {
    java.lang.Object ref = machineType_;
    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();
      machineType_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * The machine type to use for the job. Defaults to the value from the
   * template if not specified.
   * </pre>
   *
   * <code>string machine_type = 6;</code>
   *
   * @return The bytes for machineType.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getMachineTypeBytes() {
    java.lang.Object ref = machineType_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      machineType_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int ADDITIONAL_EXPERIMENTS_FIELD_NUMBER = 7;
  private com.google.protobuf.LazyStringList additionalExperiments_;
  /**
   *
   *
   * <pre>
   * Additional experiment flags for the job, specified with the
   * `--experiments` option.
   * </pre>
   *
   * <code>repeated string additional_experiments = 7;</code>
   *
   * @return A list containing the additionalExperiments.
   */
  public com.google.protobuf.ProtocolStringList getAdditionalExperimentsList() {
    return additionalExperiments_;
  }
  /**
   *
   *
   * <pre>
   * Additional experiment flags for the job, specified with the
   * `--experiments` option.
   * </pre>
   *
   * <code>repeated string additional_experiments = 7;</code>
   *
   * @return The count of additionalExperiments.
   */
  public int getAdditionalExperimentsCount() {
    return additionalExperiments_.size();
  }
  /**
   *
   *
   * <pre>
   * Additional experiment flags for the job, specified with the
   * `--experiments` option.
   * </pre>
   *
   * <code>repeated string additional_experiments = 7;</code>
   *
   * @param index The index of the element to return.
   * @return The additionalExperiments at the given index.
   */
  public java.lang.String getAdditionalExperiments(int index) {
    return additionalExperiments_.get(index);
  }
  /**
   *
   *
   * <pre>
   * Additional experiment flags for the job, specified with the
   * `--experiments` option.
   * </pre>
   *
   * <code>repeated string additional_experiments = 7;</code>
   *
   * @param index The index of the value to return.
   * @return The bytes of the additionalExperiments at the given index.
   */
  public com.google.protobuf.ByteString getAdditionalExperimentsBytes(int index) {
    return additionalExperiments_.getByteString(index);
  }

  public static final int NETWORK_FIELD_NUMBER = 8;
  private volatile java.lang.Object network_;
  /**
   *
   *
   * <pre>
   * Network to which VMs will be assigned.  If empty or unspecified,
   * the service will use the network "default".
   * </pre>
   *
   * <code>string network = 8;</code>
   *
   * @return The network.
   */
  @java.lang.Override
  public java.lang.String getNetwork() {
    java.lang.Object ref = network_;
    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();
      network_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * Network to which VMs will be assigned.  If empty or unspecified,
   * the service will use the network "default".
   * </pre>
   *
   * <code>string network = 8;</code>
   *
   * @return The bytes for network.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getNetworkBytes() {
    java.lang.Object ref = network_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      network_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int SUBNETWORK_FIELD_NUMBER = 9;
  private volatile java.lang.Object subnetwork_;
  /**
   *
   *
   * <pre>
   * Subnetwork to which VMs will be assigned, if desired. You can specify a
   * subnetwork using either a complete URL or an abbreviated path. Expected to
   * be of the form
   * "https://www.googleapis.com/compute/v1/projects/HOST_PROJECT_ID/regions/REGION/subnetworks/SUBNETWORK"
   * or "regions/REGION/subnetworks/SUBNETWORK". If the subnetwork is located in
   * a Shared VPC network, you must use the complete URL.
   * </pre>
   *
   * <code>string subnetwork = 9;</code>
   *
   * @return The subnetwork.
   */
  @java.lang.Override
  public java.lang.String getSubnetwork() {
    java.lang.Object ref = subnetwork_;
    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();
      subnetwork_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * Subnetwork to which VMs will be assigned, if desired. You can specify a
   * subnetwork using either a complete URL or an abbreviated path. Expected to
   * be of the form
   * "https://www.googleapis.com/compute/v1/projects/HOST_PROJECT_ID/regions/REGION/subnetworks/SUBNETWORK"
   * or "regions/REGION/subnetworks/SUBNETWORK". If the subnetwork is located in
   * a Shared VPC network, you must use the complete URL.
   * </pre>
   *
   * <code>string subnetwork = 9;</code>
   *
   * @return The bytes for subnetwork.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getSubnetworkBytes() {
    java.lang.Object ref = subnetwork_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      subnetwork_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int ADDITIONAL_USER_LABELS_FIELD_NUMBER = 10;

  private static final class AdditionalUserLabelsDefaultEntryHolder {
    static final com.google.protobuf.MapEntry<java.lang.String, java.lang.String> defaultEntry =
        com.google.protobuf.MapEntry.<java.lang.String, java.lang.String>newDefaultInstance(
            com.google.dataflow.v1beta3.TemplatesProto
                .internal_static_google_dataflow_v1beta3_RuntimeEnvironment_AdditionalUserLabelsEntry_descriptor,
            com.google.protobuf.WireFormat.FieldType.STRING,
            "",
            com.google.protobuf.WireFormat.FieldType.STRING,
            "");
  }

  private com.google.protobuf.MapField<java.lang.String, java.lang.String> additionalUserLabels_;

  private com.google.protobuf.MapField<java.lang.String, java.lang.String>
      internalGetAdditionalUserLabels() {
    if (additionalUserLabels_ == null) {
      return com.google.protobuf.MapField.emptyMapField(
          AdditionalUserLabelsDefaultEntryHolder.defaultEntry);
    }
    return additionalUserLabels_;
  }

  public int getAdditionalUserLabelsCount() {
    return internalGetAdditionalUserLabels().getMap().size();
  }
  /**
   *
   *
   * <pre>
   * Additional user labels to be specified for the job.
   * Keys and values should follow the restrictions specified in the [labeling
   * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
   * page.
   * An object containing a list of "key": value pairs.
   * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
   * </pre>
   *
   * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
   */
  @java.lang.Override
  public boolean containsAdditionalUserLabels(java.lang.String key) {
    if (key == null) {
      throw new NullPointerException("map key");
    }
    return internalGetAdditionalUserLabels().getMap().containsKey(key);
  }
  /** Use {@link #getAdditionalUserLabelsMap()} instead. */
  @java.lang.Override
  @java.lang.Deprecated
  public java.util.Map<java.lang.String, java.lang.String> getAdditionalUserLabels() {
    return getAdditionalUserLabelsMap();
  }
  /**
   *
   *
   * <pre>
   * Additional user labels to be specified for the job.
   * Keys and values should follow the restrictions specified in the [labeling
   * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
   * page.
   * An object containing a list of "key": value pairs.
   * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
   * </pre>
   *
   * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
   */
  @java.lang.Override
  public java.util.Map<java.lang.String, java.lang.String> getAdditionalUserLabelsMap() {
    return internalGetAdditionalUserLabels().getMap();
  }
  /**
   *
   *
   * <pre>
   * Additional user labels to be specified for the job.
   * Keys and values should follow the restrictions specified in the [labeling
   * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
   * page.
   * An object containing a list of "key": value pairs.
   * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
   * </pre>
   *
   * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
   */
  @java.lang.Override
  public java.lang.String getAdditionalUserLabelsOrDefault(
      java.lang.String key, java.lang.String defaultValue) {
    if (key == null) {
      throw new NullPointerException("map key");
    }
    java.util.Map<java.lang.String, java.lang.String> map =
        internalGetAdditionalUserLabels().getMap();
    return map.containsKey(key) ? map.get(key) : defaultValue;
  }
  /**
   *
   *
   * <pre>
   * Additional user labels to be specified for the job.
   * Keys and values should follow the restrictions specified in the [labeling
   * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
   * page.
   * An object containing a list of "key": value pairs.
   * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
   * </pre>
   *
   * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
   */
  @java.lang.Override
  public java.lang.String getAdditionalUserLabelsOrThrow(java.lang.String key) {
    if (key == null) {
      throw new NullPointerException("map key");
    }
    java.util.Map<java.lang.String, java.lang.String> map =
        internalGetAdditionalUserLabels().getMap();
    if (!map.containsKey(key)) {
      throw new java.lang.IllegalArgumentException();
    }
    return map.get(key);
  }

  public static final int KMS_KEY_NAME_FIELD_NUMBER = 12;
  private volatile java.lang.Object kmsKeyName_;
  /**
   *
   *
   * <pre>
   * Name for the Cloud KMS key for the job.
   * Key format is:
   * projects/&lt;project&gt;/locations/&lt;location&gt;/keyRings/&lt;keyring&gt;/cryptoKeys/&lt;key&gt;
   * </pre>
   *
   * <code>string kms_key_name = 12;</code>
   *
   * @return The kmsKeyName.
   */
  @java.lang.Override
  public java.lang.String getKmsKeyName() {
    java.lang.Object ref = kmsKeyName_;
    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();
      kmsKeyName_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * Name for the Cloud KMS key for the job.
   * Key format is:
   * projects/&lt;project&gt;/locations/&lt;location&gt;/keyRings/&lt;keyring&gt;/cryptoKeys/&lt;key&gt;
   * </pre>
   *
   * <code>string kms_key_name = 12;</code>
   *
   * @return The bytes for kmsKeyName.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getKmsKeyNameBytes() {
    java.lang.Object ref = kmsKeyName_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      kmsKeyName_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int IP_CONFIGURATION_FIELD_NUMBER = 14;
  private int ipConfiguration_;
  /**
   *
   *
   * <pre>
   * Configuration for VM IPs.
   * </pre>
   *
   * <code>.google.dataflow.v1beta3.WorkerIPAddressConfiguration ip_configuration = 14;</code>
   *
   * @return The enum numeric value on the wire for ipConfiguration.
   */
  @java.lang.Override
  public int getIpConfigurationValue() {
    return ipConfiguration_;
  }
  /**
   *
   *
   * <pre>
   * Configuration for VM IPs.
   * </pre>
   *
   * <code>.google.dataflow.v1beta3.WorkerIPAddressConfiguration ip_configuration = 14;</code>
   *
   * @return The ipConfiguration.
   */
  @java.lang.Override
  public com.google.dataflow.v1beta3.WorkerIPAddressConfiguration getIpConfiguration() {
    @SuppressWarnings("deprecation")
    com.google.dataflow.v1beta3.WorkerIPAddressConfiguration result =
        com.google.dataflow.v1beta3.WorkerIPAddressConfiguration.valueOf(ipConfiguration_);
    return result == null
        ? com.google.dataflow.v1beta3.WorkerIPAddressConfiguration.UNRECOGNIZED
        : result;
  }

  public static final int WORKER_REGION_FIELD_NUMBER = 15;
  private volatile java.lang.Object workerRegion_;
  /**
   *
   *
   * <pre>
   * The Compute Engine region
   * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
   * which worker processing should occur, e.g. "us-west1". Mutually exclusive
   * with worker_zone. If neither worker_region nor worker_zone is specified,
   * default to the control plane's region.
   * </pre>
   *
   * <code>string worker_region = 15;</code>
   *
   * @return The workerRegion.
   */
  @java.lang.Override
  public java.lang.String getWorkerRegion() {
    java.lang.Object ref = workerRegion_;
    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();
      workerRegion_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * The Compute Engine region
   * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
   * which worker processing should occur, e.g. "us-west1". Mutually exclusive
   * with worker_zone. If neither worker_region nor worker_zone is specified,
   * default to the control plane's region.
   * </pre>
   *
   * <code>string worker_region = 15;</code>
   *
   * @return The bytes for workerRegion.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getWorkerRegionBytes() {
    java.lang.Object ref = workerRegion_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      workerRegion_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int WORKER_ZONE_FIELD_NUMBER = 16;
  private volatile java.lang.Object workerZone_;
  /**
   *
   *
   * <pre>
   * The Compute Engine zone
   * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
   * which worker processing should occur, e.g. "us-west1-a". Mutually exclusive
   * with worker_region. If neither worker_region nor worker_zone is specified,
   * a zone in the control plane's region is chosen based on available capacity.
   * If both `worker_zone` and `zone` are set, `worker_zone` takes precedence.
   * </pre>
   *
   * <code>string worker_zone = 16;</code>
   *
   * @return The workerZone.
   */
  @java.lang.Override
  public java.lang.String getWorkerZone() {
    java.lang.Object ref = workerZone_;
    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();
      workerZone_ = s;
      return s;
    }
  }
  /**
   *
   *
   * <pre>
   * The Compute Engine zone
   * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
   * which worker processing should occur, e.g. "us-west1-a". Mutually exclusive
   * with worker_region. If neither worker_region nor worker_zone is specified,
   * a zone in the control plane's region is chosen based on available capacity.
   * If both `worker_zone` and `zone` are set, `worker_zone` takes precedence.
   * </pre>
   *
   * <code>string worker_zone = 16;</code>
   *
   * @return The bytes for workerZone.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getWorkerZoneBytes() {
    java.lang.Object ref = workerZone_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b =
          com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
      workerZone_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int ENABLE_STREAMING_ENGINE_FIELD_NUMBER = 17;
  private boolean enableStreamingEngine_;
  /**
   *
   *
   * <pre>
   * Whether to enable Streaming Engine for the job.
   * </pre>
   *
   * <code>bool enable_streaming_engine = 17;</code>
   *
   * @return The enableStreamingEngine.
   */
  @java.lang.Override
  public boolean getEnableStreamingEngine() {
    return enableStreamingEngine_;
  }

  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 (maxWorkers_ != 0) {
      output.writeInt32(1, maxWorkers_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(zone_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 2, zone_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccountEmail_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 3, serviceAccountEmail_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(tempLocation_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 4, tempLocation_);
    }
    if (bypassTempDirValidation_ != false) {
      output.writeBool(5, bypassTempDirValidation_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(machineType_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 6, machineType_);
    }
    for (int i = 0; i < additionalExperiments_.size(); i++) {
      com.google.protobuf.GeneratedMessageV3.writeString(
          output, 7, additionalExperiments_.getRaw(i));
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(network_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 8, network_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subnetwork_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 9, subnetwork_);
    }
    com.google.protobuf.GeneratedMessageV3.serializeStringMapTo(
        output,
        internalGetAdditionalUserLabels(),
        AdditionalUserLabelsDefaultEntryHolder.defaultEntry,
        10);
    if (numWorkers_ != 0) {
      output.writeInt32(11, numWorkers_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 12, kmsKeyName_);
    }
    if (ipConfiguration_
        != com.google.dataflow.v1beta3.WorkerIPAddressConfiguration.WORKER_IP_UNSPECIFIED
            .getNumber()) {
      output.writeEnum(14, ipConfiguration_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerRegion_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 15, workerRegion_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerZone_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 16, workerZone_);
    }
    if (enableStreamingEngine_ != false) {
      output.writeBool(17, enableStreamingEngine_);
    }
    getUnknownFields().writeTo(output);
  }

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

    size = 0;
    if (maxWorkers_ != 0) {
      size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, maxWorkers_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(zone_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, zone_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccountEmail_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, serviceAccountEmail_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(tempLocation_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, tempLocation_);
    }
    if (bypassTempDirValidation_ != false) {
      size += com.google.protobuf.CodedOutputStream.computeBoolSize(5, bypassTempDirValidation_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(machineType_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, machineType_);
    }
    {
      int dataSize = 0;
      for (int i = 0; i < additionalExperiments_.size(); i++) {
        dataSize += computeStringSizeNoTag(additionalExperiments_.getRaw(i));
      }
      size += dataSize;
      size += 1 * getAdditionalExperimentsList().size();
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(network_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, network_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subnetwork_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, subnetwork_);
    }
    for (java.util.Map.Entry<java.lang.String, java.lang.String> entry :
        internalGetAdditionalUserLabels().getMap().entrySet()) {
      com.google.protobuf.MapEntry<java.lang.String, java.lang.String> additionalUserLabels__ =
          AdditionalUserLabelsDefaultEntryHolder.defaultEntry
              .newBuilderForType()
              .setKey(entry.getKey())
              .setValue(entry.getValue())
              .build();
      size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, additionalUserLabels__);
    }
    if (numWorkers_ != 0) {
      size += com.google.protobuf.CodedOutputStream.computeInt32Size(11, numWorkers_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(12, kmsKeyName_);
    }
    if (ipConfiguration_
        != com.google.dataflow.v1beta3.WorkerIPAddressConfiguration.WORKER_IP_UNSPECIFIED
            .getNumber()) {
      size += com.google.protobuf.CodedOutputStream.computeEnumSize(14, ipConfiguration_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerRegion_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(15, workerRegion_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerZone_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(16, workerZone_);
    }
    if (enableStreamingEngine_ != false) {
      size += com.google.protobuf.CodedOutputStream.computeBoolSize(17, enableStreamingEngine_);
    }
    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 com.google.dataflow.v1beta3.RuntimeEnvironment)) {
      return super.equals(obj);
    }
    com.google.dataflow.v1beta3.RuntimeEnvironment other =
        (com.google.dataflow.v1beta3.RuntimeEnvironment) obj;

    if (getNumWorkers() != other.getNumWorkers()) return false;
    if (getMaxWorkers() != other.getMaxWorkers()) return false;
    if (!getZone().equals(other.getZone())) return false;
    if (!getServiceAccountEmail().equals(other.getServiceAccountEmail())) return false;
    if (!getTempLocation().equals(other.getTempLocation())) return false;
    if (getBypassTempDirValidation() != other.getBypassTempDirValidation()) return false;
    if (!getMachineType().equals(other.getMachineType())) return false;
    if (!getAdditionalExperimentsList().equals(other.getAdditionalExperimentsList())) return false;
    if (!getNetwork().equals(other.getNetwork())) return false;
    if (!getSubnetwork().equals(other.getSubnetwork())) return false;
    if (!internalGetAdditionalUserLabels().equals(other.internalGetAdditionalUserLabels()))
      return false;
    if (!getKmsKeyName().equals(other.getKmsKeyName())) return false;
    if (ipConfiguration_ != other.ipConfiguration_) return false;
    if (!getWorkerRegion().equals(other.getWorkerRegion())) return false;
    if (!getWorkerZone().equals(other.getWorkerZone())) return false;
    if (getEnableStreamingEngine() != other.getEnableStreamingEngine()) 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) + NUM_WORKERS_FIELD_NUMBER;
    hash = (53 * hash) + getNumWorkers();
    hash = (37 * hash) + MAX_WORKERS_FIELD_NUMBER;
    hash = (53 * hash) + getMaxWorkers();
    hash = (37 * hash) + ZONE_FIELD_NUMBER;
    hash = (53 * hash) + getZone().hashCode();
    hash = (37 * hash) + SERVICE_ACCOUNT_EMAIL_FIELD_NUMBER;
    hash = (53 * hash) + getServiceAccountEmail().hashCode();
    hash = (37 * hash) + TEMP_LOCATION_FIELD_NUMBER;
    hash = (53 * hash) + getTempLocation().hashCode();
    hash = (37 * hash) + BYPASS_TEMP_DIR_VALIDATION_FIELD_NUMBER;
    hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getBypassTempDirValidation());
    hash = (37 * hash) + MACHINE_TYPE_FIELD_NUMBER;
    hash = (53 * hash) + getMachineType().hashCode();
    if (getAdditionalExperimentsCount() > 0) {
      hash = (37 * hash) + ADDITIONAL_EXPERIMENTS_FIELD_NUMBER;
      hash = (53 * hash) + getAdditionalExperimentsList().hashCode();
    }
    hash = (37 * hash) + NETWORK_FIELD_NUMBER;
    hash = (53 * hash) + getNetwork().hashCode();
    hash = (37 * hash) + SUBNETWORK_FIELD_NUMBER;
    hash = (53 * hash) + getSubnetwork().hashCode();
    if (!internalGetAdditionalUserLabels().getMap().isEmpty()) {
      hash = (37 * hash) + ADDITIONAL_USER_LABELS_FIELD_NUMBER;
      hash = (53 * hash) + internalGetAdditionalUserLabels().hashCode();
    }
    hash = (37 * hash) + KMS_KEY_NAME_FIELD_NUMBER;
    hash = (53 * hash) + getKmsKeyName().hashCode();
    hash = (37 * hash) + IP_CONFIGURATION_FIELD_NUMBER;
    hash = (53 * hash) + ipConfiguration_;
    hash = (37 * hash) + WORKER_REGION_FIELD_NUMBER;
    hash = (53 * hash) + getWorkerRegion().hashCode();
    hash = (37 * hash) + WORKER_ZONE_FIELD_NUMBER;
    hash = (53 * hash) + getWorkerZone().hashCode();
    hash = (37 * hash) + ENABLE_STREAMING_ENGINE_FIELD_NUMBER;
    hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getEnableStreamingEngine());
    hash = (29 * hash) + getUnknownFields().hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment parseFrom(java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment parseFrom(
      java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment 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.dataflow.v1beta3.RuntimeEnvironment parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment parseFrom(
      byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment 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.dataflow.v1beta3.RuntimeEnvironment parseDelimitedFrom(
      java.io.InputStream input) throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment 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.dataflow.v1beta3.RuntimeEnvironment parseFrom(
      com.google.protobuf.CodedInputStream input) throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment 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.dataflow.v1beta3.RuntimeEnvironment 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 environment values to set at runtime.
   * </pre>
   *
   * Protobuf type {@code google.dataflow.v1beta3.RuntimeEnvironment}
   */
  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder>
      implements
      // @@protoc_insertion_point(builder_implements:google.dataflow.v1beta3.RuntimeEnvironment)
      com.google.dataflow.v1beta3.RuntimeEnvironmentOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
      return com.google.dataflow.v1beta3.TemplatesProto
          .internal_static_google_dataflow_v1beta3_RuntimeEnvironment_descriptor;
    }

    @SuppressWarnings({"rawtypes"})
    protected com.google.protobuf.MapField internalGetMapField(int number) {
      switch (number) {
        case 10:
          return internalGetAdditionalUserLabels();
        default:
          throw new RuntimeException("Invalid map field number: " + number);
      }
    }

    @SuppressWarnings({"rawtypes"})
    protected com.google.protobuf.MapField internalGetMutableMapField(int number) {
      switch (number) {
        case 10:
          return internalGetMutableAdditionalUserLabels();
        default:
          throw new RuntimeException("Invalid map field number: " + number);
      }
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.dataflow.v1beta3.TemplatesProto
          .internal_static_google_dataflow_v1beta3_RuntimeEnvironment_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.dataflow.v1beta3.RuntimeEnvironment.class,
              com.google.dataflow.v1beta3.RuntimeEnvironment.Builder.class);
    }

    // Construct using com.google.dataflow.v1beta3.RuntimeEnvironment.newBuilder()
    private Builder() {}

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

    @java.lang.Override
    public Builder clear() {
      super.clear();
      numWorkers_ = 0;

      maxWorkers_ = 0;

      zone_ = "";

      serviceAccountEmail_ = "";

      tempLocation_ = "";

      bypassTempDirValidation_ = false;

      machineType_ = "";

      additionalExperiments_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      bitField0_ = (bitField0_ & ~0x00000001);
      network_ = "";

      subnetwork_ = "";

      internalGetMutableAdditionalUserLabels().clear();
      kmsKeyName_ = "";

      ipConfiguration_ = 0;

      workerRegion_ = "";

      workerZone_ = "";

      enableStreamingEngine_ = false;

      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
      return com.google.dataflow.v1beta3.TemplatesProto
          .internal_static_google_dataflow_v1beta3_RuntimeEnvironment_descriptor;
    }

    @java.lang.Override
    public com.google.dataflow.v1beta3.RuntimeEnvironment getDefaultInstanceForType() {
      return com.google.dataflow.v1beta3.RuntimeEnvironment.getDefaultInstance();
    }

    @java.lang.Override
    public com.google.dataflow.v1beta3.RuntimeEnvironment build() {
      com.google.dataflow.v1beta3.RuntimeEnvironment result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public com.google.dataflow.v1beta3.RuntimeEnvironment buildPartial() {
      com.google.dataflow.v1beta3.RuntimeEnvironment result =
          new com.google.dataflow.v1beta3.RuntimeEnvironment(this);
      int from_bitField0_ = bitField0_;
      result.numWorkers_ = numWorkers_;
      result.maxWorkers_ = maxWorkers_;
      result.zone_ = zone_;
      result.serviceAccountEmail_ = serviceAccountEmail_;
      result.tempLocation_ = tempLocation_;
      result.bypassTempDirValidation_ = bypassTempDirValidation_;
      result.machineType_ = machineType_;
      if (((bitField0_ & 0x00000001) != 0)) {
        additionalExperiments_ = additionalExperiments_.getUnmodifiableView();
        bitField0_ = (bitField0_ & ~0x00000001);
      }
      result.additionalExperiments_ = additionalExperiments_;
      result.network_ = network_;
      result.subnetwork_ = subnetwork_;
      result.additionalUserLabels_ = internalGetAdditionalUserLabels();
      result.additionalUserLabels_.makeImmutable();
      result.kmsKeyName_ = kmsKeyName_;
      result.ipConfiguration_ = ipConfiguration_;
      result.workerRegion_ = workerRegion_;
      result.workerZone_ = workerZone_;
      result.enableStreamingEngine_ = enableStreamingEngine_;
      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.dataflow.v1beta3.RuntimeEnvironment) {
        return mergeFrom((com.google.dataflow.v1beta3.RuntimeEnvironment) other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.google.dataflow.v1beta3.RuntimeEnvironment other) {
      if (other == com.google.dataflow.v1beta3.RuntimeEnvironment.getDefaultInstance()) return this;
      if (other.getNumWorkers() != 0) {
        setNumWorkers(other.getNumWorkers());
      }
      if (other.getMaxWorkers() != 0) {
        setMaxWorkers(other.getMaxWorkers());
      }
      if (!other.getZone().isEmpty()) {
        zone_ = other.zone_;
        onChanged();
      }
      if (!other.getServiceAccountEmail().isEmpty()) {
        serviceAccountEmail_ = other.serviceAccountEmail_;
        onChanged();
      }
      if (!other.getTempLocation().isEmpty()) {
        tempLocation_ = other.tempLocation_;
        onChanged();
      }
      if (other.getBypassTempDirValidation() != false) {
        setBypassTempDirValidation(other.getBypassTempDirValidation());
      }
      if (!other.getMachineType().isEmpty()) {
        machineType_ = other.machineType_;
        onChanged();
      }
      if (!other.additionalExperiments_.isEmpty()) {
        if (additionalExperiments_.isEmpty()) {
          additionalExperiments_ = other.additionalExperiments_;
          bitField0_ = (bitField0_ & ~0x00000001);
        } else {
          ensureAdditionalExperimentsIsMutable();
          additionalExperiments_.addAll(other.additionalExperiments_);
        }
        onChanged();
      }
      if (!other.getNetwork().isEmpty()) {
        network_ = other.network_;
        onChanged();
      }
      if (!other.getSubnetwork().isEmpty()) {
        subnetwork_ = other.subnetwork_;
        onChanged();
      }
      internalGetMutableAdditionalUserLabels().mergeFrom(other.internalGetAdditionalUserLabels());
      if (!other.getKmsKeyName().isEmpty()) {
        kmsKeyName_ = other.kmsKeyName_;
        onChanged();
      }
      if (other.ipConfiguration_ != 0) {
        setIpConfigurationValue(other.getIpConfigurationValue());
      }
      if (!other.getWorkerRegion().isEmpty()) {
        workerRegion_ = other.workerRegion_;
        onChanged();
      }
      if (!other.getWorkerZone().isEmpty()) {
        workerZone_ = other.workerZone_;
        onChanged();
      }
      if (other.getEnableStreamingEngine() != false) {
        setEnableStreamingEngine(other.getEnableStreamingEngine());
      }
      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 8:
              {
                maxWorkers_ = input.readInt32();

                break;
              } // case 8
            case 18:
              {
                zone_ = input.readStringRequireUtf8();

                break;
              } // case 18
            case 26:
              {
                serviceAccountEmail_ = input.readStringRequireUtf8();

                break;
              } // case 26
            case 34:
              {
                tempLocation_ = input.readStringRequireUtf8();

                break;
              } // case 34
            case 40:
              {
                bypassTempDirValidation_ = input.readBool();

                break;
              } // case 40
            case 50:
              {
                machineType_ = input.readStringRequireUtf8();

                break;
              } // case 50
            case 58:
              {
                java.lang.String s = input.readStringRequireUtf8();
                ensureAdditionalExperimentsIsMutable();
                additionalExperiments_.add(s);
                break;
              } // case 58
            case 66:
              {
                network_ = input.readStringRequireUtf8();

                break;
              } // case 66
            case 74:
              {
                subnetwork_ = input.readStringRequireUtf8();

                break;
              } // case 74
            case 82:
              {
                com.google.protobuf.MapEntry<java.lang.String, java.lang.String>
                    additionalUserLabels__ =
                        input.readMessage(
                            AdditionalUserLabelsDefaultEntryHolder.defaultEntry.getParserForType(),
                            extensionRegistry);
                internalGetMutableAdditionalUserLabels()
                    .getMutableMap()
                    .put(additionalUserLabels__.getKey(), additionalUserLabels__.getValue());
                break;
              } // case 82
            case 88:
              {
                numWorkers_ = input.readInt32();

                break;
              } // case 88
            case 98:
              {
                kmsKeyName_ = input.readStringRequireUtf8();

                break;
              } // case 98
            case 112:
              {
                ipConfiguration_ = input.readEnum();

                break;
              } // case 112
            case 122:
              {
                workerRegion_ = input.readStringRequireUtf8();

                break;
              } // case 122
            case 130:
              {
                workerZone_ = input.readStringRequireUtf8();

                break;
              } // case 130
            case 136:
              {
                enableStreamingEngine_ = input.readBool();

                break;
              } // case 136
            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 int numWorkers_;
    /**
     *
     *
     * <pre>
     * The initial number of Google Compute Engine instnaces for the job.
     * </pre>
     *
     * <code>int32 num_workers = 11;</code>
     *
     * @return The numWorkers.
     */
    @java.lang.Override
    public int getNumWorkers() {
      return numWorkers_;
    }
    /**
     *
     *
     * <pre>
     * The initial number of Google Compute Engine instnaces for the job.
     * </pre>
     *
     * <code>int32 num_workers = 11;</code>
     *
     * @param value The numWorkers to set.
     * @return This builder for chaining.
     */
    public Builder setNumWorkers(int value) {

      numWorkers_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The initial number of Google Compute Engine instnaces for the job.
     * </pre>
     *
     * <code>int32 num_workers = 11;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearNumWorkers() {

      numWorkers_ = 0;
      onChanged();
      return this;
    }

    private int maxWorkers_;
    /**
     *
     *
     * <pre>
     * The maximum number of Google Compute Engine instances to be made
     * available to your pipeline during execution, from 1 to 1000.
     * </pre>
     *
     * <code>int32 max_workers = 1;</code>
     *
     * @return The maxWorkers.
     */
    @java.lang.Override
    public int getMaxWorkers() {
      return maxWorkers_;
    }
    /**
     *
     *
     * <pre>
     * The maximum number of Google Compute Engine instances to be made
     * available to your pipeline during execution, from 1 to 1000.
     * </pre>
     *
     * <code>int32 max_workers = 1;</code>
     *
     * @param value The maxWorkers to set.
     * @return This builder for chaining.
     */
    public Builder setMaxWorkers(int value) {

      maxWorkers_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The maximum number of Google Compute Engine instances to be made
     * available to your pipeline during execution, from 1 to 1000.
     * </pre>
     *
     * <code>int32 max_workers = 1;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearMaxWorkers() {

      maxWorkers_ = 0;
      onChanged();
      return this;
    }

    private java.lang.Object zone_ = "";
    /**
     *
     *
     * <pre>
     * The Compute Engine [availability
     * zone](https://cloud.google.com/compute/docs/regions-zones/regions-zones)
     * for launching worker instances to run your pipeline.
     * In the future, worker_zone will take precedence.
     * </pre>
     *
     * <code>string zone = 2;</code>
     *
     * @return The zone.
     */
    public java.lang.String getZone() {
      java.lang.Object ref = zone_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        zone_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine [availability
     * zone](https://cloud.google.com/compute/docs/regions-zones/regions-zones)
     * for launching worker instances to run your pipeline.
     * In the future, worker_zone will take precedence.
     * </pre>
     *
     * <code>string zone = 2;</code>
     *
     * @return The bytes for zone.
     */
    public com.google.protobuf.ByteString getZoneBytes() {
      java.lang.Object ref = zone_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        zone_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine [availability
     * zone](https://cloud.google.com/compute/docs/regions-zones/regions-zones)
     * for launching worker instances to run your pipeline.
     * In the future, worker_zone will take precedence.
     * </pre>
     *
     * <code>string zone = 2;</code>
     *
     * @param value The zone to set.
     * @return This builder for chaining.
     */
    public Builder setZone(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      zone_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine [availability
     * zone](https://cloud.google.com/compute/docs/regions-zones/regions-zones)
     * for launching worker instances to run your pipeline.
     * In the future, worker_zone will take precedence.
     * </pre>
     *
     * <code>string zone = 2;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearZone() {

      zone_ = getDefaultInstance().getZone();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine [availability
     * zone](https://cloud.google.com/compute/docs/regions-zones/regions-zones)
     * for launching worker instances to run your pipeline.
     * In the future, worker_zone will take precedence.
     * </pre>
     *
     * <code>string zone = 2;</code>
     *
     * @param value The bytes for zone to set.
     * @return This builder for chaining.
     */
    public Builder setZoneBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      zone_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object serviceAccountEmail_ = "";
    /**
     *
     *
     * <pre>
     * The email address of the service account to run the job as.
     * </pre>
     *
     * <code>string service_account_email = 3;</code>
     *
     * @return The serviceAccountEmail.
     */
    public java.lang.String getServiceAccountEmail() {
      java.lang.Object ref = serviceAccountEmail_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        serviceAccountEmail_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The email address of the service account to run the job as.
     * </pre>
     *
     * <code>string service_account_email = 3;</code>
     *
     * @return The bytes for serviceAccountEmail.
     */
    public com.google.protobuf.ByteString getServiceAccountEmailBytes() {
      java.lang.Object ref = serviceAccountEmail_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        serviceAccountEmail_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The email address of the service account to run the job as.
     * </pre>
     *
     * <code>string service_account_email = 3;</code>
     *
     * @param value The serviceAccountEmail to set.
     * @return This builder for chaining.
     */
    public Builder setServiceAccountEmail(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      serviceAccountEmail_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The email address of the service account to run the job as.
     * </pre>
     *
     * <code>string service_account_email = 3;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearServiceAccountEmail() {

      serviceAccountEmail_ = getDefaultInstance().getServiceAccountEmail();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The email address of the service account to run the job as.
     * </pre>
     *
     * <code>string service_account_email = 3;</code>
     *
     * @param value The bytes for serviceAccountEmail to set.
     * @return This builder for chaining.
     */
    public Builder setServiceAccountEmailBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      serviceAccountEmail_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object tempLocation_ = "";
    /**
     *
     *
     * <pre>
     * The Cloud Storage path to use for temporary files.
     * Must be a valid Cloud Storage URL, beginning with `gs://`.
     * </pre>
     *
     * <code>string temp_location = 4;</code>
     *
     * @return The tempLocation.
     */
    public java.lang.String getTempLocation() {
      java.lang.Object ref = tempLocation_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        tempLocation_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The Cloud Storage path to use for temporary files.
     * Must be a valid Cloud Storage URL, beginning with `gs://`.
     * </pre>
     *
     * <code>string temp_location = 4;</code>
     *
     * @return The bytes for tempLocation.
     */
    public com.google.protobuf.ByteString getTempLocationBytes() {
      java.lang.Object ref = tempLocation_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        tempLocation_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The Cloud Storage path to use for temporary files.
     * Must be a valid Cloud Storage URL, beginning with `gs://`.
     * </pre>
     *
     * <code>string temp_location = 4;</code>
     *
     * @param value The tempLocation to set.
     * @return This builder for chaining.
     */
    public Builder setTempLocation(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      tempLocation_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The Cloud Storage path to use for temporary files.
     * Must be a valid Cloud Storage URL, beginning with `gs://`.
     * </pre>
     *
     * <code>string temp_location = 4;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearTempLocation() {

      tempLocation_ = getDefaultInstance().getTempLocation();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The Cloud Storage path to use for temporary files.
     * Must be a valid Cloud Storage URL, beginning with `gs://`.
     * </pre>
     *
     * <code>string temp_location = 4;</code>
     *
     * @param value The bytes for tempLocation to set.
     * @return This builder for chaining.
     */
    public Builder setTempLocationBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      tempLocation_ = value;
      onChanged();
      return this;
    }

    private boolean bypassTempDirValidation_;
    /**
     *
     *
     * <pre>
     * Whether to bypass the safety checks for the job's temporary directory.
     * Use with caution.
     * </pre>
     *
     * <code>bool bypass_temp_dir_validation = 5;</code>
     *
     * @return The bypassTempDirValidation.
     */
    @java.lang.Override
    public boolean getBypassTempDirValidation() {
      return bypassTempDirValidation_;
    }
    /**
     *
     *
     * <pre>
     * Whether to bypass the safety checks for the job's temporary directory.
     * Use with caution.
     * </pre>
     *
     * <code>bool bypass_temp_dir_validation = 5;</code>
     *
     * @param value The bypassTempDirValidation to set.
     * @return This builder for chaining.
     */
    public Builder setBypassTempDirValidation(boolean value) {

      bypassTempDirValidation_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Whether to bypass the safety checks for the job's temporary directory.
     * Use with caution.
     * </pre>
     *
     * <code>bool bypass_temp_dir_validation = 5;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearBypassTempDirValidation() {

      bypassTempDirValidation_ = false;
      onChanged();
      return this;
    }

    private java.lang.Object machineType_ = "";
    /**
     *
     *
     * <pre>
     * The machine type to use for the job. Defaults to the value from the
     * template if not specified.
     * </pre>
     *
     * <code>string machine_type = 6;</code>
     *
     * @return The machineType.
     */
    public java.lang.String getMachineType() {
      java.lang.Object ref = machineType_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        machineType_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The machine type to use for the job. Defaults to the value from the
     * template if not specified.
     * </pre>
     *
     * <code>string machine_type = 6;</code>
     *
     * @return The bytes for machineType.
     */
    public com.google.protobuf.ByteString getMachineTypeBytes() {
      java.lang.Object ref = machineType_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        machineType_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The machine type to use for the job. Defaults to the value from the
     * template if not specified.
     * </pre>
     *
     * <code>string machine_type = 6;</code>
     *
     * @param value The machineType to set.
     * @return This builder for chaining.
     */
    public Builder setMachineType(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      machineType_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The machine type to use for the job. Defaults to the value from the
     * template if not specified.
     * </pre>
     *
     * <code>string machine_type = 6;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearMachineType() {

      machineType_ = getDefaultInstance().getMachineType();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The machine type to use for the job. Defaults to the value from the
     * template if not specified.
     * </pre>
     *
     * <code>string machine_type = 6;</code>
     *
     * @param value The bytes for machineType to set.
     * @return This builder for chaining.
     */
    public Builder setMachineTypeBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      machineType_ = value;
      onChanged();
      return this;
    }

    private com.google.protobuf.LazyStringList additionalExperiments_ =
        com.google.protobuf.LazyStringArrayList.EMPTY;

    private void ensureAdditionalExperimentsIsMutable() {
      if (!((bitField0_ & 0x00000001) != 0)) {
        additionalExperiments_ =
            new com.google.protobuf.LazyStringArrayList(additionalExperiments_);
        bitField0_ |= 0x00000001;
      }
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @return A list containing the additionalExperiments.
     */
    public com.google.protobuf.ProtocolStringList getAdditionalExperimentsList() {
      return additionalExperiments_.getUnmodifiableView();
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @return The count of additionalExperiments.
     */
    public int getAdditionalExperimentsCount() {
      return additionalExperiments_.size();
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @param index The index of the element to return.
     * @return The additionalExperiments at the given index.
     */
    public java.lang.String getAdditionalExperiments(int index) {
      return additionalExperiments_.get(index);
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @param index The index of the value to return.
     * @return The bytes of the additionalExperiments at the given index.
     */
    public com.google.protobuf.ByteString getAdditionalExperimentsBytes(int index) {
      return additionalExperiments_.getByteString(index);
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @param index The index to set the value at.
     * @param value The additionalExperiments to set.
     * @return This builder for chaining.
     */
    public Builder setAdditionalExperiments(int index, java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureAdditionalExperimentsIsMutable();
      additionalExperiments_.set(index, value);
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @param value The additionalExperiments to add.
     * @return This builder for chaining.
     */
    public Builder addAdditionalExperiments(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }
      ensureAdditionalExperimentsIsMutable();
      additionalExperiments_.add(value);
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @param values The additionalExperiments to add.
     * @return This builder for chaining.
     */
    public Builder addAllAdditionalExperiments(java.lang.Iterable<java.lang.String> values) {
      ensureAdditionalExperimentsIsMutable();
      com.google.protobuf.AbstractMessageLite.Builder.addAll(values, additionalExperiments_);
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearAdditionalExperiments() {
      additionalExperiments_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      bitField0_ = (bitField0_ & ~0x00000001);
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Additional experiment flags for the job, specified with the
     * `--experiments` option.
     * </pre>
     *
     * <code>repeated string additional_experiments = 7;</code>
     *
     * @param value The bytes of the additionalExperiments to add.
     * @return This builder for chaining.
     */
    public Builder addAdditionalExperimentsBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);
      ensureAdditionalExperimentsIsMutable();
      additionalExperiments_.add(value);
      onChanged();
      return this;
    }

    private java.lang.Object network_ = "";
    /**
     *
     *
     * <pre>
     * Network to which VMs will be assigned.  If empty or unspecified,
     * the service will use the network "default".
     * </pre>
     *
     * <code>string network = 8;</code>
     *
     * @return The network.
     */
    public java.lang.String getNetwork() {
      java.lang.Object ref = network_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        network_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * Network to which VMs will be assigned.  If empty or unspecified,
     * the service will use the network "default".
     * </pre>
     *
     * <code>string network = 8;</code>
     *
     * @return The bytes for network.
     */
    public com.google.protobuf.ByteString getNetworkBytes() {
      java.lang.Object ref = network_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        network_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * Network to which VMs will be assigned.  If empty or unspecified,
     * the service will use the network "default".
     * </pre>
     *
     * <code>string network = 8;</code>
     *
     * @param value The network to set.
     * @return This builder for chaining.
     */
    public Builder setNetwork(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      network_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Network to which VMs will be assigned.  If empty or unspecified,
     * the service will use the network "default".
     * </pre>
     *
     * <code>string network = 8;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearNetwork() {

      network_ = getDefaultInstance().getNetwork();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Network to which VMs will be assigned.  If empty or unspecified,
     * the service will use the network "default".
     * </pre>
     *
     * <code>string network = 8;</code>
     *
     * @param value The bytes for network to set.
     * @return This builder for chaining.
     */
    public Builder setNetworkBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      network_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object subnetwork_ = "";
    /**
     *
     *
     * <pre>
     * Subnetwork to which VMs will be assigned, if desired. You can specify a
     * subnetwork using either a complete URL or an abbreviated path. Expected to
     * be of the form
     * "https://www.googleapis.com/compute/v1/projects/HOST_PROJECT_ID/regions/REGION/subnetworks/SUBNETWORK"
     * or "regions/REGION/subnetworks/SUBNETWORK". If the subnetwork is located in
     * a Shared VPC network, you must use the complete URL.
     * </pre>
     *
     * <code>string subnetwork = 9;</code>
     *
     * @return The subnetwork.
     */
    public java.lang.String getSubnetwork() {
      java.lang.Object ref = subnetwork_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        subnetwork_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * Subnetwork to which VMs will be assigned, if desired. You can specify a
     * subnetwork using either a complete URL or an abbreviated path. Expected to
     * be of the form
     * "https://www.googleapis.com/compute/v1/projects/HOST_PROJECT_ID/regions/REGION/subnetworks/SUBNETWORK"
     * or "regions/REGION/subnetworks/SUBNETWORK". If the subnetwork is located in
     * a Shared VPC network, you must use the complete URL.
     * </pre>
     *
     * <code>string subnetwork = 9;</code>
     *
     * @return The bytes for subnetwork.
     */
    public com.google.protobuf.ByteString getSubnetworkBytes() {
      java.lang.Object ref = subnetwork_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        subnetwork_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * Subnetwork to which VMs will be assigned, if desired. You can specify a
     * subnetwork using either a complete URL or an abbreviated path. Expected to
     * be of the form
     * "https://www.googleapis.com/compute/v1/projects/HOST_PROJECT_ID/regions/REGION/subnetworks/SUBNETWORK"
     * or "regions/REGION/subnetworks/SUBNETWORK". If the subnetwork is located in
     * a Shared VPC network, you must use the complete URL.
     * </pre>
     *
     * <code>string subnetwork = 9;</code>
     *
     * @param value The subnetwork to set.
     * @return This builder for chaining.
     */
    public Builder setSubnetwork(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      subnetwork_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Subnetwork to which VMs will be assigned, if desired. You can specify a
     * subnetwork using either a complete URL or an abbreviated path. Expected to
     * be of the form
     * "https://www.googleapis.com/compute/v1/projects/HOST_PROJECT_ID/regions/REGION/subnetworks/SUBNETWORK"
     * or "regions/REGION/subnetworks/SUBNETWORK". If the subnetwork is located in
     * a Shared VPC network, you must use the complete URL.
     * </pre>
     *
     * <code>string subnetwork = 9;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearSubnetwork() {

      subnetwork_ = getDefaultInstance().getSubnetwork();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Subnetwork to which VMs will be assigned, if desired. You can specify a
     * subnetwork using either a complete URL or an abbreviated path. Expected to
     * be of the form
     * "https://www.googleapis.com/compute/v1/projects/HOST_PROJECT_ID/regions/REGION/subnetworks/SUBNETWORK"
     * or "regions/REGION/subnetworks/SUBNETWORK". If the subnetwork is located in
     * a Shared VPC network, you must use the complete URL.
     * </pre>
     *
     * <code>string subnetwork = 9;</code>
     *
     * @param value The bytes for subnetwork to set.
     * @return This builder for chaining.
     */
    public Builder setSubnetworkBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      subnetwork_ = value;
      onChanged();
      return this;
    }

    private com.google.protobuf.MapField<java.lang.String, java.lang.String> additionalUserLabels_;

    private com.google.protobuf.MapField<java.lang.String, java.lang.String>
        internalGetAdditionalUserLabels() {
      if (additionalUserLabels_ == null) {
        return com.google.protobuf.MapField.emptyMapField(
            AdditionalUserLabelsDefaultEntryHolder.defaultEntry);
      }
      return additionalUserLabels_;
    }

    private com.google.protobuf.MapField<java.lang.String, java.lang.String>
        internalGetMutableAdditionalUserLabels() {
      onChanged();
      ;
      if (additionalUserLabels_ == null) {
        additionalUserLabels_ =
            com.google.protobuf.MapField.newMapField(
                AdditionalUserLabelsDefaultEntryHolder.defaultEntry);
      }
      if (!additionalUserLabels_.isMutable()) {
        additionalUserLabels_ = additionalUserLabels_.copy();
      }
      return additionalUserLabels_;
    }

    public int getAdditionalUserLabelsCount() {
      return internalGetAdditionalUserLabels().getMap().size();
    }
    /**
     *
     *
     * <pre>
     * Additional user labels to be specified for the job.
     * Keys and values should follow the restrictions specified in the [labeling
     * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
     * page.
     * An object containing a list of "key": value pairs.
     * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
     * </pre>
     *
     * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
     */
    @java.lang.Override
    public boolean containsAdditionalUserLabels(java.lang.String key) {
      if (key == null) {
        throw new NullPointerException("map key");
      }
      return internalGetAdditionalUserLabels().getMap().containsKey(key);
    }
    /** Use {@link #getAdditionalUserLabelsMap()} instead. */
    @java.lang.Override
    @java.lang.Deprecated
    public java.util.Map<java.lang.String, java.lang.String> getAdditionalUserLabels() {
      return getAdditionalUserLabelsMap();
    }
    /**
     *
     *
     * <pre>
     * Additional user labels to be specified for the job.
     * Keys and values should follow the restrictions specified in the [labeling
     * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
     * page.
     * An object containing a list of "key": value pairs.
     * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
     * </pre>
     *
     * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
     */
    @java.lang.Override
    public java.util.Map<java.lang.String, java.lang.String> getAdditionalUserLabelsMap() {
      return internalGetAdditionalUserLabels().getMap();
    }
    /**
     *
     *
     * <pre>
     * Additional user labels to be specified for the job.
     * Keys and values should follow the restrictions specified in the [labeling
     * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
     * page.
     * An object containing a list of "key": value pairs.
     * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
     * </pre>
     *
     * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
     */
    @java.lang.Override
    public java.lang.String getAdditionalUserLabelsOrDefault(
        java.lang.String key, java.lang.String defaultValue) {
      if (key == null) {
        throw new NullPointerException("map key");
      }
      java.util.Map<java.lang.String, java.lang.String> map =
          internalGetAdditionalUserLabels().getMap();
      return map.containsKey(key) ? map.get(key) : defaultValue;
    }
    /**
     *
     *
     * <pre>
     * Additional user labels to be specified for the job.
     * Keys and values should follow the restrictions specified in the [labeling
     * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
     * page.
     * An object containing a list of "key": value pairs.
     * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
     * </pre>
     *
     * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
     */
    @java.lang.Override
    public java.lang.String getAdditionalUserLabelsOrThrow(java.lang.String key) {
      if (key == null) {
        throw new NullPointerException("map key");
      }
      java.util.Map<java.lang.String, java.lang.String> map =
          internalGetAdditionalUserLabels().getMap();
      if (!map.containsKey(key)) {
        throw new java.lang.IllegalArgumentException();
      }
      return map.get(key);
    }

    public Builder clearAdditionalUserLabels() {
      internalGetMutableAdditionalUserLabels().getMutableMap().clear();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Additional user labels to be specified for the job.
     * Keys and values should follow the restrictions specified in the [labeling
     * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
     * page.
     * An object containing a list of "key": value pairs.
     * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
     * </pre>
     *
     * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
     */
    public Builder removeAdditionalUserLabels(java.lang.String key) {
      if (key == null) {
        throw new NullPointerException("map key");
      }
      internalGetMutableAdditionalUserLabels().getMutableMap().remove(key);
      return this;
    }
    /** Use alternate mutation accessors instead. */
    @java.lang.Deprecated
    public java.util.Map<java.lang.String, java.lang.String> getMutableAdditionalUserLabels() {
      return internalGetMutableAdditionalUserLabels().getMutableMap();
    }
    /**
     *
     *
     * <pre>
     * Additional user labels to be specified for the job.
     * Keys and values should follow the restrictions specified in the [labeling
     * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
     * page.
     * An object containing a list of "key": value pairs.
     * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
     * </pre>
     *
     * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
     */
    public Builder putAdditionalUserLabels(java.lang.String key, java.lang.String value) {
      if (key == null) {
        throw new NullPointerException("map key");
      }
      if (value == null) {
        throw new NullPointerException("map value");
      }

      internalGetMutableAdditionalUserLabels().getMutableMap().put(key, value);
      return this;
    }
    /**
     *
     *
     * <pre>
     * Additional user labels to be specified for the job.
     * Keys and values should follow the restrictions specified in the [labeling
     * restrictions](https://cloud.google.com/compute/docs/labeling-resources#restrictions)
     * page.
     * An object containing a list of "key": value pairs.
     * Example: { "name": "wrench", "mass": "1kg", "count": "3" }.
     * </pre>
     *
     * <code>map&lt;string, string&gt; additional_user_labels = 10;</code>
     */
    public Builder putAllAdditionalUserLabels(
        java.util.Map<java.lang.String, java.lang.String> values) {
      internalGetMutableAdditionalUserLabels().getMutableMap().putAll(values);
      return this;
    }

    private java.lang.Object kmsKeyName_ = "";
    /**
     *
     *
     * <pre>
     * Name for the Cloud KMS key for the job.
     * Key format is:
     * projects/&lt;project&gt;/locations/&lt;location&gt;/keyRings/&lt;keyring&gt;/cryptoKeys/&lt;key&gt;
     * </pre>
     *
     * <code>string kms_key_name = 12;</code>
     *
     * @return The kmsKeyName.
     */
    public java.lang.String getKmsKeyName() {
      java.lang.Object ref = kmsKeyName_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        kmsKeyName_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * Name for the Cloud KMS key for the job.
     * Key format is:
     * projects/&lt;project&gt;/locations/&lt;location&gt;/keyRings/&lt;keyring&gt;/cryptoKeys/&lt;key&gt;
     * </pre>
     *
     * <code>string kms_key_name = 12;</code>
     *
     * @return The bytes for kmsKeyName.
     */
    public com.google.protobuf.ByteString getKmsKeyNameBytes() {
      java.lang.Object ref = kmsKeyName_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        kmsKeyName_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * Name for the Cloud KMS key for the job.
     * Key format is:
     * projects/&lt;project&gt;/locations/&lt;location&gt;/keyRings/&lt;keyring&gt;/cryptoKeys/&lt;key&gt;
     * </pre>
     *
     * <code>string kms_key_name = 12;</code>
     *
     * @param value The kmsKeyName to set.
     * @return This builder for chaining.
     */
    public Builder setKmsKeyName(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      kmsKeyName_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Name for the Cloud KMS key for the job.
     * Key format is:
     * projects/&lt;project&gt;/locations/&lt;location&gt;/keyRings/&lt;keyring&gt;/cryptoKeys/&lt;key&gt;
     * </pre>
     *
     * <code>string kms_key_name = 12;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearKmsKeyName() {

      kmsKeyName_ = getDefaultInstance().getKmsKeyName();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Name for the Cloud KMS key for the job.
     * Key format is:
     * projects/&lt;project&gt;/locations/&lt;location&gt;/keyRings/&lt;keyring&gt;/cryptoKeys/&lt;key&gt;
     * </pre>
     *
     * <code>string kms_key_name = 12;</code>
     *
     * @param value The bytes for kmsKeyName to set.
     * @return This builder for chaining.
     */
    public Builder setKmsKeyNameBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      kmsKeyName_ = value;
      onChanged();
      return this;
    }

    private int ipConfiguration_ = 0;
    /**
     *
     *
     * <pre>
     * Configuration for VM IPs.
     * </pre>
     *
     * <code>.google.dataflow.v1beta3.WorkerIPAddressConfiguration ip_configuration = 14;</code>
     *
     * @return The enum numeric value on the wire for ipConfiguration.
     */
    @java.lang.Override
    public int getIpConfigurationValue() {
      return ipConfiguration_;
    }
    /**
     *
     *
     * <pre>
     * Configuration for VM IPs.
     * </pre>
     *
     * <code>.google.dataflow.v1beta3.WorkerIPAddressConfiguration ip_configuration = 14;</code>
     *
     * @param value The enum numeric value on the wire for ipConfiguration to set.
     * @return This builder for chaining.
     */
    public Builder setIpConfigurationValue(int value) {

      ipConfiguration_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Configuration for VM IPs.
     * </pre>
     *
     * <code>.google.dataflow.v1beta3.WorkerIPAddressConfiguration ip_configuration = 14;</code>
     *
     * @return The ipConfiguration.
     */
    @java.lang.Override
    public com.google.dataflow.v1beta3.WorkerIPAddressConfiguration getIpConfiguration() {
      @SuppressWarnings("deprecation")
      com.google.dataflow.v1beta3.WorkerIPAddressConfiguration result =
          com.google.dataflow.v1beta3.WorkerIPAddressConfiguration.valueOf(ipConfiguration_);
      return result == null
          ? com.google.dataflow.v1beta3.WorkerIPAddressConfiguration.UNRECOGNIZED
          : result;
    }
    /**
     *
     *
     * <pre>
     * Configuration for VM IPs.
     * </pre>
     *
     * <code>.google.dataflow.v1beta3.WorkerIPAddressConfiguration ip_configuration = 14;</code>
     *
     * @param value The ipConfiguration to set.
     * @return This builder for chaining.
     */
    public Builder setIpConfiguration(
        com.google.dataflow.v1beta3.WorkerIPAddressConfiguration value) {
      if (value == null) {
        throw new NullPointerException();
      }

      ipConfiguration_ = value.getNumber();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Configuration for VM IPs.
     * </pre>
     *
     * <code>.google.dataflow.v1beta3.WorkerIPAddressConfiguration ip_configuration = 14;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearIpConfiguration() {

      ipConfiguration_ = 0;
      onChanged();
      return this;
    }

    private java.lang.Object workerRegion_ = "";
    /**
     *
     *
     * <pre>
     * The Compute Engine region
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1". Mutually exclusive
     * with worker_zone. If neither worker_region nor worker_zone is specified,
     * default to the control plane's region.
     * </pre>
     *
     * <code>string worker_region = 15;</code>
     *
     * @return The workerRegion.
     */
    public java.lang.String getWorkerRegion() {
      java.lang.Object ref = workerRegion_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        workerRegion_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine region
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1". Mutually exclusive
     * with worker_zone. If neither worker_region nor worker_zone is specified,
     * default to the control plane's region.
     * </pre>
     *
     * <code>string worker_region = 15;</code>
     *
     * @return The bytes for workerRegion.
     */
    public com.google.protobuf.ByteString getWorkerRegionBytes() {
      java.lang.Object ref = workerRegion_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        workerRegion_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine region
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1". Mutually exclusive
     * with worker_zone. If neither worker_region nor worker_zone is specified,
     * default to the control plane's region.
     * </pre>
     *
     * <code>string worker_region = 15;</code>
     *
     * @param value The workerRegion to set.
     * @return This builder for chaining.
     */
    public Builder setWorkerRegion(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      workerRegion_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine region
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1". Mutually exclusive
     * with worker_zone. If neither worker_region nor worker_zone is specified,
     * default to the control plane's region.
     * </pre>
     *
     * <code>string worker_region = 15;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearWorkerRegion() {

      workerRegion_ = getDefaultInstance().getWorkerRegion();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine region
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1". Mutually exclusive
     * with worker_zone. If neither worker_region nor worker_zone is specified,
     * default to the control plane's region.
     * </pre>
     *
     * <code>string worker_region = 15;</code>
     *
     * @param value The bytes for workerRegion to set.
     * @return This builder for chaining.
     */
    public Builder setWorkerRegionBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      workerRegion_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object workerZone_ = "";
    /**
     *
     *
     * <pre>
     * The Compute Engine zone
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1-a". Mutually exclusive
     * with worker_region. If neither worker_region nor worker_zone is specified,
     * a zone in the control plane's region is chosen based on available capacity.
     * If both `worker_zone` and `zone` are set, `worker_zone` takes precedence.
     * </pre>
     *
     * <code>string worker_zone = 16;</code>
     *
     * @return The workerZone.
     */
    public java.lang.String getWorkerZone() {
      java.lang.Object ref = workerZone_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        workerZone_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine zone
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1-a". Mutually exclusive
     * with worker_region. If neither worker_region nor worker_zone is specified,
     * a zone in the control plane's region is chosen based on available capacity.
     * If both `worker_zone` and `zone` are set, `worker_zone` takes precedence.
     * </pre>
     *
     * <code>string worker_zone = 16;</code>
     *
     * @return The bytes for workerZone.
     */
    public com.google.protobuf.ByteString getWorkerZoneBytes() {
      java.lang.Object ref = workerZone_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b =
            com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
        workerZone_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine zone
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1-a". Mutually exclusive
     * with worker_region. If neither worker_region nor worker_zone is specified,
     * a zone in the control plane's region is chosen based on available capacity.
     * If both `worker_zone` and `zone` are set, `worker_zone` takes precedence.
     * </pre>
     *
     * <code>string worker_zone = 16;</code>
     *
     * @param value The workerZone to set.
     * @return This builder for chaining.
     */
    public Builder setWorkerZone(java.lang.String value) {
      if (value == null) {
        throw new NullPointerException();
      }

      workerZone_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine zone
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1-a". Mutually exclusive
     * with worker_region. If neither worker_region nor worker_zone is specified,
     * a zone in the control plane's region is chosen based on available capacity.
     * If both `worker_zone` and `zone` are set, `worker_zone` takes precedence.
     * </pre>
     *
     * <code>string worker_zone = 16;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearWorkerZone() {

      workerZone_ = getDefaultInstance().getWorkerZone();
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * The Compute Engine zone
     * (https://cloud.google.com/compute/docs/regions-zones/regions-zones) in
     * which worker processing should occur, e.g. "us-west1-a". Mutually exclusive
     * with worker_region. If neither worker_region nor worker_zone is specified,
     * a zone in the control plane's region is chosen based on available capacity.
     * If both `worker_zone` and `zone` are set, `worker_zone` takes precedence.
     * </pre>
     *
     * <code>string worker_zone = 16;</code>
     *
     * @param value The bytes for workerZone to set.
     * @return This builder for chaining.
     */
    public Builder setWorkerZoneBytes(com.google.protobuf.ByteString value) {
      if (value == null) {
        throw new NullPointerException();
      }
      checkByteStringIsUtf8(value);

      workerZone_ = value;
      onChanged();
      return this;
    }

    private boolean enableStreamingEngine_;
    /**
     *
     *
     * <pre>
     * Whether to enable Streaming Engine for the job.
     * </pre>
     *
     * <code>bool enable_streaming_engine = 17;</code>
     *
     * @return The enableStreamingEngine.
     */
    @java.lang.Override
    public boolean getEnableStreamingEngine() {
      return enableStreamingEngine_;
    }
    /**
     *
     *
     * <pre>
     * Whether to enable Streaming Engine for the job.
     * </pre>
     *
     * <code>bool enable_streaming_engine = 17;</code>
     *
     * @param value The enableStreamingEngine to set.
     * @return This builder for chaining.
     */
    public Builder setEnableStreamingEngine(boolean value) {

      enableStreamingEngine_ = value;
      onChanged();
      return this;
    }
    /**
     *
     *
     * <pre>
     * Whether to enable Streaming Engine for the job.
     * </pre>
     *
     * <code>bool enable_streaming_engine = 17;</code>
     *
     * @return This builder for chaining.
     */
    public Builder clearEnableStreamingEngine() {

      enableStreamingEngine_ = false;
      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:google.dataflow.v1beta3.RuntimeEnvironment)
  }

  // @@protoc_insertion_point(class_scope:google.dataflow.v1beta3.RuntimeEnvironment)
  private static final com.google.dataflow.v1beta3.RuntimeEnvironment DEFAULT_INSTANCE;

  static {
    DEFAULT_INSTANCE = new com.google.dataflow.v1beta3.RuntimeEnvironment();
  }

  public static com.google.dataflow.v1beta3.RuntimeEnvironment getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser<RuntimeEnvironment> PARSER =
      new com.google.protobuf.AbstractParser<RuntimeEnvironment>() {
        @java.lang.Override
        public RuntimeEnvironment 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<RuntimeEnvironment> parser() {
    return PARSER;
  }

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

  @java.lang.Override
  public com.google.dataflow.v1beta3.RuntimeEnvironment getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }
}
