OSDN Git Service

Fix bug, getOption() values are not reflected after changing them by using admin...
[nucleus-jp/nucleus-jp-ancient.git] / utf8 / nucleus / libs / MANAGER.php
index bb269eb..055e6a6 100755 (executable)
@@ -1,7 +1,7 @@
 <?php
 /*
  * Nucleus: PHP/MySQL Weblog CMS (http://nucleuscms.org/)
- * Copyright (C) 2002-2006 The Nucleus Group
+ * Copyright (C) 2002-2007 The Nucleus Group
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
@@ -19,9 +19,9 @@
  * active at all times. The object can be requested using MANAGER::instance()
  *
  * @license http://nucleuscms.org/license.txt GNU General Public License
- * @copyright Copyright (C) 2002-2006 The Nucleus Group
- * @version $Id: MANAGER.php,v 1.5 2006-07-17 20:03:44 kimitake Exp $
 * $NucleusJP: MANAGER.php,v 1.4 2005/08/13 07:33:02 kimitake Exp $
+ * @copyright Copyright (C) 2002-2007 The Nucleus Group
+ * @version $Id: MANAGER.php,v 1.8 2007-04-06 19:36:29 kmorimatsu Exp $
* $NucleusJP: MANAGER.php,v 1.7 2007/02/04 06:28:46 kimitake Exp $
  */
 class MANAGER {
 
@@ -275,6 +275,24 @@ class MANAGER {
        }
 
        /**
+         * checks if the given plugin IS loaded or not
+         */
+       function &pluginLoaded($name) {
+               $plugin =& $this->plugins[$name];
+               return $plugin;
+       }
+       function &pidLoaded($pid) {
+               $plugin=false;
+               reset($this->plugins);
+               while (list($name) = each($this->plugins)) {
+                       if ($pid!=$this->plugins[$name]->getId()) continue;
+                       $plugin= & $this->plugins[$name];
+                       break;
+               }
+               return $plugin;
+       }
+
+       /**
          * checks if the given plugin IS installed or not
          */
        function pluginInstalled($name) {