File "NotRegex.php"

Full Path: /var/www/html/back/vendor/spatie/laravel-data/src/Attributes/Validation/NotRegex.php
File size: 533 bytes
MIME-type: text/x-php
Charset: utf-8

<?php

namespace Spatie\LaravelData\Attributes\Validation;

use Attribute;
use Spatie\LaravelData\Support\Validation\References\ExternalReference;

#[Attribute(Attribute::TARGET_PROPERTY | Attribute::TARGET_PARAMETER)]
class NotRegex extends StringValidationAttribute
{
    public function __construct(protected string|ExternalReference $pattern)
    {
    }

    public static function keyword(): string
    {
        return 'not_regex';
    }

    public function parameters(): array
    {
        return [$this->pattern];
    }
}