Add some utility functions to horde/Prefs
authorMichael M Slusarz <slusarz@curecanti.org>
Tue, 25 Jan 2011 05:44:23 +0000 (22:44 -0700)
committerMichael M Slusarz <slusarz@curecanti.org>
Tue, 25 Jan 2011 05:44:23 +0000 (22:44 -0700)
framework/Prefs/lib/Horde/Prefs.php
framework/Prefs/lib/Horde/Prefs/Storage/Base.php

index f7f7af8..af96cfd 100644 (file)
@@ -129,6 +129,16 @@ class Horde_Prefs implements ArrayAccess
     }
 
     /**
+     * Return the storage driver.
+     *
+     * @return Horde_Prefs_Storage_Base  The storage driver.
+     */
+    public function getStorage()
+    {
+        return $this->_storage;
+    }
+
+    /**
      * Removes a preference entry from the $prefs hash.
      *
      * @param string $pref  The name of the preference to remove.
index ec8176a..efafe29 100644 (file)
@@ -35,6 +35,16 @@ abstract class Horde_Prefs_Storage_Base
     }
 
     /**
+     * Get the list of driver parameters.
+     *
+     * @return array  Driver parameters.
+     */
+    public function getParams()
+    {
+        return $this->_params;
+    }
+
+    /**
      * Retrieves the requested preferences scope from the storage backend.
      *
      * @param Horde_Prefs_Scope $scope_ob  The scope object.