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

namespace Google\Ads\GoogleAds\V24\Resources;

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

/**
 * A Smart campaign search term view.
 *
 * Generated from protobuf message <code>google.ads.googleads.v24.resources.SmartCampaignSearchTermView</code>
 */
class SmartCampaignSearchTermView extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The resource name of the Smart campaign search term view.
     * Smart campaign search term view resource names have the form:
     * `customers/{customer_id}/smartCampaignSearchTermViews/{campaign_id}~{URL-base64_search_term}`
     *
     * 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 search term.
     *
     * Generated from protobuf field <code>string search_term = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $search_term = '';
    /**
     * Output only. The Smart campaign the search term served in.
     *
     * Generated from protobuf field <code>string campaign = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     */
    protected $campaign = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *                    Optional. Data for populating the Message object.
     *
     * @type string $resource_name
     *           Output only. The resource name of the Smart campaign search term view.
     *           Smart campaign search term view resource names have the form:
     *           `customers/{customer_id}/smartCampaignSearchTermViews/{campaign_id}~{URL-base64_search_term}`
     * @type string $search_term
     *           Output only. The search term.
     * @type string $campaign
     *           Output only. The Smart campaign the search term served in.
     * }
     */
    public function __construct($data = null)
    {
        \GPBMetadata\Google\Ads\GoogleAds\V24\Resources\SmartCampaignSearchTermView::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The resource name of the Smart campaign search term view.
     * Smart campaign search term view resource names have the form:
     * `customers/{customer_id}/smartCampaignSearchTermViews/{campaign_id}~{URL-base64_search_term}`
     *
     * 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 Smart campaign search term view.
     * Smart campaign search term view resource names have the form:
     * `customers/{customer_id}/smartCampaignSearchTermViews/{campaign_id}~{URL-base64_search_term}`
     *
     * 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 search term.
     *
     * Generated from protobuf field <code>string search_term = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @return string
     */
    public function getSearchTerm()
    {
        return $this->search_term;
    }

    /**
     * Output only. The search term.
     *
     * Generated from protobuf field <code>string search_term = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @param  string $var
     * @return $this
     */
    public function setSearchTerm($var)
    {
        GPBUtil::checkString($var, true);
        $this->search_term = $var;

        return $this;
    }

    /**
     * Output only. The Smart campaign the search term served in.
     *
     * Generated from protobuf field <code>string campaign = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     *
     * @return string
     */
    public function getCampaign()
    {
        return $this->campaign;
    }

    /**
     * Output only. The Smart campaign the search term served in.
     *
     * Generated from protobuf field <code>string campaign = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = {</code>
     *
     * @param  string $var
     * @return $this
     */
    public function setCampaign($var)
    {
        GPBUtil::checkString($var, true);
        $this->campaign = $var;

        return $this;
    }

}

