/** * Generate a URL for the provided page and params that will match the * Silex routes set up by this class. * * @param ComponentAbstract $component * @param string $page * @param array $params * @return string */ public function url(ComponentAbstract $component, $page, array $params = array()) { $url = '/admin/' . $component->getName() . '/' . $this->application['inflector']->hyphenize($page) . $this->assembleQueryString($params, '?'); if (Pimple::hasResource('url-filter')) { /* @var $filter callable */ $filter = Pimple::getResource('url-filter'); $url = $filter($url); } return $url; }