Class DBAdapter
DBAdapter (Database Adapter)
An adapter class to connect various database systems to RedBean
Database Adapter Class. The task of the database adapter class is to
communicate with the database driver. You can use all sorts of database
drivers with RedBeanPHP. The default database drivers that ships with
the RedBeanPHP library is the RPDO driver ( which uses the PHP Data Objects
Architecture aka PDO ).
-
RedBeanPHP\Observable
-
RedBeanPHP\Adapter\DBAdapter
implements
RedBeanPHP\Adapter
Namespace: RedBeanPHP\
Adapter
Copyright:
(c) copyright G.J.G.T. (Gabor) de Mooij and the RedBeanPHP community.
This source file is subject to the BSD/GPLv2 License that is bundled
with this source code in the file license.txt.
License:
BSD/GPLv2
Author:
Gabor de Mooij and the RedBeanPHP Community.
File:
RedBeanPHP/Adapter/DBAdapter.php
Located at Adapter/DBAdapter.php
Methods summary
public
|
#
__construct( RedBeanPHP\Driver $database )
Constructor.
Creates an instance of the RedBean Adapter Class.
This class provides an interface for RedBean to work
with ADO compatible DB instances.
Parameters
- $database
- ADO Compatible DB Instance
|
public
string
|
#
getSQL( )
Returns
string
See
Adapter::getSQL
Implementation of
|
public
|
#
exec( string $sql, array $bindings = array(), boolean $noevent = FALSE )
Parameters
- $sql
- string containing SQL code for database
- $bindings
- array of values to bind to parameters in query string
- $noevent
- no event firing
See
Adapter::exec
Implementation of
|
public
array
|
#
get( string $sql, array $bindings = array() )
Parameters
- $sql
- string containing SQL code for database
- $bindings
- array of values to bind to parameters in query string
Returns
array
See
Adapter::get
Implementation of
|
public
array
|
#
getRow( string $sql, array $bindings = array() )
Parameters
- $sql
- string containing SQL code for database
- $bindings
- array of values to bind to parameters in query string
Returns
array
See
Adapter::getRow
Implementation of
|
public
array
|
#
getCol( string $sql, array $bindings = array() )
Parameters
- $sql
- string containing SQL code for database
- $bindings
- array of values to bind to parameters in query string
Returns
array
See
Adapter::getCol
Implementation of
|
public
array
|
#
getAssoc( string $sql, array $bindings = array() )
Parameters
- $sql
- string containing SQL code for database
- $bindings
- array of values to bind to parameters in query string
Returns
array
See
Adapter::getAssoc
Implementation of
|
public
array
|
#
getAssocRow( string $sql, array $bindings = array() )
Parameters
- $sql
- Sstring containing SQL code for databaseQL
- $bindings
- values to bind
Returns
array
See
Adapter::getAssocRow
Implementation of
|
public
string
|
#
getCell( string $sql, array $bindings = array(), $noSignal = NULL )
Parameters
- $sql
- string containing SQL code for database
- $bindings
- array of values to bind to parameters in query string
- $noSignal
Returns
string
See
Adapter::getCell
Implementation of
|
public
Cursor
|
#
getCursor( string $sql, array $bindings = array() )
Parameters
- $sql
- string containing SQL code for database
- $bindings
- array of values to bind to parameters in query string
Returns
Cursor
See
Adapter::getCursor
Implementation of
|
public
integer
|
#
getInsertID( )
Returns
integer
See
Adapter::getInsertID
Implementation of
|
public
integer
|
#
getAffectedRows( )
Returns
integer
See
Adapter::getAffectedRows
Implementation of
|
public
mixed
|
#
getDatabase( )
Returns
mixed
See
Adapter::getDatabase
Implementation of
|
public
|
|
public
|
#
commit( )
See
Adapter::commit
Implementation of
|
public
|
#
rollback( )
See
Adapter::rollback
Implementation of
|
public
|
#
close( )
See
Adapter::close.
Implementation of
|