W3cubDocs

/Symfony 2.7

Symfony\Component\Routing\Matcher\Dumper\ApacheMatcherDumper

class ApacheMatcherDumper extends MatcherDumper

Dumps a set of Apache mod_rewrite rules.

Methods

__construct(RouteCollection $routes)

Constructor.

from MatcherDumper
RouteCollection getRoutes()

Gets the routes to dump.

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

Dumps a set of Apache mod_rewrite rules.

Details

public __construct(RouteCollection $routes)

Constructor.

Parameters

RouteCollection $routes The RouteCollection to dump

public RouteCollection getRoutes()

Gets the routes to dump.

Return Value

RouteCollection A RouteCollection instance

public string dump(array $options = array())

Dumps a set of Apache mod_rewrite rules.

Available options:

  • script_name: The script name (app.php by default)
  • base_uri: The base URI ("" by default)

Parameters

array $options An array of options

Return Value

string A string to be used as Apache rewrite rules

Exceptions

LogicException When the route regex is invalid

© 2004–2016 Fabien Potencier
Licensed under the MIT License.
http://api.symfony.com/2.7/Symfony/Component/Routing/Matcher/Dumper/ApacheMatcherDumper.html