/*
 * 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.contentwarehouse.v1.model;

/**
 * Global feature for the image.
 *
 * <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 Document AI Warehouse 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 PhotosVisionObjectrecGlobalFeature extends com.google.api.client.json.GenericJson {

  /**
   * Optional info provided by the feature extractor.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String additionalInfo;

  /**
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private PhotosVisionObjectrecFeatureVector featureVector;

  /**
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private PhotosVisionObjectrecQuantizedFeatureVector quantizedFeatureVector;

  /**
   * Tag for this global feature. E.g., "DELG", "SBv4" or "DELG_region1".
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String tag;

  /**
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String version;

  /**
   * Optional info provided by the feature extractor.
   * @see #decodeAdditionalInfo()
   * @return value or {@code null} for none
   */
  public java.lang.String getAdditionalInfo() {
    return additionalInfo;
  }

  /**
   * Optional info provided by the feature extractor.
   * @see #getAdditionalInfo()
   * @return Base64 decoded value or {@code null} for none
   *
   * @since 1.14
   */
  public byte[] decodeAdditionalInfo() {
    return com.google.api.client.util.Base64.decodeBase64(additionalInfo);
  }

  /**
   * Optional info provided by the feature extractor.
   * @see #encodeAdditionalInfo()
   * @param additionalInfo additionalInfo or {@code null} for none
   */
  public PhotosVisionObjectrecGlobalFeature setAdditionalInfo(java.lang.String additionalInfo) {
    this.additionalInfo = additionalInfo;
    return this;
  }

  /**
   * Optional info provided by the feature extractor.
   * @see #setAdditionalInfo()
   *
   * <p>
   * The value is encoded Base64 or {@code null} for none.
   * </p>
   *
   * @since 1.14
   */
  public PhotosVisionObjectrecGlobalFeature encodeAdditionalInfo(byte[] additionalInfo) {
    this.additionalInfo = com.google.api.client.util.Base64.encodeBase64URLSafeString(additionalInfo);
    return this;
  }

  /**
   * @return value or {@code null} for none
   */
  public PhotosVisionObjectrecFeatureVector getFeatureVector() {
    return featureVector;
  }

  /**
   * @param featureVector featureVector or {@code null} for none
   */
  public PhotosVisionObjectrecGlobalFeature setFeatureVector(PhotosVisionObjectrecFeatureVector featureVector) {
    this.featureVector = featureVector;
    return this;
  }

  /**
   * @return value or {@code null} for none
   */
  public PhotosVisionObjectrecQuantizedFeatureVector getQuantizedFeatureVector() {
    return quantizedFeatureVector;
  }

  /**
   * @param quantizedFeatureVector quantizedFeatureVector or {@code null} for none
   */
  public PhotosVisionObjectrecGlobalFeature setQuantizedFeatureVector(PhotosVisionObjectrecQuantizedFeatureVector quantizedFeatureVector) {
    this.quantizedFeatureVector = quantizedFeatureVector;
    return this;
  }

  /**
   * Tag for this global feature. E.g., "DELG", "SBv4" or "DELG_region1".
   * @return value or {@code null} for none
   */
  public java.lang.String getTag() {
    return tag;
  }

  /**
   * Tag for this global feature. E.g., "DELG", "SBv4" or "DELG_region1".
   * @param tag tag or {@code null} for none
   */
  public PhotosVisionObjectrecGlobalFeature setTag(java.lang.String tag) {
    this.tag = tag;
    return this;
  }

  /**
   * @return value or {@code null} for none
   */
  public java.lang.String getVersion() {
    return version;
  }

  /**
   * @param version version or {@code null} for none
   */
  public PhotosVisionObjectrecGlobalFeature setVersion(java.lang.String version) {
    this.version = version;
    return this;
  }

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

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

}
