Class Ingo_Storage_sql

Description

Ingo_Storage_sql implements the Ingo_Storage API to save Ingo data via PHP's PEAR database abstraction layer.

Required values for $params:

   'phptype'  - The database type (e.g. 'pgsql', 'mysql', etc.).
   'charset'  - The database's internal charset.

Required by some database implementations:

   'database' - The name of the database.
   'hostspec' - The hostname of the database server.
   'protocol' - The communication protocol ('tcp', 'unix', etc.).
   'username' - The username with which to connect to the database.
   'password' - The password associated with 'username'.
   'options'  - Additional options to pass to the database.
   'tty'      - The TTY on which to connect to the database.
   'port'     - The port on which to connect to the database.

The table structure can be created by the scripts/drivers/sql/ingo.sql script.

$Horde: ingo/lib/Storage/sql.php,v 1.21.2.7 2009/07/24 14:08:17 jan Exp $

See the enclosed file LICENSE for license information (ASL). If you did not receive this file, see http://www.horde.org/licenses/asl.php.

Located in /lib/Storage/sql.php (line 32)

Ingo_Storage
   |
   --Ingo_Storage_sql
Variable Summary
 boolean $_connected
 DB $_db
Method Summary
 Ingo_Storage_sql Ingo_Storage_sql ([array $params = array()])
 mixed removeUserData (string $user)
 Ingo_Storage_rule|Ingo_Storage_filters &_retrieve (integer $field, [boolean $readonly = false])
Variables
boolean $_connected = false (line 56)

Boolean indicating whether or not we're connected to the SQL server.

DB $_db (line 39)

Handle for the current database connection.

DB $_write_db (line 49)

Handle for the current database connection, used for writing.

Defaults to the same handle as $_db if a separate write database is not required.

Inherited Variables

Inherited from Ingo_Storage

Ingo_Storage::$_cache
Ingo_Storage::$_params
Ingo_Storage::$_shutdownCache
Methods
Constructor Ingo_Storage_sql (line 63)

Constructor.

Ingo_Storage_sql Ingo_Storage_sql ([array $params = array()])
  • array $params: Additional parameters for the subclass.
removeUserData (line 407)

Removes the data of the specified user from the storage backend.

  • return: True | PEAR_Error
mixed removeUserData (string $user)
  • string $user: The user name to delete filters for.

Redefinition of:
Ingo_Storage::removeUserData()
Removes the user data from the storage backend.
_retrieve (line 135)

Retrieves the specified data from the storage backend.

  • return: The specified data.
Ingo_Storage_rule|Ingo_Storage_filters &_retrieve (integer $field, [boolean $readonly = false])
  • integer $field: The field name of the desired data. See lib/Storage.php for the available fields.
  • boolean $readonly: Whether to disable any write operations.

Redefinition of:
Ingo_Storage::_retrieve()
Retrieves the specified data from the storage backend.

Inherited Methods

Inherited From Ingo_Storage

 Ingo_Storage::factory()
 Ingo_Storage::getActionInfo()
 Ingo_Storage::getTestInfo()
 Ingo_Storage::removeUserData()
 Ingo_Storage::retrieve()
 Ingo_Storage::store()
 Ingo_Storage::_retrieve()

Documentation generated on Sun, 30 Jan 2011 05:29:31 +0000 by phpDocumentor 1.4.3