public function RouteCollection::addResource

Adds a resource for this collection.

Parameters

ResourceInterface $resource A resource instance:

File

drupal/core/vendor/symfony/routing/Symfony/Component/Routing/RouteCollection.php, line 267

Class

RouteCollection
A RouteCollection represents a set of Route instances.

Namespace

Symfony\Component\Routing

Code

public function addResource(ResourceInterface $resource) {
  $this->resources[] = $resource;
}