00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 #if !defined(MYSQLPP_UDS_CONNECTION_H)
00028 #define MYSQLPP_UDS_CONNECTION_H
00029
00030 #include "connection.h"
00031
00032 namespace mysqlpp {
00033
00038
00039 class UnixDomainSocketConnection : public Connection
00040 {
00041 public:
00043 UnixDomainSocketConnection() :
00044 Connection()
00045 {
00046 }
00047
00060 UnixDomainSocketConnection(const char* path, const char* db = 0,
00061 const char* user = 0, const char* password = 0) :
00062 Connection()
00063 {
00064 connect(path, db, user, password);
00065 }
00066
00071 UnixDomainSocketConnection(const UnixDomainSocketConnection& other) :
00072 Connection(other)
00073 {
00074 }
00075
00077 ~UnixDomainSocketConnection() { }
00078
00087 bool connect(const char* path, const char* db = 0,
00088 const char* user = 0, const char* password = 0);
00089
00098 static bool is_socket(const char* path, std::string* error = 0);
00099 };
00100
00101
00102 }
00103
00104 #endif // !defined(MYSQLPP_UDS_CONNECTION_H)
00105