This is the parent class for the SQL stores, which contains the logic common to all of the SQL stores.
The table names used are determined by the class variables associations_table_name and nonces_table_name. To change the name of the tables used, pass new table names into the constructor.
To create the tables with the proper schema, see the createTables method.
This class shouldn't be used directly. Use one of its subclasses instead, as those contain the code necessary to use a specific database. If you're an OpenID integrator and you'd like to create an SQL-driven store that wraps an application's database abstraction, be sure to create a subclass of Auth_OpenID_DatabaseConnection that calls the application's database abstraction calls. Then, pass an instance of your new database connection class to your SQLStore subclass constructor.
All methods other than the constructor and createTables should be considered implementation details.
Located in /Auth/OpenID/SQLStore.php (line 57)
Auth_OpenID_OpenIDStore | --Auth_OpenID_SQLStore
Class | Description |
---|---|
Auth_OpenID_MySQLStore | An SQL store that uses MySQL as its backend. |
Auth_OpenID_PostgreSQLStore | An SQL store that uses PostgreSQL as its backend. |
Auth_OpenID_SQLiteStore | An SQL store that uses SQLite as its backend. |
This creates a new SQLStore instance. It requires an established database connection be given to it, and it allows overriding the default table names.
Returns true if $value constitutes a database error; returns false otherwise.
Resets the store by removing all records from the store's tables.
Converts a query result to a boolean. If the result is a database error according to $this->isError(), this returns false; otherwise, this returns true.
This method should be overridden by subclasses. This method is called by the constructor to set values in $this->sql, which is an array keyed on sql name.
Inherited From Auth_OpenID_OpenIDStore
Auth_OpenID_OpenIDStore::cleanup()
Auth_OpenID_OpenIDStore::cleanupAssociations()
Auth_OpenID_OpenIDStore::cleanupNonces()
Auth_OpenID_OpenIDStore::getAssociation()
Auth_OpenID_OpenIDStore::removeAssociation()
Auth_OpenID_OpenIDStore::reset()
Auth_OpenID_OpenIDStore::storeAssociation()
Auth_OpenID_OpenIDStore::supportsCleanup()
Auth_OpenID_OpenIDStore::useNonce()
Documentation generated on Thu, 29 Jul 2010 13:59:29 -0700 by phpDocumentor 1.4.3