<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/ads/googleads/v25/resources/applied_incentive.proto

namespace Google\Ads\GoogleAds\V25\Resources;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\GPBUtil;
use Google\Protobuf\RepeatedField;

/**
 * Represents an applied incentive.
 *
 * Generated from protobuf message <code>google.ads.googleads.v25.resources.AppliedIncentive</code>
 */
class AppliedIncentive extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The resource name of the incentive.
     * Incentive resource names have the form:
     * `customers/{customer_id}/appliedIncentives/{coupon_code}`
     *
     * Generated from protobuf field <code>string resource_name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     */
    protected $resource_name = '';
    /**
     * Output only. The coupon code of the incentive.
     *
     * Generated from protobuf field <code>optional string coupon_code = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $coupon_code = null;
    /**
     * Output only. The current state of the incentive.
     *
     * Generated from protobuf field <code>optional .google.ads.googleads.v25.enums.IncentiveStateEnum.IncentiveState incentive_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $incentive_state = null;
    /**
     * Output only. The redemption time of the incentive in "YYYY-MM-DD HH:MM:SS"
     * format in UTC.
     *
     * Generated from protobuf field <code>optional string redemption_date_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $redemption_date_time = null;
    /**
     * Output only. The time by which the incentive's fulfillment requirements
     * must be met, in "YYYY-MM-DD HH:MM:SS" format in UTC.
     *
     * Generated from protobuf field <code>optional string fulfillment_expiration_date_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $fulfillment_expiration_date_time = null;
    /**
     * Output only. The time when the reward was granted in "YYYY-MM-DD HH:MM:SS"
     * format in UTC. This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional string reward_grant_date_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $reward_grant_date_time = null;
    /**
     * Output only. The time when the granted reward expires in "YYYY-MM-DD
     * HH:MM:SS" format in UTC. This field is not set if the reward has not been
     * granted.
     *
     * Generated from protobuf field <code>optional string reward_expiration_date_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $reward_expiration_date_time = null;
    /**
     * Output only. The currency code for all monetary amounts (for example,
     * "USD").
     *
     * Generated from protobuf field <code>optional string currency_code = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $currency_code = null;
    /**
     * Output only. The maximum potential reward amount in micros for the
     * incentive.
     *
     * Generated from protobuf field <code>optional int64 reward_amount_micros = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $reward_amount_micros = null;
    /**
     * Output only. The amount of the reward granted in micros.
     * This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional int64 granted_amount_micros = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $granted_amount_micros = null;
    /**
     * Output only. The minimum amount that must be spent to fulfill the coupon
     * requirements, in micros.
     *
     * Generated from protobuf field <code>optional int64 required_min_spend_micros = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $required_min_spend_micros = null;
    /**
     * Output only. The current amount spent towards the fulfillment requirements,
     * in micros.
     *
     * Generated from protobuf field <code>optional int64 current_spend_towards_fulfillment_micros = 12 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $current_spend_towards_fulfillment_micros = null;
    /**
     * Output only. The remaining balance of the granted reward in micros.
     * This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional int64 reward_balance_remaining_micros = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $reward_balance_remaining_micros = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $resource_name
     *           Output only. The resource name of the incentive.
     *           Incentive resource names have the form:
     *           `customers/{customer_id}/appliedIncentives/{coupon_code}`
     *     @type string $coupon_code
     *           Output only. The coupon code of the incentive.
     *     @type int $incentive_state
     *           Output only. The current state of the incentive.
     *     @type string $redemption_date_time
     *           Output only. The redemption time of the incentive in "YYYY-MM-DD HH:MM:SS"
     *           format in UTC.
     *     @type string $fulfillment_expiration_date_time
     *           Output only. The time by which the incentive's fulfillment requirements
     *           must be met, in "YYYY-MM-DD HH:MM:SS" format in UTC.
     *     @type string $reward_grant_date_time
     *           Output only. The time when the reward was granted in "YYYY-MM-DD HH:MM:SS"
     *           format in UTC. This field is not set if the reward has not been granted.
     *     @type string $reward_expiration_date_time
     *           Output only. The time when the granted reward expires in "YYYY-MM-DD
     *           HH:MM:SS" format in UTC. This field is not set if the reward has not been
     *           granted.
     *     @type string $currency_code
     *           Output only. The currency code for all monetary amounts (for example,
     *           "USD").
     *     @type int|string $reward_amount_micros
     *           Output only. The maximum potential reward amount in micros for the
     *           incentive.
     *     @type int|string $granted_amount_micros
     *           Output only. The amount of the reward granted in micros.
     *           This field is not set if the reward has not been granted.
     *     @type int|string $required_min_spend_micros
     *           Output only. The minimum amount that must be spent to fulfill the coupon
     *           requirements, in micros.
     *     @type int|string $current_spend_towards_fulfillment_micros
     *           Output only. The current amount spent towards the fulfillment requirements,
     *           in micros.
     *     @type int|string $reward_balance_remaining_micros
     *           Output only. The remaining balance of the granted reward in micros.
     *           This field is not set if the reward has not been granted.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Ads\GoogleAds\V25\Resources\AppliedIncentive::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The resource name of the incentive.
     * Incentive resource names have the form:
     * `customers/{customer_id}/appliedIncentives/{coupon_code}`
     *
     * Generated from protobuf field <code>string resource_name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     * @return string
     */
    public function getResourceName()
    {
        return $this->resource_name;
    }

    /**
     * Output only. The resource name of the incentive.
     * Incentive resource names have the form:
     * `customers/{customer_id}/appliedIncentives/{coupon_code}`
     *
     * Generated from protobuf field <code>string resource_name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     * @param string $var
     * @return $this
     */
    public function setResourceName($var)
    {
        GPBUtil::checkString($var, True);
        $this->resource_name = $var;

        return $this;
    }

    /**
     * Output only. The coupon code of the incentive.
     *
     * Generated from protobuf field <code>optional string coupon_code = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getCouponCode()
    {
        return isset($this->coupon_code) ? $this->coupon_code : '';
    }

    public function hasCouponCode()
    {
        return isset($this->coupon_code);
    }

    public function clearCouponCode()
    {
        unset($this->coupon_code);
    }

    /**
     * Output only. The coupon code of the incentive.
     *
     * Generated from protobuf field <code>optional string coupon_code = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setCouponCode($var)
    {
        GPBUtil::checkString($var, True);
        $this->coupon_code = $var;

        return $this;
    }

    /**
     * Output only. The current state of the incentive.
     *
     * Generated from protobuf field <code>optional .google.ads.googleads.v25.enums.IncentiveStateEnum.IncentiveState incentive_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int
     */
    public function getIncentiveState()
    {
        return isset($this->incentive_state) ? $this->incentive_state : 0;
    }

    public function hasIncentiveState()
    {
        return isset($this->incentive_state);
    }

    public function clearIncentiveState()
    {
        unset($this->incentive_state);
    }

    /**
     * Output only. The current state of the incentive.
     *
     * Generated from protobuf field <code>optional .google.ads.googleads.v25.enums.IncentiveStateEnum.IncentiveState incentive_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int $var
     * @return $this
     */
    public function setIncentiveState($var)
    {
        GPBUtil::checkEnum($var, \Google\Ads\GoogleAds\V25\Enums\IncentiveStateEnum\IncentiveState::class);
        $this->incentive_state = $var;

        return $this;
    }

    /**
     * Output only. The redemption time of the incentive in "YYYY-MM-DD HH:MM:SS"
     * format in UTC.
     *
     * Generated from protobuf field <code>optional string redemption_date_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getRedemptionDateTime()
    {
        return isset($this->redemption_date_time) ? $this->redemption_date_time : '';
    }

    public function hasRedemptionDateTime()
    {
        return isset($this->redemption_date_time);
    }

    public function clearRedemptionDateTime()
    {
        unset($this->redemption_date_time);
    }

    /**
     * Output only. The redemption time of the incentive in "YYYY-MM-DD HH:MM:SS"
     * format in UTC.
     *
     * Generated from protobuf field <code>optional string redemption_date_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setRedemptionDateTime($var)
    {
        GPBUtil::checkString($var, True);
        $this->redemption_date_time = $var;

        return $this;
    }

    /**
     * Output only. The time by which the incentive's fulfillment requirements
     * must be met, in "YYYY-MM-DD HH:MM:SS" format in UTC.
     *
     * Generated from protobuf field <code>optional string fulfillment_expiration_date_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getFulfillmentExpirationDateTime()
    {
        return isset($this->fulfillment_expiration_date_time) ? $this->fulfillment_expiration_date_time : '';
    }

    public function hasFulfillmentExpirationDateTime()
    {
        return isset($this->fulfillment_expiration_date_time);
    }

    public function clearFulfillmentExpirationDateTime()
    {
        unset($this->fulfillment_expiration_date_time);
    }

    /**
     * Output only. The time by which the incentive's fulfillment requirements
     * must be met, in "YYYY-MM-DD HH:MM:SS" format in UTC.
     *
     * Generated from protobuf field <code>optional string fulfillment_expiration_date_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setFulfillmentExpirationDateTime($var)
    {
        GPBUtil::checkString($var, True);
        $this->fulfillment_expiration_date_time = $var;

        return $this;
    }

    /**
     * Output only. The time when the reward was granted in "YYYY-MM-DD HH:MM:SS"
     * format in UTC. This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional string reward_grant_date_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getRewardGrantDateTime()
    {
        return isset($this->reward_grant_date_time) ? $this->reward_grant_date_time : '';
    }

    public function hasRewardGrantDateTime()
    {
        return isset($this->reward_grant_date_time);
    }

    public function clearRewardGrantDateTime()
    {
        unset($this->reward_grant_date_time);
    }

    /**
     * Output only. The time when the reward was granted in "YYYY-MM-DD HH:MM:SS"
     * format in UTC. This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional string reward_grant_date_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setRewardGrantDateTime($var)
    {
        GPBUtil::checkString($var, True);
        $this->reward_grant_date_time = $var;

        return $this;
    }

    /**
     * Output only. The time when the granted reward expires in "YYYY-MM-DD
     * HH:MM:SS" format in UTC. This field is not set if the reward has not been
     * granted.
     *
     * Generated from protobuf field <code>optional string reward_expiration_date_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getRewardExpirationDateTime()
    {
        return isset($this->reward_expiration_date_time) ? $this->reward_expiration_date_time : '';
    }

    public function hasRewardExpirationDateTime()
    {
        return isset($this->reward_expiration_date_time);
    }

    public function clearRewardExpirationDateTime()
    {
        unset($this->reward_expiration_date_time);
    }

    /**
     * Output only. The time when the granted reward expires in "YYYY-MM-DD
     * HH:MM:SS" format in UTC. This field is not set if the reward has not been
     * granted.
     *
     * Generated from protobuf field <code>optional string reward_expiration_date_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setRewardExpirationDateTime($var)
    {
        GPBUtil::checkString($var, True);
        $this->reward_expiration_date_time = $var;

        return $this;
    }

    /**
     * Output only. The currency code for all monetary amounts (for example,
     * "USD").
     *
     * Generated from protobuf field <code>optional string currency_code = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getCurrencyCode()
    {
        return isset($this->currency_code) ? $this->currency_code : '';
    }

    public function hasCurrencyCode()
    {
        return isset($this->currency_code);
    }

    public function clearCurrencyCode()
    {
        unset($this->currency_code);
    }

    /**
     * Output only. The currency code for all monetary amounts (for example,
     * "USD").
     *
     * Generated from protobuf field <code>optional string currency_code = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setCurrencyCode($var)
    {
        GPBUtil::checkString($var, True);
        $this->currency_code = $var;

        return $this;
    }

    /**
     * Output only. The maximum potential reward amount in micros for the
     * incentive.
     *
     * Generated from protobuf field <code>optional int64 reward_amount_micros = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int|string
     */
    public function getRewardAmountMicros()
    {
        return isset($this->reward_amount_micros) ? $this->reward_amount_micros : 0;
    }

    public function hasRewardAmountMicros()
    {
        return isset($this->reward_amount_micros);
    }

    public function clearRewardAmountMicros()
    {
        unset($this->reward_amount_micros);
    }

    /**
     * Output only. The maximum potential reward amount in micros for the
     * incentive.
     *
     * Generated from protobuf field <code>optional int64 reward_amount_micros = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int|string $var
     * @return $this
     */
    public function setRewardAmountMicros($var)
    {
        GPBUtil::checkInt64($var);
        $this->reward_amount_micros = $var;

        return $this;
    }

    /**
     * Output only. The amount of the reward granted in micros.
     * This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional int64 granted_amount_micros = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int|string
     */
    public function getGrantedAmountMicros()
    {
        return isset($this->granted_amount_micros) ? $this->granted_amount_micros : 0;
    }

    public function hasGrantedAmountMicros()
    {
        return isset($this->granted_amount_micros);
    }

    public function clearGrantedAmountMicros()
    {
        unset($this->granted_amount_micros);
    }

    /**
     * Output only. The amount of the reward granted in micros.
     * This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional int64 granted_amount_micros = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int|string $var
     * @return $this
     */
    public function setGrantedAmountMicros($var)
    {
        GPBUtil::checkInt64($var);
        $this->granted_amount_micros = $var;

        return $this;
    }

    /**
     * Output only. The minimum amount that must be spent to fulfill the coupon
     * requirements, in micros.
     *
     * Generated from protobuf field <code>optional int64 required_min_spend_micros = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int|string
     */
    public function getRequiredMinSpendMicros()
    {
        return isset($this->required_min_spend_micros) ? $this->required_min_spend_micros : 0;
    }

    public function hasRequiredMinSpendMicros()
    {
        return isset($this->required_min_spend_micros);
    }

    public function clearRequiredMinSpendMicros()
    {
        unset($this->required_min_spend_micros);
    }

    /**
     * Output only. The minimum amount that must be spent to fulfill the coupon
     * requirements, in micros.
     *
     * Generated from protobuf field <code>optional int64 required_min_spend_micros = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int|string $var
     * @return $this
     */
    public function setRequiredMinSpendMicros($var)
    {
        GPBUtil::checkInt64($var);
        $this->required_min_spend_micros = $var;

        return $this;
    }

    /**
     * Output only. The current amount spent towards the fulfillment requirements,
     * in micros.
     *
     * Generated from protobuf field <code>optional int64 current_spend_towards_fulfillment_micros = 12 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int|string
     */
    public function getCurrentSpendTowardsFulfillmentMicros()
    {
        return isset($this->current_spend_towards_fulfillment_micros) ? $this->current_spend_towards_fulfillment_micros : 0;
    }

    public function hasCurrentSpendTowardsFulfillmentMicros()
    {
        return isset($this->current_spend_towards_fulfillment_micros);
    }

    public function clearCurrentSpendTowardsFulfillmentMicros()
    {
        unset($this->current_spend_towards_fulfillment_micros);
    }

    /**
     * Output only. The current amount spent towards the fulfillment requirements,
     * in micros.
     *
     * Generated from protobuf field <code>optional int64 current_spend_towards_fulfillment_micros = 12 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int|string $var
     * @return $this
     */
    public function setCurrentSpendTowardsFulfillmentMicros($var)
    {
        GPBUtil::checkInt64($var);
        $this->current_spend_towards_fulfillment_micros = $var;

        return $this;
    }

    /**
     * Output only. The remaining balance of the granted reward in micros.
     * This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional int64 reward_balance_remaining_micros = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int|string
     */
    public function getRewardBalanceRemainingMicros()
    {
        return isset($this->reward_balance_remaining_micros) ? $this->reward_balance_remaining_micros : 0;
    }

    public function hasRewardBalanceRemainingMicros()
    {
        return isset($this->reward_balance_remaining_micros);
    }

    public function clearRewardBalanceRemainingMicros()
    {
        unset($this->reward_balance_remaining_micros);
    }

    /**
     * Output only. The remaining balance of the granted reward in micros.
     * This field is not set if the reward has not been granted.
     *
     * Generated from protobuf field <code>optional int64 reward_balance_remaining_micros = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int|string $var
     * @return $this
     */
    public function setRewardBalanceRemainingMicros($var)
    {
        GPBUtil::checkInt64($var);
        $this->reward_balance_remaining_micros = $var;

        return $this;
    }

}

