MySQL 5.6.14 Source Code Document
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Connection Class Reference

#include <common.h>

Public Member Functions

 Connection (MYSQL_PLUGIN_VIO *vio)
int write (const Blob &)
Blob read ()
int error () const

Detailed Description

Connection class Convenience wrapper around MYSQL_PLUGIN_VIO object providing basic read/write operations.

Definition at line 214 of file common.h.

Constructor & Destructor Documentation

Connection::Connection ( MYSQL_PLUGIN_VIO vio)

Connection class Create connection out of an active MYSQL_PLUGIN_VIO object.

Parameters
[in]viopointer to a MYSQL_PLUGIN_VIO object used for connection - it can not be NULL

Definition at line 53 of file common.cc.

Member Function Documentation

Blob Connection::read ( )

Read data from connection.

Returns
A Blob containing read packet or null Blob in case of error.
Note
In case of error, VIO error code is stored in the connection object and can be obtained with error() method.

Definition at line 92 of file common.cc.

Here is the caller graph for this function:

int Connection::write ( const Blob blob)

Write data to the connection.

Parameters
[in]blobdata to be written
Returns
0 on success, VIO error code on failure.
Note
In case of error, VIO error code is stored in the connection object and can be obtained with error() method.

Definition at line 70 of file common.cc.

Here is the caller graph for this function:


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