public static function getInstance($cacheFolder = NULL) { if (is_null(self::$instance)) { self::$instance = new self($cacheFolder); } return self::$instance; }
public static function GetInstance($exp_time = 3600, $path = 'cache/') { if (!isset(self::$instance)) { //doesn't exists the isntance self::$instance = new self($exp_time, $path); //goes to the constructor } return self::$instance; }
/** * Set the singleton instance to a given object */ static function setSingleton($instance) { self::$instance = $instance; }