예제 #1
0
    /**
     * Internal method to check if the given cache supports tags
     *
     * @return false|string
     */
    protected static function _getTagSupportForCache()
    {
        $backend = self::$_cache->getBackend();
        if ($backend instanceof \Zend\Cache\Backend\ExtendedInterface) {
            $cacheOptions = $backend->getCapabilities();
            self::$_cacheTags = $cacheOptions['tags'];
        } else {
            self::$_cacheTags = false;
        }

        return self::$_cacheTags;
    }
예제 #2
0
 /**
  * Internal method to check if the given cache supports tags
  *
  * @return false|string
  */
 protected static function _getTagSupportForCache()
 {
     if (!self::$_cache instanceof CacheAdapter) {
         self::$_cacheTags = false;
         return false;
     }
     $capabilities = self::$_cache->getCapabilities();
     if (!$capabilities->getTagging()) {
         self::$_cacheTags = false;
         return false;
     }
     self::$_cacheTags = true;
     return true;
 }