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

namespace Google\Ads\GoogleAds\V24\Resources\Invoice;

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

/**
 * Represents adjustment information associated with an account.
 *
 * Generated from protobuf message <code>google.ads.googleads.v24.resources.Invoice.AdjustmentSummary</code>
 */
class AdjustmentSummary extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The description of the adjustment. Example: Incentive
     * Adjustment, discount.
     *
     * Generated from protobuf field <code>optional string adjustment_description = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $adjustment_description = null;
    /**
     * Output only. The amount of the adjustment, in micros. The currency code
     * for this amount is the same as the Invoice.currency_code.
     *
     * Generated from protobuf field <code>optional int64 amount_micros = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $amount_micros = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *                    Optional. Data for populating the Message object.
     *
     * @type string $adjustment_description
     *           Output only. The description of the adjustment. Example: Incentive
     *           Adjustment, discount.
     * @type int|string $amount_micros
     *           Output only. The amount of the adjustment, in micros. The currency code
     *           for this amount is the same as the Invoice.currency_code.
     * }
     */
    public function __construct($data = null)
    {
        \GPBMetadata\Google\Ads\GoogleAds\V24\Resources\Invoice::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The description of the adjustment. Example: Incentive
     * Adjustment, discount.
     *
     * Generated from protobuf field <code>optional string adjustment_description = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @return string
     */
    public function getAdjustmentDescription()
    {
        return isset($this->adjustment_description) ? $this->adjustment_description : '';
    }

    public function hasAdjustmentDescription()
    {
        return isset($this->adjustment_description);
    }

    public function clearAdjustmentDescription()
    {
        unset($this->adjustment_description);
    }

    /**
     * Output only. The description of the adjustment. Example: Incentive
     * Adjustment, discount.
     *
     * Generated from protobuf field <code>optional string adjustment_description = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @param  string $var
     * @return $this
     */
    public function setAdjustmentDescription($var)
    {
        GPBUtil::checkString($var, true);
        $this->adjustment_description = $var;

        return $this;
    }

    /**
     * Output only. The amount of the adjustment, in micros. The currency code
     * for this amount is the same as the Invoice.currency_code.
     *
     * Generated from protobuf field <code>optional int64 amount_micros = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @return int|string
     */
    public function getAmountMicros()
    {
        return isset($this->amount_micros) ? $this->amount_micros : 0;
    }

    public function hasAmountMicros()
    {
        return isset($this->amount_micros);
    }

    public function clearAmountMicros()
    {
        unset($this->amount_micros);
    }

    /**
     * Output only. The amount of the adjustment, in micros. The currency code
     * for this amount is the same as the Invoice.currency_code.
     *
     * Generated from protobuf field <code>optional int64 amount_micros = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @param  int|string $var
     * @return $this
     */
    public function setAmountMicros($var)
    {
        GPBUtil::checkInt64($var);
        $this->amount_micros = $var;

        return $this;
    }

}

