You are here

constant ResourceVersionRouteEnhancer::VERSION_IDENTIFIER_VALIDATOR in JSON:API 8.2

Resource version validation regex.

@todo When D8 requires PHP >=5.6, convert to expression using the VersionNegotiator::SEPARATOR constant.

File

src/Revisions/ResourceVersionRouteEnhancer.php, line 63

Class

ResourceVersionRouteEnhancer
Loads an appropriate revision for the requested resource version.

Namespace

Drupal\jsonapi\Revisions

Code

const VERSION_IDENTIFIER_VALIDATOR = '/^[a-z]+[a-z_]*[a-z]+:[a-zA-Z0-9\\-]+(:[a-zA-Z0-9\\-]+)*$/';