/*
 * 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.datacatalog.v1beta1.model;

/**
 * Specification that applies to a routine. Valid only for entries with the `ROUTINE` type.
 *
 * <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 Google Cloud Data Catalog 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 GoogleCloudDatacatalogV1RoutineSpec extends com.google.api.client.json.GenericJson {

  /**
   * Fields specific for BigQuery routines.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleCloudDatacatalogV1BigQueryRoutineSpec bigqueryRoutineSpec;

  /**
   * The body of the routine.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String definitionBody;

  /**
   * The language the routine is written in. The exact value depends on the source system. For
   * BigQuery routines, possible values are: * `SQL` * `JAVASCRIPT`
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String language;

  /**
   * Return type of the argument. The exact value depends on the source system and the language.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String returnType;

  /**
   * Arguments of the routine.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<GoogleCloudDatacatalogV1RoutineSpecArgument> routineArguments;

  /**
   * The type of the routine.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String routineType;

  /**
   * Fields specific for BigQuery routines.
   * @return value or {@code null} for none
   */
  public GoogleCloudDatacatalogV1BigQueryRoutineSpec getBigqueryRoutineSpec() {
    return bigqueryRoutineSpec;
  }

  /**
   * Fields specific for BigQuery routines.
   * @param bigqueryRoutineSpec bigqueryRoutineSpec or {@code null} for none
   */
  public GoogleCloudDatacatalogV1RoutineSpec setBigqueryRoutineSpec(GoogleCloudDatacatalogV1BigQueryRoutineSpec bigqueryRoutineSpec) {
    this.bigqueryRoutineSpec = bigqueryRoutineSpec;
    return this;
  }

  /**
   * The body of the routine.
   * @return value or {@code null} for none
   */
  public java.lang.String getDefinitionBody() {
    return definitionBody;
  }

  /**
   * The body of the routine.
   * @param definitionBody definitionBody or {@code null} for none
   */
  public GoogleCloudDatacatalogV1RoutineSpec setDefinitionBody(java.lang.String definitionBody) {
    this.definitionBody = definitionBody;
    return this;
  }

  /**
   * The language the routine is written in. The exact value depends on the source system. For
   * BigQuery routines, possible values are: * `SQL` * `JAVASCRIPT`
   * @return value or {@code null} for none
   */
  public java.lang.String getLanguage() {
    return language;
  }

  /**
   * The language the routine is written in. The exact value depends on the source system. For
   * BigQuery routines, possible values are: * `SQL` * `JAVASCRIPT`
   * @param language language or {@code null} for none
   */
  public GoogleCloudDatacatalogV1RoutineSpec setLanguage(java.lang.String language) {
    this.language = language;
    return this;
  }

  /**
   * Return type of the argument. The exact value depends on the source system and the language.
   * @return value or {@code null} for none
   */
  public java.lang.String getReturnType() {
    return returnType;
  }

  /**
   * Return type of the argument. The exact value depends on the source system and the language.
   * @param returnType returnType or {@code null} for none
   */
  public GoogleCloudDatacatalogV1RoutineSpec setReturnType(java.lang.String returnType) {
    this.returnType = returnType;
    return this;
  }

  /**
   * Arguments of the routine.
   * @return value or {@code null} for none
   */
  public java.util.List<GoogleCloudDatacatalogV1RoutineSpecArgument> getRoutineArguments() {
    return routineArguments;
  }

  /**
   * Arguments of the routine.
   * @param routineArguments routineArguments or {@code null} for none
   */
  public GoogleCloudDatacatalogV1RoutineSpec setRoutineArguments(java.util.List<GoogleCloudDatacatalogV1RoutineSpecArgument> routineArguments) {
    this.routineArguments = routineArguments;
    return this;
  }

  /**
   * The type of the routine.
   * @return value or {@code null} for none
   */
  public java.lang.String getRoutineType() {
    return routineType;
  }

  /**
   * The type of the routine.
   * @param routineType routineType or {@code null} for none
   */
  public GoogleCloudDatacatalogV1RoutineSpec setRoutineType(java.lang.String routineType) {
    this.routineType = routineType;
    return this;
  }

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

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

}
