Files
php-flasher/src/Prime/Stamp/PresenterStamp.php
T
Younes ENNAJI 3f920f2c01 Simplify PHPDoc comments in Plugin, HTTP, Stamp, and Test constraint classes
Removes verbose documentation while preserving type annotations.
2026-01-16 00:07:42 +01:00

24 lines
589 B
PHP

<?php
declare(strict_types=1);
namespace Flasher\Prime\Stamp;
final readonly class PresenterStamp implements StampInterface
{
/**
* @throws \InvalidArgumentException
*/
public function __construct(private string $pattern)
{
if (false === @preg_match($pattern, '')) {
throw new \InvalidArgumentException(\sprintf("The provided regex pattern '%s' is invalid for the presenter stamp. Please ensure it is a valid regex expression.", $pattern));
}
}
public function getPattern(): string
{
return $this->pattern;
}
}