W3cubDocs

/Symfony 4.1

PhpGeneratorDumper

class PhpGeneratorDumper extends GeneratorDumper

PhpGeneratorDumper creates a PHP class able to generate URLs for a given set of routes.

Methods

__construct(RouteCollection $routes) from GeneratorDumper
RouteCollection getRoutes()

Gets the routes to dump.

from GeneratorDumper
string dump(array $options = array())

Dumps a set of routes to a PHP class.

Details

__construct(RouteCollection $routes)

Parameters

RouteCollection $routes

RouteCollection getRoutes()

Gets the routes to dump.

Return Value

RouteCollection A RouteCollection instance

string dump(array $options = array())

Dumps a set of routes to a PHP class.

Available options:

  • class: The class name
  • base_class: The base class name

Parameters

array $options An array of options

Return Value

string Executable code

© 2004–2017 Fabien Potencier
Licensed under the MIT License.
https://api.symfony.com/4.1/Symfony/Component/Routing/Generator/Dumper/PhpGeneratorDumper.html