/*
 * 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;

/**
 * A column within a schema. Columns can be nested inside other columns.
 *
 * <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 GoogleCloudDatacatalogV1ColumnSchema extends com.google.api.client.json.GenericJson {

  /**
   * Required. Name of the column. Must be a UTF-8 string without dots (.). The maximum size is 64
   * bytes.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String column;

  /**
   * Optional. Default value for the column.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String defaultValue;

  /**
   * Optional. Description of the column. Default value is an empty string. The description must be
   * a UTF-8 string with the maximum size of 2000 bytes.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String description;

  /**
   * Optional. Garbage collection policy for the column or column family. Applies to systems like
   * Cloud Bigtable.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String gcRule;

  /**
   * Optional. Most important inclusion of this column.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String highestIndexingType;

  /**
   * Looker specific column info of this column.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleCloudDatacatalogV1ColumnSchemaLookerColumnSpec lookerColumnSpec;

  /**
   * Optional. A column's mode indicates whether values in this column are required, nullable, or
   * repeated. Only `NULLABLE`, `REQUIRED`, and `REPEATED` values are supported. Default mode is
   * `NULLABLE`.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String mode;

  /**
   * Optional. Ordinal position
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Integer ordinalPosition;

  /**
   * Optional. Schema of sub-columns. A column can have zero or more sub-columns.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<GoogleCloudDatacatalogV1ColumnSchema> subcolumns;

  /**
   * Required. Type of the column. Must be a UTF-8 string with the maximum size of 128 bytes.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String type;

  /**
   * Required. Name of the column. Must be a UTF-8 string without dots (.). The maximum size is 64
   * bytes.
   * @return value or {@code null} for none
   */
  public java.lang.String getColumn() {
    return column;
  }

  /**
   * Required. Name of the column. Must be a UTF-8 string without dots (.). The maximum size is 64
   * bytes.
   * @param column column or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setColumn(java.lang.String column) {
    this.column = column;
    return this;
  }

  /**
   * Optional. Default value for the column.
   * @return value or {@code null} for none
   */
  public java.lang.String getDefaultValue() {
    return defaultValue;
  }

  /**
   * Optional. Default value for the column.
   * @param defaultValue defaultValue or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setDefaultValue(java.lang.String defaultValue) {
    this.defaultValue = defaultValue;
    return this;
  }

  /**
   * Optional. Description of the column. Default value is an empty string. The description must be
   * a UTF-8 string with the maximum size of 2000 bytes.
   * @return value or {@code null} for none
   */
  public java.lang.String getDescription() {
    return description;
  }

  /**
   * Optional. Description of the column. Default value is an empty string. The description must be
   * a UTF-8 string with the maximum size of 2000 bytes.
   * @param description description or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setDescription(java.lang.String description) {
    this.description = description;
    return this;
  }

  /**
   * Optional. Garbage collection policy for the column or column family. Applies to systems like
   * Cloud Bigtable.
   * @return value or {@code null} for none
   */
  public java.lang.String getGcRule() {
    return gcRule;
  }

  /**
   * Optional. Garbage collection policy for the column or column family. Applies to systems like
   * Cloud Bigtable.
   * @param gcRule gcRule or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setGcRule(java.lang.String gcRule) {
    this.gcRule = gcRule;
    return this;
  }

  /**
   * Optional. Most important inclusion of this column.
   * @return value or {@code null} for none
   */
  public java.lang.String getHighestIndexingType() {
    return highestIndexingType;
  }

  /**
   * Optional. Most important inclusion of this column.
   * @param highestIndexingType highestIndexingType or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setHighestIndexingType(java.lang.String highestIndexingType) {
    this.highestIndexingType = highestIndexingType;
    return this;
  }

  /**
   * Looker specific column info of this column.
   * @return value or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchemaLookerColumnSpec getLookerColumnSpec() {
    return lookerColumnSpec;
  }

  /**
   * Looker specific column info of this column.
   * @param lookerColumnSpec lookerColumnSpec or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setLookerColumnSpec(GoogleCloudDatacatalogV1ColumnSchemaLookerColumnSpec lookerColumnSpec) {
    this.lookerColumnSpec = lookerColumnSpec;
    return this;
  }

  /**
   * Optional. A column's mode indicates whether values in this column are required, nullable, or
   * repeated. Only `NULLABLE`, `REQUIRED`, and `REPEATED` values are supported. Default mode is
   * `NULLABLE`.
   * @return value or {@code null} for none
   */
  public java.lang.String getMode() {
    return mode;
  }

  /**
   * Optional. A column's mode indicates whether values in this column are required, nullable, or
   * repeated. Only `NULLABLE`, `REQUIRED`, and `REPEATED` values are supported. Default mode is
   * `NULLABLE`.
   * @param mode mode or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setMode(java.lang.String mode) {
    this.mode = mode;
    return this;
  }

  /**
   * Optional. Ordinal position
   * @return value or {@code null} for none
   */
  public java.lang.Integer getOrdinalPosition() {
    return ordinalPosition;
  }

  /**
   * Optional. Ordinal position
   * @param ordinalPosition ordinalPosition or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setOrdinalPosition(java.lang.Integer ordinalPosition) {
    this.ordinalPosition = ordinalPosition;
    return this;
  }

  /**
   * Optional. Schema of sub-columns. A column can have zero or more sub-columns.
   * @return value or {@code null} for none
   */
  public java.util.List<GoogleCloudDatacatalogV1ColumnSchema> getSubcolumns() {
    return subcolumns;
  }

  /**
   * Optional. Schema of sub-columns. A column can have zero or more sub-columns.
   * @param subcolumns subcolumns or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setSubcolumns(java.util.List<GoogleCloudDatacatalogV1ColumnSchema> subcolumns) {
    this.subcolumns = subcolumns;
    return this;
  }

  /**
   * Required. Type of the column. Must be a UTF-8 string with the maximum size of 128 bytes.
   * @return value or {@code null} for none
   */
  public java.lang.String getType() {
    return type;
  }

  /**
   * Required. Type of the column. Must be a UTF-8 string with the maximum size of 128 bytes.
   * @param type type or {@code null} for none
   */
  public GoogleCloudDatacatalogV1ColumnSchema setType(java.lang.String type) {
    this.type = type;
    return this;
  }

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

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

}
