PHP Класс Demo\Aspect\CachingAspect

Наследование: implements Go\Aop\Aspect
Показать файл Открыть проект

Открытые методы

Метод Описание
aroundCacheable ( Go\Aop\Intercept\MethodInvocation $invocation ) This advice intercepts an execution of cacheable methods

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

aroundCacheable() публичный Метод

Logic is pretty simple: we look for the value in the cache and if it's not present here then invoke original method and store it's result in the cache. Real-life examples will use APC or Memcache to store value in the cache
public aroundCacheable ( Go\Aop\Intercept\MethodInvocation $invocation )
$invocation Go\Aop\Intercept\MethodInvocation Invocation