Exponential Basic 2.4.0.1 Exponential Basic CMS — PHP Class Reference

Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ezpRestDefaultRegexpPrefixFilter Class Reference
Inheritance diagram for ezpRestDefaultRegexpPrefixFilter:

## Public Member Functions
| __construct (ezcMvcRequest $request, $apiPrefix)
| filter ()
Public Member Functions inherited from ezpRestPrefixFilterInterface
| filterRequestUri ()

## Protected Member Functions
| getPrefixPattern ()
| parseVersionValue ()

## Protected Attributes
| $apiPart
Protected Attributes inherited from ezpRestPrefixFilterInterface
| $request
| $versionToken
| $apiProviderToken

## Additional Inherited Members
Static Public Member Functions inherited from ezpRestPrefixFilterInterface
static | getApiVersion ()
static | getApiProviderName ()
static | getApiPrefix ()
Static Protected Attributes inherited from ezpRestPrefixFilterInterface
static | $version = null
static | $apiProvider = null
static | $apiPrefix = null

## Detailed Description

Default implementation of prefix filter interface.

Definition at line 15 of file default_regexp_prefix_filter.php.

## Constructor & Destructor Documentation

## ◆ __construct()

ezpRestDefaultRegexpPrefixFilter::__construct | ( | ezcMvcRequest | $request,
|  |  | $apiPrefix
| ) |  |

Creates a new VersionToken object which describes the version token in API strings.

Parameters

  ezcMvcRequest | $request |
  string | $apiPrefix |

Reimplemented from ezpRestPrefixFilterInterface.

Definition at line 29 of file default_regexp_prefix_filter.php.

References ezpRestPrefixFilterInterface\$apiPrefix, and ezpRestPrefixFilterInterface\$request.

## Member Function Documentation

## ◆ filter()

ezpRestDefaultRegexpPrefixFilter::filter | ( |  | ) |

Filters the request object for API provider name and version token.

API provider name is assumed to be the first URI element.

If version token exists, gets the numerical value of this token, and filters the URI in the request object, removing said token.

This lets us not to deal with any version token data, in our route definitions. This is a benefit, since different systems, might have different preferences for what the version token should look like.

Returns
  void

Reimplemented from ezpRestPrefixFilterInterface.

Definition at line 69 of file default_regexp_prefix_filter.php.

References ezpRestPrefixFilterInterface\$apiProviderToken, $version, getPrefixPattern(), and parseVersionValue().

## ◆ getPrefixPattern()

ezpRestDefaultRegexpPrefixFilter::getPrefixPattern | ( |  | ) |
| protected

Definition at line 36 of file default_regexp_prefix_filter.php.

Referenced by filter().

## ◆ parseVersionValue()

ezpRestDefaultRegexpPrefixFilter::parseVersionValue | ( |  | ) |
| protected

Returns the numerical version of the version token.

Returns
  int version value

Reimplemented from ezpRestPrefixFilterInterface.

Definition at line 46 of file default_regexp_prefix_filter.php.

Referenced by filter().

## Member Data Documentation

## ◆ $apiPart

ezpRestDefaultRegexpPrefixFilter::$apiPart
| protected

Definition at line 21 of file default_regexp_prefix_filter.php.

The documentation for this class was generated from the following file:

- default_regexp_prefix_filter.php

Copyright © 1998 – 2026 7x. All rights reserved. Licensed under the GNU GPLv2+.