|
| UnixDomainSocketConnection () |
| Create object without connecting it to the MySQL server.
|
|
| UnixDomainSocketConnection (const char *path, const char *db=0, const char *user=0, const char *password=0) |
| Create object and connect to database server over Unix domain sockets in one step. More...
|
|
| UnixDomainSocketConnection (const UnixDomainSocketConnection &other) |
| Establish a new connection using the same parameters as an existing connection. More...
|
|
| ~UnixDomainSocketConnection () |
| Destroy object.
|
|
bool | connect (const char *path, const char *db=0, const char *user=0, const char *password=0) |
| Connect to database after object is created. More...
|
|
| Connection (bool te=true) |
| Create object without connecting to the database server. More...
|
|
| Connection (const char *db, const char *server=0, const char *user=0, const char *password=0, unsigned int port=0) |
| Create object and connect to database server in one step. More...
|
|
| Connection (const Connection &other) |
| Establish a new connection using the same parameters as an existing connection. More...
|
|
virtual | ~Connection () |
| Destroy object.
|
|
std::string | client_version () const |
| Get version of library underpinning the current database driver.
|
|
bool | connected () const |
| Returns true if connection was established successfully. More...
|
|
ulonglong | count_rows (const std::string &table) |
| Returns the number of rows in a table. More...
|
|
bool | create_db (const std::string &db) |
| Ask the database server to create a database. More...
|
|
void | disconnect () |
| Drop the connection to the database server.
|
|
DBDriver * | driver () |
| Returns a reference to the current database driver.
|
|
bool | drop_db (const std::string &db) |
| Asks the database server to drop (destroy) a database. More...
|
|
int | errnum () |
| Return last error number associated with this connection.
|
|
const char * | error () const |
| Return error message for last error associated with this connection. More...
|
|
std::string | ipc_info () const |
| Get information about the IPC connection to the database server. More...
|
|
bool | kill (unsigned long tid) const |
| Kill a database server thread. More...
|
|
| operator private_bool_type () const |
| Test whether any error has occurred within the object. More...
|
|
Connection & | operator= (const Connection &rhs) |
| Copy an existing Connection object's state into this object.
|
|
bool | ping () |
| "Pings" the database server More...
|
|
int | protocol_version () const |
| Returns version number of the protocol the database driver uses to communicate with the server.
|
|
Query | query (const char *qstr=0) |
| Return a new query object. More...
|
|
Query | query (const std::string &qstr) |
| Return a new query object. More...
|
|
bool | select_db (const std::string &db) |
| Change to a different database managed by the database server we are connected to. More...
|
|
std::string | server_version () const |
| Get the database server's version string.
|
|
bool | set_option (Option *o) |
| Sets a connection option. More...
|
|
bool | shutdown () |
| Ask database server to shut down.
|
|
std::string | server_status () const |
| Returns information about database server's status.
|
|
unsigned long | thread_id () |
| Returns the database server's thread ID for this connection. More...
|
|
| OptionalExceptions (bool e=true) |
| Default constructor. More...
|
|
virtual | ~OptionalExceptions () |
| Destroy object.
|
|
void | enable_exceptions () const |
| Enable exceptions from the object.
|
|
void | disable_exceptions () const |
| Disable exceptions from the object.
|
|
bool | throw_exceptions () const |
| Returns true if exceptions are enabled.
|
|
Specialization of Connection
for Unix domain sockets.
This class just simplifies the connection creation interface of Connection
. It does not add new functionality.