class FormattedDateDiff

Contains a formatted time difference.

Hierarchy

File

core/lib/Drupal/Core/Datetime/FormattedDateDiff.php, line 12

Namespace

Drupal\Core\Datetime

Members

Name Modifiers Type Description
FormattedDateDiff::$maxAge protected property The maximum time in seconds that this string may be cached.
FormattedDateDiff::$string protected property The actual formatted time difference.
FormattedDateDiff::getMaxAge public function
FormattedDateDiff::getString public function
FormattedDateDiff::toRenderable public function Returns a render array representation of the object. Overrides RenderableInterface::toRenderable
FormattedDateDiff::__construct public function Creates a new FormattedDateDiff instance.
UnchangingCacheableDependencyTrait::getCacheContexts public function The cache contexts associated with this object. Overrides CacheableDependencyInterface::getCacheContexts
UnchangingCacheableDependencyTrait::getCacheMaxAge public function The maximum age for which this object may be cached. Overrides CacheableDependencyInterface::getCacheMaxAge
UnchangingCacheableDependencyTrait::getCacheTags public function The cache tags associated with this object. Overrides CacheableDependencyInterface::getCacheTags

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Datetime!FormattedDateDiff.php/class/FormattedDateDiff/8.1.x