remove statics for the inflector
authorChuck Hagenbuch <chuck@horde.org>
Sat, 10 Jan 2009 17:17:22 +0000 (12:17 -0500)
committerChuck Hagenbuch <chuck@horde.org>
Sat, 10 Jan 2009 17:17:22 +0000 (12:17 -0500)
framework/Rdo/lib/Horde/Rdo.php
framework/Rdo/lib/Horde/Rdo/Mapper.php

index ddcf41e..ec06938 100644 (file)
@@ -40,34 +40,4 @@ class Horde_Rdo
      */
     const MANY_TO_MANY = 4;
 
-    /**
-     * Global inflector object.
-     *
-     * @var Horde_Support_Inflector
-     */
-    protected static $_inflector;
-
-    /**
-     * Get the global inflector object.
-     *
-     * @return Horde_Support_Inflector
-     */
-    public static function getInflector()
-    {
-        if (!self::$_inflector) {
-            self::$_inflector = new Horde_Support_Inflector;
-        }
-        return self::$_inflector;
-    }
-
-    /**
-     * Set a custom global inflector.
-     *
-     * @param Horde_Support_Inflector $inflector
-     */
-    public static function setInflector($inflector)
-    {
-        self::$_inflector = $inflector;
-    }
-
 }
index e386c2e..dd9963a 100644 (file)
@@ -123,7 +123,8 @@ abstract class Horde_Rdo_Mapper implements Countable
             return $this->adapter;
 
         case 'inflector':
-            return Horde_Rdo::getInflector();
+            $this->inflector = new Horde_Support_Inflector();
+            return $this->inflector;
 
         case 'table':
             $this->table = !empty($this->_table) ? $this->_table : $this->mapperToTable();