final class CacheKeyValidator (View source)

Enforces the PSR-6 key restrictions shared by framework cache implementations.

Constants

private RESERVED_PATTERN

Methods

static void
assertValid(string $key)

Rejects empty keys and keys containing characters reserved by PSR-6.

void

Details

assertValid

static void assertValid(string $key)

Rejects empty keys and keys containing characters reserved by PSR-6.

Parameters

string $key

Return Value

void

Exceptions

InvalidCacheKeyException