Minahito
minah****@users*****
2006年 2月 3日 (金) 17:33:01 JST
Index: xoops2jp/html/modules/base/admin/class/DeactiveModuleHandler.class.php diff -u xoops2jp/html/modules/base/admin/class/DeactiveModuleHandler.class.php:1.1.2.2 xoops2jp/html/modules/base/admin/class/DeactiveModuleHandler.class.php:removed --- xoops2jp/html/modules/base/admin/class/DeactiveModuleHandler.class.php:1.1.2.2 Mon Dec 26 21:23:12 2005 +++ xoops2jp/html/modules/base/admin/class/DeactiveModuleHandler.class.php Fri Feb 3 17:33:01 2006 @@ -1,81 +0,0 @@ -<?php -/** - * @version - */ - -/** - */ -class Legacy_DeactiveModuleHandler extends XoopsObjectHandler -{ - var $_mXoopsModules = array(); - - var $mModHandler = null; - - /** - * readonly property - */ - var $_mExclusions = array(".", "..", "CVS"); - - function Legacy_DeactiveModuleHandler(&$db) - { - } - - /** - * Once, load module objects to a member property from XOOPS_MODULE_PATH. - */ - function _setupObjects() - { - if (count($this->_mXoopsModules) == 0) { - if ($handler = opendir(XOOPS_MODULE_PATH)) { - while (($dir = readdir($handler)) !== false) { - if (!in_array($dir, $this->_mExclusions) && is_dir(XOOPS_MODULE_PATH . "/" . $dir)) { - $module =& $this->get($dir); - if ($module !== false ) { - $this->_mXoopsModules[] =& $module; - unset($module); - } - } - } - } - } - } - - /** - * Return module object by $dirname that is specified module directory. - * If specified module has been installed or doesn't keep xoops_version, not return it. - * @param $dirname string - * @param XoopsModule or false - */ - function &get($dirname) - { - $ret=false; - - if (!file_exists(XOOPS_MODULE_PATH . "/" . $dirname . "/xoops_version.php")) { - return $ret; - } - - $moduleHandler =& xoops_gethandler('module'); - - $check =& $moduleHandler->getByDirname($dirname); - if (is_object($check)) { - return $ret; - } - - $module =& $moduleHandler->create(); - $module->loadInfoAsVar($dirname); - - return $module; - } - - function &getObjects($criteria=null) - { - $ret =& $this->_setupObjects(); - - // - // ????????? - // - return $this->_mXoopsModules; - } -} - -?>