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

namespace Google\Ads\GoogleAds\V23\Services;

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

/**
 * All metrics returned against a criteria.
 *
 * Generated from protobuf message <code>google.ads.googleads.v23.services.Metrics</code>
 */
class Metrics extends \Google\Protobuf\Internal\Message
{
    /**
     * Average rate metrics calculated by dividing one metric by another.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.services.RateMetrics average_rate_metrics = 1;</code>
     */
    protected $average_rate_metrics = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Ads\GoogleAds\V23\Services\RateMetrics $average_rate_metrics
     *           Average rate metrics calculated by dividing one metric by another.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Ads\GoogleAds\V23\Services\BenchmarksService::initOnce();
        parent::__construct($data);
    }

    /**
     * Average rate metrics calculated by dividing one metric by another.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.services.RateMetrics average_rate_metrics = 1;</code>
     * @return \Google\Ads\GoogleAds\V23\Services\RateMetrics|null
     */
    public function getAverageRateMetrics()
    {
        return $this->average_rate_metrics;
    }

    public function hasAverageRateMetrics()
    {
        return isset($this->average_rate_metrics);
    }

    public function clearAverageRateMetrics()
    {
        unset($this->average_rate_metrics);
    }

    /**
     * Average rate metrics calculated by dividing one metric by another.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.services.RateMetrics average_rate_metrics = 1;</code>
     * @param \Google\Ads\GoogleAds\V23\Services\RateMetrics $var
     * @return $this
     */
    public function setAverageRateMetrics($var)
    {
        GPBUtil::checkMessage($var, \Google\Ads\GoogleAds\V23\Services\RateMetrics::class);
        $this->average_rate_metrics = $var;

        return $this;
    }

}

