/**
* {@inheritdoc}
*/
public function generate(RouteInterface $resource)
{
$this->defaults['id'] = $resource->getIdentifier()->getId();
$this->defaults['_locale'] = $resource->getLocale();
return new SymfonyRoute($resource->getPath(), $this->defaults, $this->requirements, $this->options);
}