You are here

public function DatexBlock::getCacheMaxAge in Datex 8

The maximum age for which this object may be cached.

Return value

int The maximum time in seconds that this object may be cached.

Overrides ContextAwarePluginBase::getCacheMaxAge

File

src/Plugin/Block/DatexBlock.php, line 100

Class

DatexBlock
Provides a block to show a localized current/relative date.

Namespace

Drupal\datex\Plugin\Block

Code

public function getCacheMaxAge() {
  $config = $this
    ->getConfiguration();
  return isset($config['cache']) ? $config['cache'] : 3600;
}