PHP Класс yii\caching\ExpressionDependency

ExpressionDependency will use eval() to evaluate the PHP expression. The dependency is reported as unchanged if and only if the result of the expression is the same as the one evaluated when storing the data to cache. A PHP expression can be any PHP code that has a value. To learn more about what an expression is, please refer to the php manual. For more details and usage information on Cache, see the guide article on caching.
С версии: 2.0
Автор: Qiang Xue ([email protected])
Наследование: extends yii\caching\Dependency
Показать файл Открыть проект

Открытые свойства

Свойство Тип Описание
$expression the string representation of a PHP expression whose result is used to determine the dependency. A PHP expression can be any PHP code that evaluates to a value. To learn more about what an expression is, please refer to the php manual.
$params custom parameters associated with this dependency. You may get the value of this property in [[expression]] using $this->params.

Защищенные методы

Метод Описание
generateDependencyData ( Cache $cache ) : mixed Generates the data needed to determine if dependency has been changed.

Описание методов

generateDependencyData() защищенный Метод

This method returns the result of the PHP expression.
protected generateDependencyData ( Cache $cache ) : mixed
$cache Cache the cache component that is currently evaluating this dependency
Результат mixed the data needed to determine if dependency has been changed.

Описание свойств

$expression публичное свойство

the string representation of a PHP expression whose result is used to determine the dependency. A PHP expression can be any PHP code that evaluates to a value. To learn more about what an expression is, please refer to the php manual.
public $expression

$params публичное свойство

custom parameters associated with this dependency. You may get the value of this property in [[expression]] using $this->params.
public $params