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

namespace Google\Ads\GoogleAds\V23\Services;

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

/**
 * YouTube Channel insights, and its metadata (such as channel name and channel
 * ID), returned for a creator insights response.
 *
 * Generated from protobuf message <code>google.ads.googleads.v23.services.YouTubeChannelInsights</code>
 */
class YouTubeChannelInsights extends \Google\Protobuf\Internal\Message
{
    /**
     * The name of the YouTube Channel.
     *
     * Generated from protobuf field <code>string display_name = 1;</code>
     */
    protected $display_name = '';
    /**
     * The YouTube Channel ID.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.common.YouTubeChannelInfo youtube_channel = 2;</code>
     */
    protected $youtube_channel = null;
    /**
     * URL for the channel in the form of
     * https://www.youtube.com/channel/{channel_id}.
     *
     * Generated from protobuf field <code>string channel_url = 9;</code>
     */
    protected $channel_url = '';
    /**
     * Description of the channel.
     *
     * Generated from protobuf field <code>string channel_description = 10;</code>
     */
    protected $channel_description = '';
    /**
     * The unique, short, and user-visible identifier for the channel starting
     * with an "&#64;" symbol (such as "&#64;youtubecreators"). See
     * https://support.google.com/youtube/answer/11585688 for more information.
     *
     * Generated from protobuf field <code>string handle = 11;</code>
     */
    protected $handle = '';
    /**
     * URL for a 240px by 240px thumbnail image of the channel.
     *
     * Generated from protobuf field <code>string thumbnail_url = 12;</code>
     */
    protected $thumbnail_url = '';
    /**
     * The date that the channel was created. Formatted as "yyyy-mm-dd".
     *
     * Generated from protobuf field <code>string publish_date = 13;</code>
     */
    protected $publish_date = '';
    /**
     * The country with which the channel is associated.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.common.LocationInfo country_location = 14;</code>
     */
    protected $country_location = null;
    /**
     * The metrics for a YouTube Channel.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.services.YouTubeMetrics channel_metrics = 3;</code>
     */
    protected $channel_metrics = null;
    /**
     * The types of audiences and demographics linked to the channel's main
     * audience. Audiences and demographics have a breakdown of subscriber share
     * across dimensions of the same value, such as Age Range, Gender, and User
     * Interest.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata channel_audience_attributes = 7;</code>
     */
    private $channel_audience_attributes;
    /**
     * The attributes associated with the content made by a channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata channel_attributes = 5;</code>
     */
    private $channel_attributes;
    /**
     * The top 10 videos for the channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata top_videos = 8;</code>
     */
    private $top_videos;
    /**
     * The languages associated with the content made by a channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.services.LanguageDistribution language_distributions = 15;</code>
     */
    private $language_distributions;
    /**
     * Metadata string associated with the type of channel.
     *
     * Generated from protobuf field <code>string channel_type = 6;</code>
     */
    protected $channel_type = '';
    /**
     * The relevance score of the channel to the topic being searched for weighted
     * by views. The value is between 0 and 1, with 1 being the most relevant.
     * Only populated for trends using search_topics.
     *
     * Generated from protobuf field <code>double relevance_score = 16;</code>
     */
    protected $relevance_score = 0.0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $display_name
     *           The name of the YouTube Channel.
     *     @type \Google\Ads\GoogleAds\V23\Common\YouTubeChannelInfo $youtube_channel
     *           The YouTube Channel ID.
     *     @type string $channel_url
     *           URL for the channel in the form of
     *           https://www.youtube.com/channel/{channel_id}.
     *     @type string $channel_description
     *           Description of the channel.
     *     @type string $handle
     *           The unique, short, and user-visible identifier for the channel starting
     *           with an "&#64;" symbol (such as "&#64;youtubecreators"). See
     *           https://support.google.com/youtube/answer/11585688 for more information.
     *     @type string $thumbnail_url
     *           URL for a 240px by 240px thumbnail image of the channel.
     *     @type string $publish_date
     *           The date that the channel was created. Formatted as "yyyy-mm-dd".
     *     @type \Google\Ads\GoogleAds\V23\Common\LocationInfo $country_location
     *           The country with which the channel is associated.
     *     @type \Google\Ads\GoogleAds\V23\Services\YouTubeMetrics $channel_metrics
     *           The metrics for a YouTube Channel.
     *     @type array<\Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata>|\Google\Protobuf\Internal\RepeatedField $channel_audience_attributes
     *           The types of audiences and demographics linked to the channel's main
     *           audience. Audiences and demographics have a breakdown of subscriber share
     *           across dimensions of the same value, such as Age Range, Gender, and User
     *           Interest.
     *     @type array<\Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata>|\Google\Protobuf\Internal\RepeatedField $channel_attributes
     *           The attributes associated with the content made by a channel.
     *     @type array<\Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata>|\Google\Protobuf\Internal\RepeatedField $top_videos
     *           The top 10 videos for the channel.
     *     @type array<\Google\Ads\GoogleAds\V23\Services\LanguageDistribution>|\Google\Protobuf\Internal\RepeatedField $language_distributions
     *           The languages associated with the content made by a channel.
     *     @type string $channel_type
     *           Metadata string associated with the type of channel.
     *     @type float $relevance_score
     *           The relevance score of the channel to the topic being searched for weighted
     *           by views. The value is between 0 and 1, with 1 being the most relevant.
     *           Only populated for trends using search_topics.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Ads\GoogleAds\V23\Services\ContentCreatorInsightsService::initOnce();
        parent::__construct($data);
    }

    /**
     * The name of the YouTube Channel.
     *
     * Generated from protobuf field <code>string display_name = 1;</code>
     * @return string
     */
    public function getDisplayName()
    {
        return $this->display_name;
    }

    /**
     * The name of the YouTube Channel.
     *
     * Generated from protobuf field <code>string display_name = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setDisplayName($var)
    {
        GPBUtil::checkString($var, True);
        $this->display_name = $var;

        return $this;
    }

    /**
     * The YouTube Channel ID.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.common.YouTubeChannelInfo youtube_channel = 2;</code>
     * @return \Google\Ads\GoogleAds\V23\Common\YouTubeChannelInfo|null
     */
    public function getYoutubeChannel()
    {
        return $this->youtube_channel;
    }

    public function hasYoutubeChannel()
    {
        return isset($this->youtube_channel);
    }

    public function clearYoutubeChannel()
    {
        unset($this->youtube_channel);
    }

    /**
     * The YouTube Channel ID.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.common.YouTubeChannelInfo youtube_channel = 2;</code>
     * @param \Google\Ads\GoogleAds\V23\Common\YouTubeChannelInfo $var
     * @return $this
     */
    public function setYoutubeChannel($var)
    {
        GPBUtil::checkMessage($var, \Google\Ads\GoogleAds\V23\Common\YouTubeChannelInfo::class);
        $this->youtube_channel = $var;

        return $this;
    }

    /**
     * URL for the channel in the form of
     * https://www.youtube.com/channel/{channel_id}.
     *
     * Generated from protobuf field <code>string channel_url = 9;</code>
     * @return string
     */
    public function getChannelUrl()
    {
        return $this->channel_url;
    }

    /**
     * URL for the channel in the form of
     * https://www.youtube.com/channel/{channel_id}.
     *
     * Generated from protobuf field <code>string channel_url = 9;</code>
     * @param string $var
     * @return $this
     */
    public function setChannelUrl($var)
    {
        GPBUtil::checkString($var, True);
        $this->channel_url = $var;

        return $this;
    }

    /**
     * Description of the channel.
     *
     * Generated from protobuf field <code>string channel_description = 10;</code>
     * @return string
     */
    public function getChannelDescription()
    {
        return $this->channel_description;
    }

    /**
     * Description of the channel.
     *
     * Generated from protobuf field <code>string channel_description = 10;</code>
     * @param string $var
     * @return $this
     */
    public function setChannelDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->channel_description = $var;

        return $this;
    }

    /**
     * The unique, short, and user-visible identifier for the channel starting
     * with an "&#64;" symbol (such as "&#64;youtubecreators"). See
     * https://support.google.com/youtube/answer/11585688 for more information.
     *
     * Generated from protobuf field <code>string handle = 11;</code>
     * @return string
     */
    public function getHandle()
    {
        return $this->handle;
    }

    /**
     * The unique, short, and user-visible identifier for the channel starting
     * with an "&#64;" symbol (such as "&#64;youtubecreators"). See
     * https://support.google.com/youtube/answer/11585688 for more information.
     *
     * Generated from protobuf field <code>string handle = 11;</code>
     * @param string $var
     * @return $this
     */
    public function setHandle($var)
    {
        GPBUtil::checkString($var, True);
        $this->handle = $var;

        return $this;
    }

    /**
     * URL for a 240px by 240px thumbnail image of the channel.
     *
     * Generated from protobuf field <code>string thumbnail_url = 12;</code>
     * @return string
     */
    public function getThumbnailUrl()
    {
        return $this->thumbnail_url;
    }

    /**
     * URL for a 240px by 240px thumbnail image of the channel.
     *
     * Generated from protobuf field <code>string thumbnail_url = 12;</code>
     * @param string $var
     * @return $this
     */
    public function setThumbnailUrl($var)
    {
        GPBUtil::checkString($var, True);
        $this->thumbnail_url = $var;

        return $this;
    }

    /**
     * The date that the channel was created. Formatted as "yyyy-mm-dd".
     *
     * Generated from protobuf field <code>string publish_date = 13;</code>
     * @return string
     */
    public function getPublishDate()
    {
        return $this->publish_date;
    }

    /**
     * The date that the channel was created. Formatted as "yyyy-mm-dd".
     *
     * Generated from protobuf field <code>string publish_date = 13;</code>
     * @param string $var
     * @return $this
     */
    public function setPublishDate($var)
    {
        GPBUtil::checkString($var, True);
        $this->publish_date = $var;

        return $this;
    }

    /**
     * The country with which the channel is associated.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.common.LocationInfo country_location = 14;</code>
     * @return \Google\Ads\GoogleAds\V23\Common\LocationInfo|null
     */
    public function getCountryLocation()
    {
        return $this->country_location;
    }

    public function hasCountryLocation()
    {
        return isset($this->country_location);
    }

    public function clearCountryLocation()
    {
        unset($this->country_location);
    }

    /**
     * The country with which the channel is associated.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.common.LocationInfo country_location = 14;</code>
     * @param \Google\Ads\GoogleAds\V23\Common\LocationInfo $var
     * @return $this
     */
    public function setCountryLocation($var)
    {
        GPBUtil::checkMessage($var, \Google\Ads\GoogleAds\V23\Common\LocationInfo::class);
        $this->country_location = $var;

        return $this;
    }

    /**
     * The metrics for a YouTube Channel.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.services.YouTubeMetrics channel_metrics = 3;</code>
     * @return \Google\Ads\GoogleAds\V23\Services\YouTubeMetrics|null
     */
    public function getChannelMetrics()
    {
        return $this->channel_metrics;
    }

    public function hasChannelMetrics()
    {
        return isset($this->channel_metrics);
    }

    public function clearChannelMetrics()
    {
        unset($this->channel_metrics);
    }

    /**
     * The metrics for a YouTube Channel.
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.services.YouTubeMetrics channel_metrics = 3;</code>
     * @param \Google\Ads\GoogleAds\V23\Services\YouTubeMetrics $var
     * @return $this
     */
    public function setChannelMetrics($var)
    {
        GPBUtil::checkMessage($var, \Google\Ads\GoogleAds\V23\Services\YouTubeMetrics::class);
        $this->channel_metrics = $var;

        return $this;
    }

    /**
     * The types of audiences and demographics linked to the channel's main
     * audience. Audiences and demographics have a breakdown of subscriber share
     * across dimensions of the same value, such as Age Range, Gender, and User
     * Interest.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata channel_audience_attributes = 7;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getChannelAudienceAttributes()
    {
        return $this->channel_audience_attributes;
    }

    /**
     * The types of audiences and demographics linked to the channel's main
     * audience. Audiences and demographics have a breakdown of subscriber share
     * across dimensions of the same value, such as Age Range, Gender, and User
     * Interest.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata channel_audience_attributes = 7;</code>
     * @param array<\Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setChannelAudienceAttributes($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata::class);
        $this->channel_audience_attributes = $arr;

        return $this;
    }

    /**
     * The attributes associated with the content made by a channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata channel_attributes = 5;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getChannelAttributes()
    {
        return $this->channel_attributes;
    }

    /**
     * The attributes associated with the content made by a channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata channel_attributes = 5;</code>
     * @param array<\Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setChannelAttributes($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata::class);
        $this->channel_attributes = $arr;

        return $this;
    }

    /**
     * The top 10 videos for the channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata top_videos = 8;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getTopVideos()
    {
        return $this->top_videos;
    }

    /**
     * The top 10 videos for the channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.common.AudienceInsightsAttributeMetadata top_videos = 8;</code>
     * @param array<\Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setTopVideos($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Ads\GoogleAds\V23\Common\AudienceInsightsAttributeMetadata::class);
        $this->top_videos = $arr;

        return $this;
    }

    /**
     * The languages associated with the content made by a channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.services.LanguageDistribution language_distributions = 15;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getLanguageDistributions()
    {
        return $this->language_distributions;
    }

    /**
     * The languages associated with the content made by a channel.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.services.LanguageDistribution language_distributions = 15;</code>
     * @param array<\Google\Ads\GoogleAds\V23\Services\LanguageDistribution>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setLanguageDistributions($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Ads\GoogleAds\V23\Services\LanguageDistribution::class);
        $this->language_distributions = $arr;

        return $this;
    }

    /**
     * Metadata string associated with the type of channel.
     *
     * Generated from protobuf field <code>string channel_type = 6;</code>
     * @return string
     */
    public function getChannelType()
    {
        return $this->channel_type;
    }

    /**
     * Metadata string associated with the type of channel.
     *
     * Generated from protobuf field <code>string channel_type = 6;</code>
     * @param string $var
     * @return $this
     */
    public function setChannelType($var)
    {
        GPBUtil::checkString($var, True);
        $this->channel_type = $var;

        return $this;
    }

    /**
     * The relevance score of the channel to the topic being searched for weighted
     * by views. The value is between 0 and 1, with 1 being the most relevant.
     * Only populated for trends using search_topics.
     *
     * Generated from protobuf field <code>double relevance_score = 16;</code>
     * @return float
     */
    public function getRelevanceScore()
    {
        return $this->relevance_score;
    }

    /**
     * The relevance score of the channel to the topic being searched for weighted
     * by views. The value is between 0 and 1, with 1 being the most relevant.
     * Only populated for trends using search_topics.
     *
     * Generated from protobuf field <code>double relevance_score = 16;</code>
     * @param float $var
     * @return $this
     */
    public function setRelevanceScore($var)
    {
        GPBUtil::checkDouble($var);
        $this->relevance_score = $var;

        return $this;
    }

}

