* * This source file is subject to the MIT license that is bundled * with this source code in the file LICENSE. */ /** * RequestDataCollector. * * @author Fabien Potencier */ class RequestDataCollector extends BaseRequestDataCollector { /** * {@inheritdoc} */ public function collect(Request $request, Response $response, \Exception $exception = null) { parent::collect($request, $response, $exception); $this->data['route'] = $request->attributes->get('_route'); } /** * Gets the route. * * @return string The route */ public function getRoute() { return $this->data['route']; } }