当前位置: 首页>>代码示例>>PHP>>正文


PHP CacheProvider::deleteAll方法代码示例

本文整理汇总了PHP中Doctrine\Common\Cache\CacheProvider::deleteAll方法的典型用法代码示例。如果您正苦于以下问题:PHP CacheProvider::deleteAll方法的具体用法?PHP CacheProvider::deleteAll怎么用?PHP CacheProvider::deleteAll使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Doctrine\Common\Cache\CacheProvider的用法示例。


在下文中一共展示了CacheProvider::deleteAll方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: clean

 /**
  * Removes items from the cache by conditions.
  *
  * @param array $conditions
  * @return void
  */
 public function clean(array $conditions)
 {
     if (!isset($conditions[Nette\Caching\Cache::ALL])) {
         throw new NotImplementedException();
     }
     $this->provider->deleteAll();
 }
开发者ID:Richmond77,项目名称:learning-nette,代码行数:13,代码来源:ReversedStorageDecorator.php

示例2: clearCache

 /**
  *
  */
 private function clearCache()
 {
     $container = $this->getConfigurationPool()->getContainer();
     $container->get('harentius_blog.router.category_slug_provider')->clearAll();
     $this->cache->deleteAll();
     $container->get('harentius_blog.controller.feed_cache')->deleteAll();
 }
开发者ID:harentius,项目名称:blog-bundle,代码行数:10,代码来源:ArticleAdmin.php

示例3: updateTimestamp

 /**
  * Renews the timestamp of the last update of database translations for the given locale
  *
  * @param string|null $locale
  */
 public function updateTimestamp($locale = null)
 {
     if ($locale) {
         $this->localCache[$locale] = (new \DateTime('now', new \DateTimeZone('UTC')))->getTimestamp();
         $this->cacheImpl->save($locale, $this->localCache[$locale]);
     } else {
         $this->localCache = [];
         $this->cacheImpl->deleteAll();
     }
 }
开发者ID:Maksold,项目名称:platform,代码行数:15,代码来源:DynamicTranslationMetadataCache.php

示例4: deleteAll

 public function deleteAll($auto_flush = true)
 {
     $this->engine->deleteAll();
     if ($this->auto_flush && $auto_flush) {
         return $this->engine->flushAll();
     }
 }
开发者ID:symforce,项目名称:symforce-core,代码行数:7,代码来源:Cache.php

示例5: clearCacheDriver

 protected function clearCacheDriver(CacheProvider $cacheDriver = null, $description = "")
 {
     if ($cacheDriver !== null) {
         $this->output .= 'Doctrine ' . $description . ' cache: ' . $cacheDriver->getNamespace() . ' — ';
         $this->output .= $cacheDriver->deleteAll() ? '<info>OK</info>' : '<info>FAIL</info>';
         $this->output .= PHP_EOL;
     }
 }
开发者ID:QuangDang212,项目名称:roadiz,代码行数:8,代码来源:DoctrineCacheClearer.php

示例6: flush

 /**
  * Flush all cache entries
  *
  * @access public
  * @return void
  */
 public function flush()
 {
     if ($this->flush_namespace) {
         $this->adapted_provider->deleteAll();
     } else {
         $this->adapted_provider->flushAll();
     }
 }
开发者ID:onemightyroar,项目名称:php-activerecord-components,代码行数:14,代码来源:DoctrineCacheAdapter.php

示例7: clearCache

 /**
  * Clears the ownership metadata cache
  *
  * If the class name is not specified this method clears all cached data
  *
  * @param string|null $className
  */
 public function clearCache($className = null)
 {
     if ($this->cache) {
         if ($className !== null) {
             $this->cache->delete($className);
         } else {
             $this->cache->deleteAll();
         }
     }
 }
开发者ID:xamin123,项目名称:platform,代码行数:17,代码来源:OwnershipMetadataProvider.php

示例8: build

 /**
  * Write to cache entity classes and appropriate events
  */
 public function build()
 {
     $this->assertProvider();
     // get all triggers data
     $triggerRepository = $this->registry->getManagerForClass('OroWorkflowBundle:ProcessTrigger')->getRepository('OroWorkflowBundle:ProcessTrigger');
     /** @var ProcessTrigger[] $triggers */
     $triggers = $triggerRepository->findAllWithDefinitions();
     $data = array();
     foreach ($triggers as $trigger) {
         $entityClass = $trigger->getDefinition()->getRelatedEntity();
         $event = $trigger->getEvent();
         if (!isset($data[$entityClass])) {
             $data[$entityClass] = array();
         }
         if (!in_array($event, $data[$entityClass])) {
             $data[$entityClass][] = $event;
         }
     }
     // write trigger data to cache
     $this->provider->deleteAll();
     $this->provider->save(self::DATA, $data);
     $this->provider->save(self::BUILT, true);
 }
开发者ID:ramunasd,项目名称:platform,代码行数:26,代码来源:ProcessTriggerCache.php

示例9: clearCache

 /**
  * Clears the cache by security type
  *
  * If the $securityType is not specified, clear all cached data
  *
  * @param string|null $securityType The security type.
  */
 public function clearCache($securityType = null)
 {
     if ($this->cache) {
         if ($securityType !== null) {
             $this->cache->delete($securityType);
         } else {
             $this->cache->deleteAll();
         }
     }
     if ($securityType !== null) {
         unset($this->localCache[$securityType]);
     } else {
         $this->localCache = array();
     }
 }
开发者ID:xamin123,项目名称:platform,代码行数:22,代码来源:EntitySecurityMetadataProvider.php

示例10: clearCacheProvider

 /**
  * Delete all in cache provider
  */
 public function clearCacheProvider()
 {
     if ($this->cacheProvider) {
         $this->cacheProvider->deleteAll();
     }
 }
开发者ID:modpreneur,项目名称:trinity-settings,代码行数:9,代码来源:SettingsManager.php

示例11: clear

 /**
  * Clear the owner tree cache
  */
 public function clear()
 {
     $this->cache->deleteAll();
 }
开发者ID:xamin123,项目名称:platform,代码行数:7,代码来源:OwnerTreeProvider.php

示例12: removeAll

 /**
  * Remove all cache
  *
  * @return void
  */
 public function removeAll()
 {
     $this->provider->deleteAll();
 }
开发者ID:itkg,项目名称:core,代码行数:9,代码来源:Doctrine.php

示例13: deleteAllConfigurable

 /**
  * Deletes cached "configurable" flags for all configs.
  *
  * @return bool TRUE if the cache entries were successfully deleted; otherwise, FALSE.
  */
 public function deleteAllConfigurable()
 {
     $this->localModelCache = [];
     return $this->modelCache->deleteAll();
 }
开发者ID:northdakota,项目名称:platform,代码行数:10,代码来源:ConfigCache.php

示例14: deleteAll

 public function deleteAll()
 {
     return $this->driver->deleteAll();
 }
开发者ID:anna-framework,项目名称:anna,代码行数:4,代码来源:Cache.php

示例15: removeAllConfigurable

 /**
  * @return bool
  */
 public function removeAllConfigurable()
 {
     return $this->modelCache->deleteAll();
 }
开发者ID:xamin123,项目名称:platform,代码行数:7,代码来源:ConfigCache.php


注:本文中的Doctrine\Common\Cache\CacheProvider::deleteAll方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。