public function TwigExtension::setDateFormatter in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/Template/TwigExtension.php \Drupal\Core\Template\TwigExtension::setDateFormatter()
Sets the date formatter.
Parameters
\Drupal\Core\Datetime\DateFormatter $date_formatter: The date formatter.
Return value
$this
File
- core/
lib/ Drupal/ Core/ Template/ TwigExtension.php, line 121 - Contains \Drupal\Core\Template\TwigExtension.
Class
- TwigExtension
- A class providing Drupal Twig extensions.
Namespace
Drupal\Core\TemplateCode
public function setDateFormatter(DateFormatter $date_formatter) {
$this->dateFormatter = $date_formatter;
return $this;
}