0 follower

Final Class Yiisoft\HttpMiddleware\TagRequest\TagProvider\PrefixedTagProvider

InheritanceYiisoft\HttpMiddleware\TagRequest\TagProvider\PrefixedTagProvider
ImplementsYiisoft\HttpMiddleware\TagRequest\TagProvider\TagProviderInterface

A tag provider that prefixes the result of a decorated tag provider with a specified string.

Method Details

Hide inherited methods

__construct() public method

public mixed __construct ( string $prefix, Yiisoft\HttpMiddleware\TagRequest\TagProvider\TagProviderInterface $decorated )
$prefix string

The prefix to add to the tag.

$decorated Yiisoft\HttpMiddleware\TagRequest\TagProvider\TagProviderInterface

The decorated tag provider.

                public function __construct(
    private readonly string $prefix,
    private readonly TagProviderInterface $decorated,
) {
}

            
get() public method

public string get ( )

                public function get(): string
{
    return $this->prefix . $this->decorated->get();
}