Cachearium\Backend\CacheRAM::singleton PHP 메소드

singleton() 공개 정적인 메소드

Cache constructor (this is a singleton).
public static singleton ( ) : CacheRAM
리턴 CacheRAM The cache singleton.
    public static function singleton()
    {
        static $instances;
        if (!isset($instances)) {
            $instances = new CacheRAM();
        }
        return $instances;
    }

Usage Example

예제 #1
0
 public function teststartCallbackRAM()
 {
     $cache = CacheRAM::singleton();
     if ($cache->isEnabled()) {
         $this->_startcallback($cache);
     }
 }
All Usage Examples Of Cachearium\Backend\CacheRAM::singleton