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

namespace Google\Ads\GoogleAds\V20\Resources\Recommendation;

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

/**
 * Information of a target adjustment recommendation.
 *
 * Generated from protobuf message <code>google.ads.googleads.v20.resources.Recommendation.TargetAdjustmentInfo</code>
 */
class TargetAdjustmentInfo extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The shared set resource name of the portfolio bidding
     * strategy where the target is defined. Only populated if the
     * recommendation is portfolio level.
     *
     * Generated from protobuf field <code>optional string shared_set = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $shared_set = null;
    /**
     * Output only. The factor by which we recommend the target to be adjusted
     * by.
     *
     * Generated from protobuf field <code>double recommended_target_multiplier = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $recommended_target_multiplier = 0.0;
    /**
     * Output only. The current average target of the campaign or portfolio
     * targeted by this recommendation.
     *
     * Generated from protobuf field <code>int64 current_average_target_micros = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $current_average_target_micros = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $shared_set
     *           Output only. The shared set resource name of the portfolio bidding
     *           strategy where the target is defined. Only populated if the
     *           recommendation is portfolio level.
     *     @type float $recommended_target_multiplier
     *           Output only. The factor by which we recommend the target to be adjusted
     *           by.
     *     @type int|string $current_average_target_micros
     *           Output only. The current average target of the campaign or portfolio
     *           targeted by this recommendation.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Ads\GoogleAds\V20\Resources\Recommendation::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The shared set resource name of the portfolio bidding
     * strategy where the target is defined. Only populated if the
     * recommendation is portfolio level.
     *
     * Generated from protobuf field <code>optional string shared_set = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getSharedSet()
    {
        return isset($this->shared_set) ? $this->shared_set : '';
    }

    public function hasSharedSet()
    {
        return isset($this->shared_set);
    }

    public function clearSharedSet()
    {
        unset($this->shared_set);
    }

    /**
     * Output only. The shared set resource name of the portfolio bidding
     * strategy where the target is defined. Only populated if the
     * recommendation is portfolio level.
     *
     * Generated from protobuf field <code>optional string shared_set = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setSharedSet($var)
    {
        GPBUtil::checkString($var, True);
        $this->shared_set = $var;

        return $this;
    }

    /**
     * Output only. The factor by which we recommend the target to be adjusted
     * by.
     *
     * Generated from protobuf field <code>double recommended_target_multiplier = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return float
     */
    public function getRecommendedTargetMultiplier()
    {
        return $this->recommended_target_multiplier;
    }

    /**
     * Output only. The factor by which we recommend the target to be adjusted
     * by.
     *
     * Generated from protobuf field <code>double recommended_target_multiplier = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param float $var
     * @return $this
     */
    public function setRecommendedTargetMultiplier($var)
    {
        GPBUtil::checkDouble($var);
        $this->recommended_target_multiplier = $var;

        return $this;
    }

    /**
     * Output only. The current average target of the campaign or portfolio
     * targeted by this recommendation.
     *
     * Generated from protobuf field <code>int64 current_average_target_micros = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int|string
     */
    public function getCurrentAverageTargetMicros()
    {
        return $this->current_average_target_micros;
    }

    /**
     * Output only. The current average target of the campaign or portfolio
     * targeted by this recommendation.
     *
     * Generated from protobuf field <code>int64 current_average_target_micros = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int|string $var
     * @return $this
     */
    public function setCurrentAverageTargetMicros($var)
    {
        GPBUtil::checkInt64($var);
        $this->current_average_target_micros = $var;

        return $this;
    }

}

// Adding a class alias for backwards compatibility with the previous class name.
class_alias(TargetAdjustmentInfo::class, \Google\Ads\GoogleAds\V20\Resources\Recommendation_TargetAdjustmentInfo::class);

