/*
 * 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.searchads360.v0.model;

/**
 * An ad group criterion.
 *
 * <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 Search Ads 360 Reporting 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 GoogleAdsSearchads360V0ResourcesAdGroupCriterion extends com.google.api.client.json.GenericJson {

  /**
   * Immutable. The ad group to which the criterion belongs.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String adGroup;

  /**
   * Immutable. Age range.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0CommonAgeRangeInfo ageRange;

  /**
   * The modifier for the bid when the criterion matches. The modifier must be in the range: 0.1 -
   * 10.0. Most targetable criteria types support modifiers.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Double bidModifier;

  /**
   * The CPC (cost-per-click) bid.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key @com.google.api.client.json.JsonString
  private java.lang.Long cpcBidMicros;

  /**
   * Output only. The timestamp when this ad group criterion was created. The timestamp is in the
   * customer's time zone and in "yyyy-MM-dd HH:mm:ss" format.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String creationTime;

  /**
   * Output only. The ID of the criterion.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key @com.google.api.client.json.JsonString
  private java.lang.Long criterionId;

  /**
   * Output only. The effective CPC (cost-per-click) bid.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key @com.google.api.client.json.JsonString
  private java.lang.Long effectiveCpcBidMicros;

  /**
   * Output only. ID of the ad group criterion in the external engine account. This field is for
   * non-Google Ads account only, for example, Yahoo Japan, Microsoft, Baidu etc. For Google Ads
   * entity, use "ad_group_criterion.criterion_id" instead.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String engineId;

  /**
   * Output only. The Engine Status for ad group criterion.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String engineStatus;

  /**
   * URL template for appending params to final URL.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String finalUrlSuffix;

  /**
   * The list of possible final URLs after all cross-domain redirects for the ad.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<java.lang.String> finalUrls;

  /**
   * Immutable. Gender.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0CommonGenderInfo gender;

  /**
   * Immutable. Keyword.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0CommonKeywordInfo keyword;

  /**
   * Output only. The resource names of labels attached to this ad group criterion.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.util.List<java.lang.String> labels;

  /**
   * Output only. The datetime when this ad group criterion was last modified. The datetime is in
   * the customer's time zone and in "yyyy-MM-dd HH:mm:ss.ssssss" format.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String lastModifiedTime;

  /**
   * Immutable. Listing group.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0CommonListingGroupInfo listingGroup;

  /**
   * Immutable. Location.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0CommonLocationInfo location;

  /**
   * Immutable. Whether to target (`false`) or exclude (`true`) the criterion. This field is
   * immutable. To switch a criterion from positive to negative, remove then re-add it.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.Boolean negative;

  /**
   * Output only. Estimates for criterion bids at various positions.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0ResourcesAdGroupCriterionPositionEstimates positionEstimates;

  /**
   * Output only. Information regarding the quality of the criterion.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0ResourcesAdGroupCriterionQualityInfo qualityInfo;

  /**
   * Immutable. The resource name of the ad group criterion. Ad group criterion resource names have
   * the form: `customers/{customer_id}/adGroupCriteria/{ad_group_id}~{criterion_id}`
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String resourceName;

  /**
   * The status of the criterion. This is the status of the ad group criterion entity, set by the
   * client. Note: UI reports may incorporate additional information that affects whether a
   * criterion is eligible to run. In some cases a criterion that's REMOVED in the API can still
   * show as enabled in the UI. For example, campaigns by default show to users of all age ranges
   * unless excluded. The UI will show each age range as "enabled", since they're eligible to see
   * the ads; but AdGroupCriterion.status will show "removed", since no positive criterion was
   * added.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String status;

  /**
   * The URL template for constructing a tracking URL.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private java.lang.String trackingUrlTemplate;

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

  /**
   * Immutable. User List. The Similar Audiences sunset starts May 2023. Refer to https://ads-
   * developers.googleblog.com/2022/11/announcing-deprecation-and-sunset-of.html for other options.
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0CommonUserListInfo userList;

  /**
   * Immutable. Webpage
   * The value may be {@code null}.
   */
  @com.google.api.client.util.Key
  private GoogleAdsSearchads360V0CommonWebpageInfo webpage;

  /**
   * Immutable. The ad group to which the criterion belongs.
   * @return value or {@code null} for none
   */
  public java.lang.String getAdGroup() {
    return adGroup;
  }

  /**
   * Immutable. The ad group to which the criterion belongs.
   * @param adGroup adGroup or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setAdGroup(java.lang.String adGroup) {
    this.adGroup = adGroup;
    return this;
  }

  /**
   * Immutable. Age range.
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0CommonAgeRangeInfo getAgeRange() {
    return ageRange;
  }

  /**
   * Immutable. Age range.
   * @param ageRange ageRange or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setAgeRange(GoogleAdsSearchads360V0CommonAgeRangeInfo ageRange) {
    this.ageRange = ageRange;
    return this;
  }

  /**
   * The modifier for the bid when the criterion matches. The modifier must be in the range: 0.1 -
   * 10.0. Most targetable criteria types support modifiers.
   * @return value or {@code null} for none
   */
  public java.lang.Double getBidModifier() {
    return bidModifier;
  }

  /**
   * The modifier for the bid when the criterion matches. The modifier must be in the range: 0.1 -
   * 10.0. Most targetable criteria types support modifiers.
   * @param bidModifier bidModifier or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setBidModifier(java.lang.Double bidModifier) {
    this.bidModifier = bidModifier;
    return this;
  }

  /**
   * The CPC (cost-per-click) bid.
   * @return value or {@code null} for none
   */
  public java.lang.Long getCpcBidMicros() {
    return cpcBidMicros;
  }

  /**
   * The CPC (cost-per-click) bid.
   * @param cpcBidMicros cpcBidMicros or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setCpcBidMicros(java.lang.Long cpcBidMicros) {
    this.cpcBidMicros = cpcBidMicros;
    return this;
  }

  /**
   * Output only. The timestamp when this ad group criterion was created. The timestamp is in the
   * customer's time zone and in "yyyy-MM-dd HH:mm:ss" format.
   * @return value or {@code null} for none
   */
  public java.lang.String getCreationTime() {
    return creationTime;
  }

  /**
   * Output only. The timestamp when this ad group criterion was created. The timestamp is in the
   * customer's time zone and in "yyyy-MM-dd HH:mm:ss" format.
   * @param creationTime creationTime or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setCreationTime(java.lang.String creationTime) {
    this.creationTime = creationTime;
    return this;
  }

  /**
   * Output only. The ID of the criterion.
   * @return value or {@code null} for none
   */
  public java.lang.Long getCriterionId() {
    return criterionId;
  }

  /**
   * Output only. The ID of the criterion.
   * @param criterionId criterionId or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setCriterionId(java.lang.Long criterionId) {
    this.criterionId = criterionId;
    return this;
  }

  /**
   * Output only. The effective CPC (cost-per-click) bid.
   * @return value or {@code null} for none
   */
  public java.lang.Long getEffectiveCpcBidMicros() {
    return effectiveCpcBidMicros;
  }

  /**
   * Output only. The effective CPC (cost-per-click) bid.
   * @param effectiveCpcBidMicros effectiveCpcBidMicros or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setEffectiveCpcBidMicros(java.lang.Long effectiveCpcBidMicros) {
    this.effectiveCpcBidMicros = effectiveCpcBidMicros;
    return this;
  }

  /**
   * Output only. ID of the ad group criterion in the external engine account. This field is for
   * non-Google Ads account only, for example, Yahoo Japan, Microsoft, Baidu etc. For Google Ads
   * entity, use "ad_group_criterion.criterion_id" instead.
   * @return value or {@code null} for none
   */
  public java.lang.String getEngineId() {
    return engineId;
  }

  /**
   * Output only. ID of the ad group criterion in the external engine account. This field is for
   * non-Google Ads account only, for example, Yahoo Japan, Microsoft, Baidu etc. For Google Ads
   * entity, use "ad_group_criterion.criterion_id" instead.
   * @param engineId engineId or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setEngineId(java.lang.String engineId) {
    this.engineId = engineId;
    return this;
  }

  /**
   * Output only. The Engine Status for ad group criterion.
   * @return value or {@code null} for none
   */
  public java.lang.String getEngineStatus() {
    return engineStatus;
  }

  /**
   * Output only. The Engine Status for ad group criterion.
   * @param engineStatus engineStatus or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setEngineStatus(java.lang.String engineStatus) {
    this.engineStatus = engineStatus;
    return this;
  }

  /**
   * URL template for appending params to final URL.
   * @return value or {@code null} for none
   */
  public java.lang.String getFinalUrlSuffix() {
    return finalUrlSuffix;
  }

  /**
   * URL template for appending params to final URL.
   * @param finalUrlSuffix finalUrlSuffix or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setFinalUrlSuffix(java.lang.String finalUrlSuffix) {
    this.finalUrlSuffix = finalUrlSuffix;
    return this;
  }

  /**
   * The list of possible final URLs after all cross-domain redirects for the ad.
   * @return value or {@code null} for none
   */
  public java.util.List<java.lang.String> getFinalUrls() {
    return finalUrls;
  }

  /**
   * The list of possible final URLs after all cross-domain redirects for the ad.
   * @param finalUrls finalUrls or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setFinalUrls(java.util.List<java.lang.String> finalUrls) {
    this.finalUrls = finalUrls;
    return this;
  }

  /**
   * Immutable. Gender.
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0CommonGenderInfo getGender() {
    return gender;
  }

  /**
   * Immutable. Gender.
   * @param gender gender or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setGender(GoogleAdsSearchads360V0CommonGenderInfo gender) {
    this.gender = gender;
    return this;
  }

  /**
   * Immutable. Keyword.
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0CommonKeywordInfo getKeyword() {
    return keyword;
  }

  /**
   * Immutable. Keyword.
   * @param keyword keyword or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setKeyword(GoogleAdsSearchads360V0CommonKeywordInfo keyword) {
    this.keyword = keyword;
    return this;
  }

  /**
   * Output only. The resource names of labels attached to this ad group criterion.
   * @return value or {@code null} for none
   */
  public java.util.List<java.lang.String> getLabels() {
    return labels;
  }

  /**
   * Output only. The resource names of labels attached to this ad group criterion.
   * @param labels labels or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setLabels(java.util.List<java.lang.String> labels) {
    this.labels = labels;
    return this;
  }

  /**
   * Output only. The datetime when this ad group criterion was last modified. The datetime is in
   * the customer's time zone and in "yyyy-MM-dd HH:mm:ss.ssssss" format.
   * @return value or {@code null} for none
   */
  public java.lang.String getLastModifiedTime() {
    return lastModifiedTime;
  }

  /**
   * Output only. The datetime when this ad group criterion was last modified. The datetime is in
   * the customer's time zone and in "yyyy-MM-dd HH:mm:ss.ssssss" format.
   * @param lastModifiedTime lastModifiedTime or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setLastModifiedTime(java.lang.String lastModifiedTime) {
    this.lastModifiedTime = lastModifiedTime;
    return this;
  }

  /**
   * Immutable. Listing group.
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0CommonListingGroupInfo getListingGroup() {
    return listingGroup;
  }

  /**
   * Immutable. Listing group.
   * @param listingGroup listingGroup or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setListingGroup(GoogleAdsSearchads360V0CommonListingGroupInfo listingGroup) {
    this.listingGroup = listingGroup;
    return this;
  }

  /**
   * Immutable. Location.
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0CommonLocationInfo getLocation() {
    return location;
  }

  /**
   * Immutable. Location.
   * @param location location or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setLocation(GoogleAdsSearchads360V0CommonLocationInfo location) {
    this.location = location;
    return this;
  }

  /**
   * Immutable. Whether to target (`false`) or exclude (`true`) the criterion. This field is
   * immutable. To switch a criterion from positive to negative, remove then re-add it.
   * @return value or {@code null} for none
   */
  public java.lang.Boolean getNegative() {
    return negative;
  }

  /**
   * Immutable. Whether to target (`false`) or exclude (`true`) the criterion. This field is
   * immutable. To switch a criterion from positive to negative, remove then re-add it.
   * @param negative negative or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setNegative(java.lang.Boolean negative) {
    this.negative = negative;
    return this;
  }

  /**
   * Output only. Estimates for criterion bids at various positions.
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterionPositionEstimates getPositionEstimates() {
    return positionEstimates;
  }

  /**
   * Output only. Estimates for criterion bids at various positions.
   * @param positionEstimates positionEstimates or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setPositionEstimates(GoogleAdsSearchads360V0ResourcesAdGroupCriterionPositionEstimates positionEstimates) {
    this.positionEstimates = positionEstimates;
    return this;
  }

  /**
   * Output only. Information regarding the quality of the criterion.
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterionQualityInfo getQualityInfo() {
    return qualityInfo;
  }

  /**
   * Output only. Information regarding the quality of the criterion.
   * @param qualityInfo qualityInfo or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setQualityInfo(GoogleAdsSearchads360V0ResourcesAdGroupCriterionQualityInfo qualityInfo) {
    this.qualityInfo = qualityInfo;
    return this;
  }

  /**
   * Immutable. The resource name of the ad group criterion. Ad group criterion resource names have
   * the form: `customers/{customer_id}/adGroupCriteria/{ad_group_id}~{criterion_id}`
   * @return value or {@code null} for none
   */
  public java.lang.String getResourceName() {
    return resourceName;
  }

  /**
   * Immutable. The resource name of the ad group criterion. Ad group criterion resource names have
   * the form: `customers/{customer_id}/adGroupCriteria/{ad_group_id}~{criterion_id}`
   * @param resourceName resourceName or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setResourceName(java.lang.String resourceName) {
    this.resourceName = resourceName;
    return this;
  }

  /**
   * The status of the criterion. This is the status of the ad group criterion entity, set by the
   * client. Note: UI reports may incorporate additional information that affects whether a
   * criterion is eligible to run. In some cases a criterion that's REMOVED in the API can still
   * show as enabled in the UI. For example, campaigns by default show to users of all age ranges
   * unless excluded. The UI will show each age range as "enabled", since they're eligible to see
   * the ads; but AdGroupCriterion.status will show "removed", since no positive criterion was
   * added.
   * @return value or {@code null} for none
   */
  public java.lang.String getStatus() {
    return status;
  }

  /**
   * The status of the criterion. This is the status of the ad group criterion entity, set by the
   * client. Note: UI reports may incorporate additional information that affects whether a
   * criterion is eligible to run. In some cases a criterion that's REMOVED in the API can still
   * show as enabled in the UI. For example, campaigns by default show to users of all age ranges
   * unless excluded. The UI will show each age range as "enabled", since they're eligible to see
   * the ads; but AdGroupCriterion.status will show "removed", since no positive criterion was
   * added.
   * @param status status or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setStatus(java.lang.String status) {
    this.status = status;
    return this;
  }

  /**
   * The URL template for constructing a tracking URL.
   * @return value or {@code null} for none
   */
  public java.lang.String getTrackingUrlTemplate() {
    return trackingUrlTemplate;
  }

  /**
   * The URL template for constructing a tracking URL.
   * @param trackingUrlTemplate trackingUrlTemplate or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setTrackingUrlTemplate(java.lang.String trackingUrlTemplate) {
    this.trackingUrlTemplate = trackingUrlTemplate;
    return this;
  }

  /**
   * Output only. The type of the criterion.
   * @return value or {@code null} for none
   */
  public java.lang.String getType() {
    return type;
  }

  /**
   * Output only. The type of the criterion.
   * @param type type or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setType(java.lang.String type) {
    this.type = type;
    return this;
  }

  /**
   * Immutable. User List. The Similar Audiences sunset starts May 2023. Refer to https://ads-
   * developers.googleblog.com/2022/11/announcing-deprecation-and-sunset-of.html for other options.
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0CommonUserListInfo getUserList() {
    return userList;
  }

  /**
   * Immutable. User List. The Similar Audiences sunset starts May 2023. Refer to https://ads-
   * developers.googleblog.com/2022/11/announcing-deprecation-and-sunset-of.html for other options.
   * @param userList userList or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setUserList(GoogleAdsSearchads360V0CommonUserListInfo userList) {
    this.userList = userList;
    return this;
  }

  /**
   * Immutable. Webpage
   * @return value or {@code null} for none
   */
  public GoogleAdsSearchads360V0CommonWebpageInfo getWebpage() {
    return webpage;
  }

  /**
   * Immutable. Webpage
   * @param webpage webpage or {@code null} for none
   */
  public GoogleAdsSearchads360V0ResourcesAdGroupCriterion setWebpage(GoogleAdsSearchads360V0CommonWebpageInfo webpage) {
    this.webpage = webpage;
    return this;
  }

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

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

}
