interface Db \ Connection

All implemented interfaces:
Serializable
All known implementing classes:
ReplicatedConnection, SoloConnection

Represents an instance of a database connection, which can be used to prepare and execute queries. TODO master/slave switch TODO everything else TODO maybe create a subclass SwitchingConnection that can switch as necessary? we can then put initialisation in the __construct


Method Summary

Name Description
lastInsertId()
prepare($query)

public function lastInsertId()

Returns:
the last inserted auto_increment id, if there is any

public function prepare($query)

Returns:
a Query ready to be used