當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Kernel::getCacheDir方法代碼示例

本文整理匯總了PHP中Symfony\Component\HttpKernel\Kernel::getCacheDir方法的典型用法代碼示例。如果您正苦於以下問題:PHP Kernel::getCacheDir方法的具體用法?PHP Kernel::getCacheDir怎麽用?PHP Kernel::getCacheDir使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Symfony\Component\HttpKernel\Kernel的用法示例。


在下文中一共展示了Kernel::getCacheDir方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: theFollowingAcmePhpConfiguration

 /**
  * @Given the following acme_php configuration:
  */
 public function theFollowingAcmePhpConfiguration(PyStringNode $rawConfig)
 {
     $yaml = new Yaml();
     $config = ['acme_php' => array_merge($this->getDefaultConfig(), $yaml->parse($rawConfig->getRaw()))];
     $this->filesystem->dumpFile($this->acmeConfigPath, $yaml->dump($config, 4));
     $this->kernel->shutdown();
     $this->filesystem->remove($this->kernel->getCacheDir());
     $this->kernel->boot();
 }
開發者ID:acmephp,項目名稱:symfony-bundle,代碼行數:12,代碼來源:FeatureContext.php

示例2: getCacheDir

 public function getCacheDir()
 {
     if (in_array($this->environment, ['dev', 'test']) && $this->cacheDir) {
         return $this->cacheDir;
     }
     return parent::getCacheDir();
 }
開發者ID:psk-pz,項目名稱:Backend,代碼行數:7,代碼來源:AppKernel.php

示例3: getCacheDir

 public function getCacheDir()
 {
     if (in_array($this->getEnvironment(), array('dev', 'ci'))) {
         return '/dev/shm/' . $this->getEnvironment() . '/cache/';
     }
     return parent::getCacheDir();
 }
開發者ID:veloxy,項目名稱:sourcebox-kunstmaan,代碼行數:7,代碼來源:AppKernel.php

示例4: getCacheDir

 public function getCacheDir()
 {
     if (in_array($this->getEnvironment(), array('dev', 'test'), true)) {
         return sprintf('/tmp/symfony/music/cache/%s', $this->environment);
     }
     return parent::getCacheDir();
 }
開發者ID:robertdumitrescu,項目名稱:Interview-MusicCoursesApplication,代碼行數:7,代碼來源:AppKernel.php

示例5: getCacheDir

 public function getCacheDir()
 {
     if (array_key_exists('CACHE_DIR', $_ENV)) {
         return $_ENV['CACHE_DIR'] . DIRECTORY_SEPARATOR . $this->environment;
     }
     return parent::getCacheDir();
 }
開發者ID:sgomez,項目名稱:CraueConfigBundle,代碼行數:7,代碼來源:AppKernel.php

示例6: getCacheDir

 /**
  * {@inheritdoc}
  */
 public function getCacheDir()
 {
     if ($this->isVagrantEnvironment()) {
         return '/dev/shm/park-manager/cache/' . $this->getEnvironment();
     }
     return parent::getCacheDir();
 }
開發者ID:sstok,項目名稱:park-manager,代碼行數:10,代碼來源:Kernel.php

示例7: getCacheDir

 /**
  * @see \Symfony\Component\HttpKernel\Kernel::getCacheDir()
  */
 public function getCacheDir()
 {
     if (in_array($this->environment, ['dev', 'test'])) {
         return '/dev/shm/librarian/cache/' . $this->environment;
     }
     return parent::getCacheDir();
 }
開發者ID:EightArmCode,項目名稱:librarian,代碼行數:10,代碼來源:AppKernel.php

示例8: getCacheDir

 public function getCacheDir()
 {
     if ($this->getRootDir() === '/vagrant/app' && in_array($this->environment, ['dev', 'test'])) {
         return '/dev/shm/appname/cache/' . $this->environment;
     }
     return parent::getCacheDir();
 }
開發者ID:msvrtan,項目名稱:cqrs1,代碼行數:7,代碼來源:AppKernel.php

示例9: getCacheDir

 public function getCacheDir()
 {
     if (in_array($this->environment, array('dev', 'test'))) {
         return $this->getRootDir() . '/cache/' . $this->environment;
     }
     return parent::getCacheDir();
 }
開發者ID:houximing,項目名稱:sportfun,代碼行數:7,代碼來源:AppKernel.php

示例10: getCacheDir

 public function getCacheDir()
 {
     if (in_array($this->environment, array('dev', 'test'))) {
         return sys_get_temp_dir() . '/jumph/cache/' . $this->environment;
     }
     return parent::getCacheDir();
 }
開發者ID:fedegiust,項目名稱:Jumph,代碼行數:7,代碼來源:AppKernel.php

示例11: getCacheDir

 public function getCacheDir()
 {
     if (in_array($this->environment, array('dev', 'test'))) {
         return '/home/vagrant/stecnico/cache/' . $this->environment;
     }
     return parent::getCacheDir();
 }
開發者ID:pabarrientos,項目名稱:stecnico,代碼行數:7,代碼來源:AppKernel.php

示例12: getCacheDir

 /**
  * {@inheritdoc}
  */
 public function getCacheDir()
 {
     if ($this->isVagrantEnvironment()) {
         return '/dev/shm/sylius/cache/' . $this->environment;
     }
     return parent::getCacheDir();
 }
開發者ID:TheMadeleine,項目名稱:Sylius,代碼行數:10,代碼來源:Kernel.php

示例13: getCacheDir

 public function getCacheDir()
 {
     if ($this->gcsBucketName) {
         return sprintf('gs://%s/symfony/cache%s', $this->gcsBucketName, $this->getVersionSuffix());
     }
     return parent::getCacheDir();
 }
開發者ID:GoogleCloudPlatform,項目名稱:appengine-symfony-starter-project,代碼行數:7,代碼來源:AppKernel.php

示例14: getCacheDir

 public function getCacheDir()
 {
     if ($this->vagrant) {
         return '/dev/shm/sages/cache/' . $this->environment;
     }
     return parent::getCacheDir();
 }
開發者ID:Rybbow,項目名稱:symfony-blog,代碼行數:7,代碼來源:AppKernel.php

示例15: getCacheDir

 /**
  * {@inheritdoc}
  */
 public function getCacheDir()
 {
     return parent::getCacheDir();
     //        $environment = getenv("PLATFORM_ENVIRONMENT");
     //
     //        if (!$environment) {
     //            return parent::getCacheDir();
     //        }
     //        return $this->rootDir . '/cache/' . $environment . '/' . $this->environment;
 }
開發者ID:networking,項目名稱:platform-sandbox,代碼行數:13,代碼來源:AppKernel.php


注:本文中的Symfony\Component\HttpKernel\Kernel::getCacheDir方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。