* クラス生成 */ function load($class_name) { $lower = strtolower($class_name); $camel = ucfirst($class_name); if (in_array($lower, $this->classes) == false) { $this->classes[] = $lower; require_once $this->config['libDir'] . $lower . '.php'; $this->{$lower} = new $camel(); } } } /** * 同一オブジェクトを生成する為のメソッド */ function &get_instance() { return Gen::get_instance(); } /** * 同一オブジェクトを生成 * 同一インスタンスを取得する為にいは以下のようにメソッドを使用する * $gen =& get_instance(); */ $gen = new Gen($config); $gen->pdo = db_connect($config); $gen->load('http'); $gen->load('view'); require_once $config['libDir'] . 'helper.php'; //heler