Exemple #1
0
 public static function __import__()
 {
     $level = array("none" => 0, "error" => 1, "warning" => 2, "info" => 3, "debug" => 4);
     self::$DISP_LEVEL = $level[Rhaco::def("core.Log@disp", "none")];
     self::$FILE_LEVEL = $level[Rhaco::def("core.Log@file", "none")];
     self::$PATH = Rhaco::def("core.Log@path", Rhaco::work("log"));
     self::$MAXLEVEL = null;
     Log::$START = microtime(true);
 }
Exemple #2
0
 public static function __import__()
 {
     $path = str_replace("\\", "/", Rhaco::def("core.Lib@path", Rhaco::work("extlib")));
     self::$PATH = $path . (substr($path, -1) == "/" ? "" : "/");
     Rhaco::add(self::$PATH);
     if (strpos(get_include_path(), self::$PATH) === false) {
         set_include_path(get_include_path() . PATH_SEPARATOR . self::$PATH);
     }
     $server = Rhaco::def("core.Lib@server");
     if (!empty($server)) {
         if (is_array($server)) {
             foreach ($server as $s) {
                 self::add($s);
             }
         } else {
             self::add($server);
         }
     }
 }
Exemple #3
0
 public static function __import__()
 {
     self::$tgz_dir = Rhaco::def("generic.Packager@path", Rhaco::work("tgz"));
 }
Exemple #4
0
/**
 * アプリケーションのワーキング(テンポラリ)ファイルパスを取得する
 *
 * @param string $path
 * @return string
 */
function work_path($path = null)
{
    return Rhaco::work($path);
}
Exemple #5
0
 public static function __import__()
 {
     self::$CACHE_PATH = Rhaco::def("core.File@path", Rhaco::work("cache"));
 }
Exemple #6
0
 public static function __import__()
 {
     self::exec_type(self::SUCCESS | self::FAIL | self::NONE);
     self::$ftmp = Rhaco::def("ext.Test@ftmp", Rhaco::work("tmp"));
     if (self::$ftmp !== null && is_dir(self::ftpath())) {
         foreach (File::dirs(self::ftpath()) as $dir) {
             File::rm($dir);
         }
     }
 }