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

namespace Google\Ads\GoogleAds\V23\Resources\Campaign;

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

/**
 * Settings to control automatically generated text assets.
 *
 * Generated from protobuf message <code>google.ads.googleads.v23.resources.Campaign.TextGuidelines</code>
 */
class TextGuidelines extends \Google\Protobuf\Internal\Message
{
    /**
     * Exact words or phrases that will be excluded from generated text
     * assets. At most 25 exclusions may be provided. Valid exclusions may
     * contain a maximum of 30 characters.
     *
     * Generated from protobuf field <code>repeated string term_exclusions = 1;</code>
     */
    private $term_exclusions;
    /**
     * Freeform instructions that will be used to guide text asset generation
     * using LLM inference. At most 40 restrictions may be provided.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.resources.Campaign.MessagingRestriction messaging_restrictions = 2;</code>
     */
    private $messaging_restrictions;

    /**
     * Constructor.
     *
     * @param array $data {
     *                    Optional. Data for populating the Message object.
     *
     * @type string[] $term_exclusions
     *           Exact words or phrases that will be excluded from generated text
     *           assets. At most 25 exclusions may be provided. Valid exclusions may
     *           contain a maximum of 30 characters.
     * @type \Google\Ads\GoogleAds\V23\Resources\Campaign\MessagingRestriction[] $messaging_restrictions
     *           Freeform instructions that will be used to guide text asset generation
     *           using LLM inference. At most 40 restrictions may be provided.
     * }
     */
    public function __construct($data = null)
    {
        \GPBMetadata\Google\Ads\GoogleAds\V23\Resources\Campaign::initOnce();
        parent::__construct($data);
    }

    /**
     * Exact words or phrases that will be excluded from generated text
     * assets. At most 25 exclusions may be provided. Valid exclusions may
     * contain a maximum of 30 characters.
     *
     * Generated from protobuf field <code>repeated string term_exclusions = 1;</code>
     *
     * @return RepeatedField<string>
     */
    public function getTermExclusions()
    {
        return $this->term_exclusions;
    }

    /**
     * Exact words or phrases that will be excluded from generated text
     * assets. At most 25 exclusions may be provided. Valid exclusions may
     * contain a maximum of 30 characters.
     *
     * Generated from protobuf field <code>repeated string term_exclusions = 1;</code>
     *
     * @param  string[] $var
     * @return $this
     */
    public function setTermExclusions($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->term_exclusions = $arr;

        return $this;
    }

    /**
     * Freeform instructions that will be used to guide text asset generation
     * using LLM inference. At most 40 restrictions may be provided.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.resources.Campaign.MessagingRestriction messaging_restrictions = 2;</code>
     *
     * @return RepeatedField<\Google\Ads\GoogleAds\V23\Resources\Campaign\MessagingRestriction>
     */
    public function getMessagingRestrictions()
    {
        return $this->messaging_restrictions;
    }

    /**
     * Freeform instructions that will be used to guide text asset generation
     * using LLM inference. At most 40 restrictions may be provided.
     *
     * Generated from protobuf field <code>repeated .google.ads.googleads.v23.resources.Campaign.MessagingRestriction messaging_restrictions = 2;</code>
     *
     * @param  \Google\Ads\GoogleAds\V23\Resources\Campaign\MessagingRestriction[] $var
     * @return $this
     */
    public function setMessagingRestrictions($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Ads\GoogleAds\V23\Resources\Campaign\MessagingRestriction::class);
        $this->messaging_restrictions = $arr;

        return $this;
    }

}

