コード例 #1
0
ファイル: FSTools.php プロジェクト: Jaaviieer/PrograWeb
 /**
  * Sets our global singleton to something else; useful for overloading
  * functions.
  */
 public static function setSingleton($singleton)
 {
     FSTools::$singleton = $singleton;
 }
コード例 #2
0
ファイル: File.php プロジェクト: ajnok/yii2book
 /**
  * Filename of file you wish to instantiate.
  * @note This file need not exist
  */
 public function __construct($name, $fs = false)
 {
     $this->name = $name;
     $this->fs = $fs ? $fs : FSTools::singleton();
 }
コード例 #3
0
 function __destruct()
 {
     FSTools::singleton()->rmdirr($this->dir);
 }