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

namespace Google\Ads\GoogleAds\V23\Resources;

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

/**
 * Represents a video that can include both advertiser uploaded videos or
 * enhancements generated from the advertiser uploaded videos. Only publicly
 * available videos are returned.
 * Each row in this resource represents either the video uploaded by the
 * advertiser or each specific variation of it. In contrast, the `Video`
 * resource represents only the advertiser-provided video and would aggregate
 * metrics across all its variations (including enhancements).
 * {-- next tag to use: 5 --}
 *
 * Generated from protobuf message <code>google.ads.googleads.v23.resources.VideoEnhancement</code>
 */
class VideoEnhancement extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The resource name of the video enhancement.
     * Video enhancement resource names have the form:
     * `customers/{customer_id}/videoEnhancements/{video_id}`
     *
     * 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. Duration of this video, in milliseconds.
     *
     * Generated from protobuf field <code>int64 duration_millis = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $duration_millis = 0;
    /**
     * Output only. The source of the video (e.g. advertiser or enhanced by Google
     * Ads).
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.enums.VideoEnhancementSourceEnum.VideoEnhancementSource source = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $source = 0;
    /**
     * Output only. Title of this video.
     *
     * Generated from protobuf field <code>string title = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $title = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *                    Optional. Data for populating the Message object.
     *
     * @type string $resource_name
     *           Output only. The resource name of the video enhancement.
     *           Video enhancement resource names have the form:
     *           `customers/{customer_id}/videoEnhancements/{video_id}`
     * @type int|string $duration_millis
     *           Output only. Duration of this video, in milliseconds.
     * @type int $source
     *           Output only. The source of the video (e.g. advertiser or enhanced by Google
     *           Ads).
     * @type string $title
     *           Output only. Title of this video.
     * }
     */
    public function __construct($data = null)
    {
        \GPBMetadata\Google\Ads\GoogleAds\V23\Resources\VideoEnhancement::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The resource name of the video enhancement.
     * Video enhancement resource names have the form:
     * `customers/{customer_id}/videoEnhancements/{video_id}`
     *
     * 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 video enhancement.
     * Video enhancement resource names have the form:
     * `customers/{customer_id}/videoEnhancements/{video_id}`
     *
     * 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. Duration of this video, in milliseconds.
     *
     * Generated from protobuf field <code>int64 duration_millis = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @return int|string
     */
    public function getDurationMillis()
    {
        return $this->duration_millis;
    }

    /**
     * Output only. Duration of this video, in milliseconds.
     *
     * Generated from protobuf field <code>int64 duration_millis = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @param  int|string $var
     * @return $this
     */
    public function setDurationMillis($var)
    {
        GPBUtil::checkInt64($var);
        $this->duration_millis = $var;

        return $this;
    }

    /**
     * Output only. The source of the video (e.g. advertiser or enhanced by Google
     * Ads).
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.enums.VideoEnhancementSourceEnum.VideoEnhancementSource source = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @return int
     */
    public function getSource()
    {
        return $this->source;
    }

    /**
     * Output only. The source of the video (e.g. advertiser or enhanced by Google
     * Ads).
     *
     * Generated from protobuf field <code>.google.ads.googleads.v23.enums.VideoEnhancementSourceEnum.VideoEnhancementSource source = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @param  int $var
     * @return $this
     */
    public function setSource($var)
    {
        GPBUtil::checkEnum($var, \Google\Ads\GoogleAds\V23\Enums\VideoEnhancementSourceEnum\VideoEnhancementSource::class);
        $this->source = $var;

        return $this;
    }

    /**
     * Output only. Title of this video.
     *
     * Generated from protobuf field <code>string title = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @return string
     */
    public function getTitle()
    {
        return $this->title;
    }

    /**
     * Output only. Title of this video.
     *
     * Generated from protobuf field <code>string title = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     *
     * @param  string $var
     * @return $this
     */
    public function setTitle($var)
    {
        GPBUtil::checkString($var, true);
        $this->title = $var;

        return $this;
    }

}

