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

/**
 * Information about a review of a place.
 *
 * <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 Places API (New). 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 GoogleMapsPlacesV1Review extends com.google.api.client.json.GenericJson {

  /**
   * Output only. This review's author.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleMapsPlacesV1AuthorAttribution authorAttribution;

  /**
   * Output only. The review text in its original language.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleTypeLocalizedText originalText;

  /**
   * Output only. Timestamp for the review.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private String publishTime;

  /**
   * Output only. A number between 1.0 and 5.0, a.k.a. the number of stars.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Double rating;

  /**
   * Output only. A string of formatted recent time, expressing the review time relative to the
   * current time in a form appropriate for the language and country.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String relativePublishTimeDescription;

  /**
   * Output only. The localized text of the review.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleTypeLocalizedText text;

  /**
   * Output only. This review's author.
   * @return value or {@code null} for none
   */
  public GoogleMapsPlacesV1AuthorAttribution getAuthorAttribution() {
    return authorAttribution;
  }

  /**
   * Output only. This review's author.
   * @param authorAttribution authorAttribution or {@code null} for none
   */
  public GoogleMapsPlacesV1Review setAuthorAttribution(GoogleMapsPlacesV1AuthorAttribution authorAttribution) {
    this.authorAttribution = authorAttribution;
    return this;
  }

  /**
   * Output only. The review text in its original language.
   * @return value or {@code null} for none
   */
  public GoogleTypeLocalizedText getOriginalText() {
    return originalText;
  }

  /**
   * Output only. The review text in its original language.
   * @param originalText originalText or {@code null} for none
   */
  public GoogleMapsPlacesV1Review setOriginalText(GoogleTypeLocalizedText originalText) {
    this.originalText = originalText;
    return this;
  }

  /**
   * Output only. Timestamp for the review.
   * @return value or {@code null} for none
   */
  public String getPublishTime() {
    return publishTime;
  }

  /**
   * Output only. Timestamp for the review.
   * @param publishTime publishTime or {@code null} for none
   */
  public GoogleMapsPlacesV1Review setPublishTime(String publishTime) {
    this.publishTime = publishTime;
    return this;
  }

  /**
   * Output only. A number between 1.0 and 5.0, a.k.a. the number of stars.
   * @return value or {@code null} for none
   */
  public java.lang.Double getRating() {
    return rating;
  }

  /**
   * Output only. A number between 1.0 and 5.0, a.k.a. the number of stars.
   * @param rating rating or {@code null} for none
   */
  public GoogleMapsPlacesV1Review setRating(java.lang.Double rating) {
    this.rating = rating;
    return this;
  }

  /**
   * Output only. A string of formatted recent time, expressing the review time relative to the
   * current time in a form appropriate for the language and country.
   * @return value or {@code null} for none
   */
  public java.lang.String getRelativePublishTimeDescription() {
    return relativePublishTimeDescription;
  }

  /**
   * Output only. A string of formatted recent time, expressing the review time relative to the
   * current time in a form appropriate for the language and country.
   * @param relativePublishTimeDescription relativePublishTimeDescription or {@code null} for none
   */
  public GoogleMapsPlacesV1Review setRelativePublishTimeDescription(java.lang.String relativePublishTimeDescription) {
    this.relativePublishTimeDescription = relativePublishTimeDescription;
    return this;
  }

  /**
   * Output only. The localized text of the review.
   * @return value or {@code null} for none
   */
  public GoogleTypeLocalizedText getText() {
    return text;
  }

  /**
   * Output only. The localized text of the review.
   * @param text text or {@code null} for none
   */
  public GoogleMapsPlacesV1Review setText(GoogleTypeLocalizedText text) {
    this.text = text;
    return this;
  }

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

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

}
