public static function Drupal::time in Drupal 9
Same name and namespace in other branches
- 8 core/lib/Drupal.php \Drupal::time()
Returns the time service.
Return value
\Drupal\Component\Datetime\TimeInterface The time service.
1 call to Drupal::time()
- TaxonomyTermArgumentDepthTest::setUp in core/
modules/ taxonomy/ tests/ src/ Kernel/ Views/ TaxonomyTermArgumentDepthTest.php
File
- core/
lib/ Drupal.php, line 732
Class
- Drupal
- Static Service Container wrapper.
Code
public static function time() {
return static::getContainer()
->get('datetime.time');
}