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

namespace Google\Ads\GoogleAds\V24\Services;

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

/**
 * Dimensions by which the breakdown metrics are grouped by.
 *
 * Generated from protobuf message <code>google.ads.googleads.v24.services.BreakdownKey</code>
 */
class BreakdownKey extends \Google\Protobuf\Internal\Message
{
    /**
     * Dates used for the breakdown. For example, this represents the start and
     * end dates of the week for a weekly breakdown.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v24.common.DateRange dates = 1;</code>
     */
    protected $dates = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *                    Optional. Data for populating the Message object.
     *
     * @type \Google\Ads\GoogleAds\V24\Common\DateRange $dates
     *           Dates used for the breakdown. For example, this represents the start and
     *           end dates of the week for a weekly breakdown.
     * }
     */
    public function __construct($data = null)
    {
        \GPBMetadata\Google\Ads\GoogleAds\V24\Services\BenchmarksService::initOnce();
        parent::__construct($data);
    }

    /**
     * Dates used for the breakdown. For example, this represents the start and
     * end dates of the week for a weekly breakdown.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v24.common.DateRange dates = 1;</code>
     *
     * @return \Google\Ads\GoogleAds\V24\Common\DateRange|null
     */
    public function getDates()
    {
        return $this->dates;
    }

    public function hasDates()
    {
        return isset($this->dates);
    }

    public function clearDates()
    {
        unset($this->dates);
    }

    /**
     * Dates used for the breakdown. For example, this represents the start and
     * end dates of the week for a weekly breakdown.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v24.common.DateRange dates = 1;</code>
     *
     * @param  \Google\Ads\GoogleAds\V24\Common\DateRange $var
     * @return $this
     */
    public function setDates($var)
    {
        GPBUtil::checkMessage($var, \Google\Ads\GoogleAds\V24\Common\DateRange::class);
        $this->dates = $var;

        return $this;
    }

}

