Public Member Functions | Static Public Member Functions | Public Attributes | Protected Attributes | Private Attributes

DB Class Reference
[Connectors and dialects for various databases]

DB-connector's implementation basis. More...

Inheritance diagram for DB:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 connect ()
 disconnect ()
 getTableInfo ($table)
 queryRaw ($queryString)
 queryRow (Query $query)
 querySet (Query $query)
 queryColumn (Query $query)
 queryCount (Query $query)
 setDbEncoding ()
 __destruct ()
 getLink ()
 isConnected ()
 hasSequences ()
 hasQueue ()
 isPersistent ()
 setPersistent ($really=false)
 setUsername ($name)
 setPassword ($password)
 setHostname ($host)
 setBasename ($base)
 setEncoding ($encoding)

 begin ($level=null, $mode=null)
 transaction handling
 commit ()
 rollback ()
 inTransaction ()

 queueStart ()
 queue handling
 queueStop ()
 queueDrop ()
 queueFlush ()
 isQueueActive ()

 query (Query $query)
 base queries
 queryNull (Query $query)

Static Public Member Functions

static getDialect ()
static spawn ($connector, $user, $pass, $host, $base=null, $persistent=false, $encoding=null)
 Shortcut.

Public Attributes

const FULL_TEXT_AND = 1
const FULL_TEXT_OR = 2

Protected Attributes

 $link = null
 $persistent = false
 $username = null
 $password = null
 $hostname = null
 $port = null
 $basename = null
 $encoding = null

Private Attributes

 $transaction = false
 flag to indicate whether we're in transaction
 $queue = array()
 $toQueue = false

Detailed Description

DB-connector's implementation basis.

Definition at line 17 of file DB.class.php.


Constructor & Destructor Documentation

DB::__destruct (  ) 

Definition at line 57 of file DB.class.php.

References disconnect(), isConnected(), and rollback().

Here is the call graph for this function:


Member Function Documentation

DB::begin ( level = null,
mode = null 
)

transaction handling

Deprecated:
by Transaction class
Returns:
DB

Definition at line 109 of file DB.class.php.

References queryRaw().

Here is the call graph for this function:

DB::commit (  ) 
Returns:
DB

Definition at line 135 of file DB.class.php.

References queryRaw().

Here is the call graph for this function:

DB::connect (  )  [abstract]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

DB::disconnect (  )  [abstract]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

Referenced by __destruct().

static DB::getDialect (  )  [static]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

Definition at line 68 of file DB.class.php.

Referenced by queryNull(), and Queue::run().

DB::getLink (  ) 

Definition at line 96 of file DB.class.php.

DB::getTableInfo ( table  )  [abstract]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

DB::hasQueue (  ) 

Reimplemented in MySQL, MySQLim, and SQLite.

Definition at line 259 of file DB.class.php.

Referenced by queueStart().

DB::hasSequences (  ) 

Reimplemented in PgSQL.

Definition at line 254 of file DB.class.php.

DB::inTransaction (  ) 

Definition at line 162 of file DB.class.php.

DB::isConnected (  ) 

Reimplemented in PgSQL, and SQLite.

Definition at line 249 of file DB.class.php.

Referenced by __destruct(), MySQLim::disconnect(), and MySQL::disconnect().

DB::isPersistent (  ) 

Definition at line 264 of file DB.class.php.

DB::isQueueActive (  ) 

Definition at line 219 of file DB.class.php.

DB::query ( Query query  ) 

base queries

Reimplemented in Sequenceless.

Definition at line 229 of file DB.class.php.

References queryRaw(), and DialectString::toDialectString().

Referenced by PgSQL::queryColumn(), queryNull(), PgSQL::queryRow(), and PgSQL::querySet().

Here is the call graph for this function:

DB::queryColumn ( Query query  )  [abstract]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

DB::queryCount ( Query query  )  [abstract]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

DB::queryNull ( Query query  ) 

Definition at line 234 of file DB.class.php.

References getDialect(), query(), and DialectString::toDialectString().

Referenced by SQLite::queryCount(), PgSQL::queryCount(), MySQLim::queryCount(), and MySQL::queryCount().

Here is the call graph for this function:

DB::queryRaw ( queryString  )  [abstract]
DB::queryRow ( Query query  )  [abstract]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

DB::querySet ( Query query  )  [abstract]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

DB::queueDrop (  ) 
Returns:
DB

Definition at line 197 of file DB.class.php.

Referenced by queueFlush().

DB::queueFlush (  ) 
Returns:
DB

Definition at line 207 of file DB.class.php.

References queryRaw(), and queueDrop().

Here is the call graph for this function:

DB::queueStart (  ) 

queue handling

Deprecated:
by Queue class
Returns:
DB

Definition at line 176 of file DB.class.php.

References hasQueue().

Here is the call graph for this function:

DB::queueStop (  ) 
Returns:
DB

Definition at line 187 of file DB.class.php.

DB::rollback (  ) 
Returns:
DB

Definition at line 150 of file DB.class.php.

References queryRaw().

Referenced by __destruct().

Here is the call graph for this function:

DB::setBasename ( base  ) 
Returns:
DB

Definition at line 318 of file DB.class.php.

Referenced by spawn().

DB::setDbEncoding (  )  [abstract]

Reimplemented in MySQL, MySQLim, PgSQL, and SQLite.

DB::setEncoding ( encoding  ) 
Returns:
DB

Definition at line 328 of file DB.class.php.

References $encoding.

Referenced by spawn().

DB::setHostname ( host  ) 
Returns:
DB

Definition at line 302 of file DB.class.php.

References $port.

Referenced by spawn().

DB::setPassword ( password  ) 
Returns:
DB

Definition at line 292 of file DB.class.php.

References $password.

Referenced by spawn().

DB::setPersistent ( really = false  ) 
Returns:
DB

Definition at line 272 of file DB.class.php.

Referenced by spawn().

DB::setUsername ( name  ) 
Returns:
DB

Definition at line 282 of file DB.class.php.

Referenced by spawn().

static DB::spawn ( connector,
user,
pass,
host,
base = null,
persistent = false,
encoding = null 
) [static]

Shortcut.

Returns:
DB

Definition at line 78 of file DB.class.php.

References $encoding, $persistent, setBasename(), setEncoding(), setHostname(), setPassword(), setPersistent(), and setUsername().

Here is the call graph for this function:


Member Data Documentation

DB::$basename = null [protected]

Definition at line 31 of file DB.class.php.

DB::$encoding = null [protected]

Definition at line 32 of file DB.class.php.

Referenced by setEncoding(), and spawn().

DB::$hostname = null [protected]

Definition at line 29 of file DB.class.php.

Referenced by MySQL::connect().

DB::$link = null [protected]

Definition at line 22 of file DB.class.php.

DB::$password = null [protected]

Definition at line 28 of file DB.class.php.

Referenced by setPassword().

DB::$persistent = false [protected]

Definition at line 24 of file DB.class.php.

Referenced by spawn().

DB::$port = null [protected]

Definition at line 30 of file DB.class.php.

Referenced by setHostname().

DB::$queue = array() [private]

Definition at line 39 of file DB.class.php.

DB::$toQueue = false [private]

Definition at line 40 of file DB.class.php.

DB::$transaction = false [private]

flag to indicate whether we're in transaction

Definition at line 37 of file DB.class.php.

DB::$username = null [protected]

Definition at line 27 of file DB.class.php.

const DB::FULL_TEXT_AND = 1
const DB::FULL_TEXT_OR = 2

Definition at line 20 of file DB.class.php.

Referenced by Expression::fullTextOr(), and Expression::fullTextRankOr().


The documentation for this class was generated from the following file: