File tree Expand file tree Collapse file tree 7 files changed +15
-15
lines changed
Expand file tree Collapse file tree 7 files changed +15
-15
lines changed Original file line number Diff line number Diff line change @@ -40,12 +40,12 @@ public function getFunctions()
4040 );
4141 }
4242
43- public function getPath ($ name , array $ parameters = array ())
43+ public function getPath ($ name , $ parameters = array ())
4444 {
4545 return $ this ->generator ->generate ($ name , $ parameters , false );
4646 }
4747
48- public function getUrl ($ name , array $ parameters = array ())
48+ public function getUrl ($ name , $ parameters = array ())
4949 {
5050 return $ this ->generator ->generate ($ name , $ parameters , true );
5151 }
Original file line number Diff line number Diff line change @@ -34,12 +34,12 @@ class Controller extends ContainerAware
3434 * Generates a URL from the given parameters.
3535 *
3636 * @param string $name The name of the route
37- * @param array $parameters An array of parameters
37+ * @param mixed $parameters An array of parameters
3838 * @param Boolean $absolute Whether to generate an absolute URL
3939 *
4040 * @return string The generated URL
4141 */
42- public function generateUrl ($ route , array $ parameters = array (), $ absolute = false )
42+ public function generateUrl ($ route , $ parameters = array (), $ absolute = false )
4343 {
4444 return $ this ->container ->get ('router ' )->generate ($ route , $ parameters , $ absolute );
4545 }
Original file line number Diff line number Diff line change @@ -37,12 +37,12 @@ public function __construct(UrlGeneratorInterface $router)
3737 * Generates a URL from the given parameters.
3838 *
3939 * @param string $name The name of the route
40- * @param array $parameters An array of parameters
40+ * @param mixed $parameters An array of parameters
4141 * @param Boolean $absolute Whether to generate an absolute URL
4242 *
4343 * @return string The generated URL
4444 */
45- public function generate ($ name , array $ parameters = array (), $ absolute = false )
45+ public function generate ($ name , $ parameters = array (), $ absolute = false )
4646 {
4747 return $ this ->generator ->generate ($ name , $ parameters , $ absolute );
4848 }
Original file line number Diff line number Diff line change @@ -78,7 +78,7 @@ private function get{$escapedName}RouteInfo()
7878
7979 return <<<EOF
8080
81- public function generate( \$name, array \$parameters = array(), \$absolute = false)
81+ public function generate( \$name, \$parameters = array(), \$absolute = false)
8282 {
8383 if (!isset(self:: \$declaredRouteNames[ \$name])) {
8484 throw new RouteNotFoundException(sprintf('Route "%s" does not exist.', \$name));
Original file line number Diff line number Diff line change @@ -33,8 +33,8 @@ class UrlGenerator implements UrlGeneratorInterface
3333 '%2F ' => '/ ' ,
3434 );
3535
36- private $ routes ;
37- private $ cache ;
36+ protected $ routes ;
37+ protected $ cache ;
3838
3939 /**
4040 * Constructor.
@@ -77,7 +77,7 @@ public function getContext()
7777 * Generates a URL from the given parameters.
7878 *
7979 * @param string $name The name of the route
80- * @param array $parameters An array of parameters
80+ * @param mixed $parameters An array of parameters
8181 * @param Boolean $absolute Whether to generate an absolute URL
8282 *
8383 * @return string The generated URL
@@ -86,7 +86,7 @@ public function getContext()
8686 *
8787 * @api
8888 */
89- public function generate ($ name , array $ parameters = array (), $ absolute = false )
89+ public function generate ($ name , $ parameters = array (), $ absolute = false )
9090 {
9191 if (null === $ route = $ this ->routes ->get ($ name )) {
9292 throw new RouteNotFoundException (sprintf ('Route "%s" does not exist. ' , $ name ));
Original file line number Diff line number Diff line change @@ -26,12 +26,12 @@ interface UrlGeneratorInterface extends RequestContextAwareInterface
2626 * Generates a URL from the given parameters.
2727 *
2828 * @param string $name The name of the route
29- * @param array $parameters An array of parameters
29+ * @param mixed $parameters An array of parameters
3030 * @param Boolean $absolute Whether to generate an absolute URL
3131 *
3232 * @return string The generated URL
3333 *
3434 * @api
3535 */
36- function generate ($ name , array $ parameters = array (), $ absolute = false );
36+ function generate ($ name , $ parameters = array (), $ absolute = false );
3737}
Original file line number Diff line number Diff line change @@ -171,12 +171,12 @@ public function getContext()
171171 * Generates a URL from the given parameters.
172172 *
173173 * @param string $name The name of the route
174- * @param array $parameters An array of parameters
174+ * @param mixed $parameters An array of parameters
175175 * @param Boolean $absolute Whether to generate an absolute URL
176176 *
177177 * @return string The generated URL
178178 */
179- public function generate ($ name , array $ parameters = array (), $ absolute = false )
179+ public function generate ($ name , $ parameters = array (), $ absolute = false )
180180 {
181181 return $ this ->getGenerator ()->generate ($ name , $ parameters , $ absolute );
182182 }
You can’t perform that action at this time.
0 commit comments