<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: keyapis/encryption_profile/v1/keyapis_encryption_profile_encryption_profile_v1.proto

namespace Keyapis\EncryptionProfile\V1;

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

/**
 * Фильтр по профилям шифрования
 *
 * Generated from protobuf message <code>keyapis.encryption_profile.v1.EncryptionProfileFilter</code>
 */
class EncryptionProfileFilter extends \Google\Protobuf\Internal\Message
{
    /**
     * Поиск по тексту.
     * Если значение не передано то поиск по нему не производится.
     * # Диапазон: 3..64.
     * # Поиск производится по полям:
     * # - Наименование;
     * # - Описание
     *
     * Generated from protobuf field <code>string text = 1;</code>
     */
    protected $text = '';
    /**
     * По типам профиля шифрования
     *
     * Generated from protobuf field <code>repeated .keyapis.encryption_profile.v1.EncryptionProfile.Type types = 2;</code>
     */
    private $types;
    /**
     * Показывать удаленные
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue show_deleted = 3;</code>
     */
    protected $show_deleted = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $text
     *           Поиск по тексту.
     *           Если значение не передано то поиск по нему не производится.
     *           # Диапазон: 3..64.
     *           # Поиск производится по полям:
     *           # - Наименование;
     *           # - Описание
     *     @type array<int>|\Google\Protobuf\Internal\RepeatedField $types
     *           По типам профиля шифрования
     *     @type \Google\Protobuf\BoolValue $show_deleted
     *           Показывать удаленные
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Keyapis\EncryptionProfile\V1\KeyapisEncryptionProfileEncryptionProfileV1::initOnce();
        parent::__construct($data);
    }

    /**
     * Поиск по тексту.
     * Если значение не передано то поиск по нему не производится.
     * # Диапазон: 3..64.
     * # Поиск производится по полям:
     * # - Наименование;
     * # - Описание
     *
     * Generated from protobuf field <code>string text = 1;</code>
     * @return string
     */
    public function getText()
    {
        return $this->text;
    }

    /**
     * Поиск по тексту.
     * Если значение не передано то поиск по нему не производится.
     * # Диапазон: 3..64.
     * # Поиск производится по полям:
     * # - Наименование;
     * # - Описание
     *
     * Generated from protobuf field <code>string text = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setText($var)
    {
        GPBUtil::checkString($var, True);
        $this->text = $var;

        return $this;
    }

    /**
     * По типам профиля шифрования
     *
     * Generated from protobuf field <code>repeated .keyapis.encryption_profile.v1.EncryptionProfile.Type types = 2;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getTypes()
    {
        return $this->types;
    }

    /**
     * По типам профиля шифрования
     *
     * Generated from protobuf field <code>repeated .keyapis.encryption_profile.v1.EncryptionProfile.Type types = 2;</code>
     * @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setTypes($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Keyapis\EncryptionProfile\V1\EncryptionProfile\Type::class);
        $this->types = $arr;

        return $this;
    }

    /**
     * Показывать удаленные
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue show_deleted = 3;</code>
     * @return \Google\Protobuf\BoolValue|null
     */
    public function getShowDeleted()
    {
        return $this->show_deleted;
    }

    public function hasShowDeleted()
    {
        return isset($this->show_deleted);
    }

    public function clearShowDeleted()
    {
        unset($this->show_deleted);
    }

    /**
     * Returns the unboxed value from <code>getShowDeleted()</code>

     * Показывать удаленные
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue show_deleted = 3;</code>
     * @return bool|null
     */
    public function getShowDeletedUnwrapped()
    {
        return $this->readWrapperValue("show_deleted");
    }

    /**
     * Показывать удаленные
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue show_deleted = 3;</code>
     * @param \Google\Protobuf\BoolValue $var
     * @return $this
     */
    public function setShowDeleted($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\BoolValue::class);
        $this->show_deleted = $var;

        return $this;
    }

    /**
     * Sets the field by wrapping a primitive type in a Google\Protobuf\BoolValue object.

     * Показывать удаленные
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue show_deleted = 3;</code>
     * @param bool|null $var
     * @return $this
     */
    public function setShowDeletedUnwrapped($var)
    {
        $this->writeWrapperValue("show_deleted", $var);
        return $this;}

}

