You are here

public function ChainRouteCollection::setMethods in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony-cmf/routing/ChainRouteCollection.php \Symfony\Cmf\Component\Routing\ChainRouteCollection::setMethods()

Sets the HTTP methods (e.g. 'POST') all child routes are restricted to.

Parameters

string|array $methods The method or an array of methods:

Overrides RouteCollection::setMethods

File

vendor/symfony-cmf/routing/ChainRouteCollection.php, line 231

Class

ChainRouteCollection

Namespace

Symfony\Cmf\Component\Routing

Code

public function setMethods($methods) {
  $this
    ->createInternalCollection();
  foreach ($this->routeCollections as $routeCollection) {
    $routeCollection
      ->setMethods($methods);
  }
}