<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/privacy/dlp/v2/dlp.proto

namespace Google\Cloud\Dlp\V2;

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

/**
 * A collection of regular expressions to determine what tables to match
 * against.
 *
 * Generated from protobuf message <code>google.privacy.dlp.v2.BigQueryRegexes</code>
 */
class BigQueryRegexes extends \Google\Protobuf\Internal\Message
{
    /**
     * A single BigQuery regular expression pattern to match against one or more
     * tables, datasets, or projects that contain BigQuery tables.
     *
     * Generated from protobuf field <code>repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1;</code>
     */
    private $patterns;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\Dlp\V2\BigQueryRegex[] $patterns
     *           A single BigQuery regular expression pattern to match against one or more
     *           tables, datasets, or projects that contain BigQuery tables.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce();
        parent::__construct($data);
    }

    /**
     * A single BigQuery regular expression pattern to match against one or more
     * tables, datasets, or projects that contain BigQuery tables.
     *
     * Generated from protobuf field <code>repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1;</code>
     * @return RepeatedField<\Google\Cloud\Dlp\V2\BigQueryRegex>
     */
    public function getPatterns()
    {
        return $this->patterns;
    }

    /**
     * A single BigQuery regular expression pattern to match against one or more
     * tables, datasets, or projects that contain BigQuery tables.
     *
     * Generated from protobuf field <code>repeated .google.privacy.dlp.v2.BigQueryRegex patterns = 1;</code>
     * @param \Google\Cloud\Dlp\V2\BigQueryRegex[] $var
     * @return $this
     */
    public function setPatterns($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dlp\V2\BigQueryRegex::class);
        $this->patterns = $arr;

        return $this;
    }

}

