PHP Class eZ\Bundle\EzPublishRestBundle\CorsOptions\RestProvider

Uses the REST OPTIONS routes allowedMethods attribute to provide the list of methods allowed for an URI.
Inheritance: implements Nelmio\CorsBundle\Options\ProviderInterface
Show file Open project: ezsystems/ezpublish-kernel

Protected Properties

Property Type Description
$requestMatcher Symfony\Component\Routing\Matcher\RequestMatcherInterface

Public Methods

Method Description
__construct ( Symfony\Component\Routing\Matcher\RequestMatcherInterface $requestMatcher )
getOptions ( Request $request ) : array Returns allowed CORS methods for a REST route.

Protected Methods

Method Description
getAllowedMethods ( $uri )

Method Details

__construct() public method

public __construct ( Symfony\Component\Routing\Matcher\RequestMatcherInterface $requestMatcher )
$requestMatcher Symfony\Component\Routing\Matcher\RequestMatcherInterface

getAllowedMethods() protected method

protected getAllowedMethods ( $uri )

getOptions() public method

Returns allowed CORS methods for a REST route.
public getOptions ( Request $request ) : array
$request Symfony\Component\HttpFoundation\Request
return array

Property Details

$requestMatcher protected property

protected RequestMatcherInterface,Symfony\Component\Routing\Matcher $requestMatcher
return Symfony\Component\Routing\Matcher\RequestMatcherInterface