/*
 * 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
 *
 * http://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.
 */
/*
 * This code was generated by https://github.com/googleapis/google-api-java-client-services/
 * Modify at your own risk.
 */

package com.google.api.services.servicenetworking.v1.model;

/**
 * Model definition for ValidateConsumerConfigRequest.
 *
 * <p> This is the Java data model class that specifies how to parse/serialize into the JSON that is
 * transmitted over HTTP when working with the Service Networking API. For a detailed explanation
 * see:
 * <a href="https://developers.google.com/api-client-library/java/google-http-java-client/json">https://developers.google.com/api-client-library/java/google-http-java-client/json</a>
 * </p>
 *
 * @author Google, Inc.
 */
@SuppressWarnings("javadoc")
public final class ValidateConsumerConfigRequest extends com.google.api.client.json.GenericJson {

  /**
   * Required. The network that the consumer is using to connect with services. Must be in the form
   * of projects/{project}/global/networks/{network} {project} is a project number, as in '12345'
   * {network} is network name.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String consumerNetwork;

  /**
   * NETWORK_NOT_IN_CONSUMERS_PROJECT, NETWORK_NOT_IN_CONSUMERS_HOST_PROJECT, and
   * HOST_PROJECT_NOT_FOUND are done when consumer_project is provided.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private ConsumerProject consumerProject;

  /**
   * RANGES_EXHAUSTED, RANGES_EXHAUSTED, and RANGES_DELETED_LATER are done when range_reservation is
   * provided.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private RangeReservation rangeReservation;

  /**
   * The validations will be performed in the order listed in the ValidationError enum. The first
   * failure will return. If a validation is not requested, then the next one will be performed.
   * SERVICE_NETWORKING_NOT_ENABLED and NETWORK_NOT_PEERED checks are performed for all requests
   * where validation is requested. NETWORK_NOT_FOUND and NETWORK_DISCONNECTED checks are done for
   * requests that have validate_network set to true.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Boolean validateNetwork;

  /**
   * Required. The network that the consumer is using to connect with services. Must be in the form
   * of projects/{project}/global/networks/{network} {project} is a project number, as in '12345'
   * {network} is network name.
   * @return value or {@code null} for none
   */
  public java.lang.String getConsumerNetwork() {
    return consumerNetwork;
  }

  /**
   * Required. The network that the consumer is using to connect with services. Must be in the form
   * of projects/{project}/global/networks/{network} {project} is a project number, as in '12345'
   * {network} is network name.
   * @param consumerNetwork consumerNetwork or {@code null} for none
   */
  public ValidateConsumerConfigRequest setConsumerNetwork(java.lang.String consumerNetwork) {
    this.consumerNetwork = consumerNetwork;
    return this;
  }

  /**
   * NETWORK_NOT_IN_CONSUMERS_PROJECT, NETWORK_NOT_IN_CONSUMERS_HOST_PROJECT, and
   * HOST_PROJECT_NOT_FOUND are done when consumer_project is provided.
   * @return value or {@code null} for none
   */
  public ConsumerProject getConsumerProject() {
    return consumerProject;
  }

  /**
   * NETWORK_NOT_IN_CONSUMERS_PROJECT, NETWORK_NOT_IN_CONSUMERS_HOST_PROJECT, and
   * HOST_PROJECT_NOT_FOUND are done when consumer_project is provided.
   * @param consumerProject consumerProject or {@code null} for none
   */
  public ValidateConsumerConfigRequest setConsumerProject(ConsumerProject consumerProject) {
    this.consumerProject = consumerProject;
    return this;
  }

  /**
   * RANGES_EXHAUSTED, RANGES_EXHAUSTED, and RANGES_DELETED_LATER are done when range_reservation is
   * provided.
   * @return value or {@code null} for none
   */
  public RangeReservation getRangeReservation() {
    return rangeReservation;
  }

  /**
   * RANGES_EXHAUSTED, RANGES_EXHAUSTED, and RANGES_DELETED_LATER are done when range_reservation is
   * provided.
   * @param rangeReservation rangeReservation or {@code null} for none
   */
  public ValidateConsumerConfigRequest setRangeReservation(RangeReservation rangeReservation) {
    this.rangeReservation = rangeReservation;
    return this;
  }

  /**
   * The validations will be performed in the order listed in the ValidationError enum. The first
   * failure will return. If a validation is not requested, then the next one will be performed.
   * SERVICE_NETWORKING_NOT_ENABLED and NETWORK_NOT_PEERED checks are performed for all requests
   * where validation is requested. NETWORK_NOT_FOUND and NETWORK_DISCONNECTED checks are done for
   * requests that have validate_network set to true.
   * @return value or {@code null} for none
   */
  public java.lang.Boolean getValidateNetwork() {
    return validateNetwork;
  }

  /**
   * The validations will be performed in the order listed in the ValidationError enum. The first
   * failure will return. If a validation is not requested, then the next one will be performed.
   * SERVICE_NETWORKING_NOT_ENABLED and NETWORK_NOT_PEERED checks are performed for all requests
   * where validation is requested. NETWORK_NOT_FOUND and NETWORK_DISCONNECTED checks are done for
   * requests that have validate_network set to true.
   * @param validateNetwork validateNetwork or {@code null} for none
   */
  public ValidateConsumerConfigRequest setValidateNetwork(java.lang.Boolean validateNetwork) {
    this.validateNetwork = validateNetwork;
    return this;
  }

  @Override
  public ValidateConsumerConfigRequest set(String fieldName, Object value) {
    return (ValidateConsumerConfigRequest) super.set(fieldName, value);
  }

  @Override
  public ValidateConsumerConfigRequest clone() {
    return (ValidateConsumerConfigRequest) super.clone();
  }

}
