~drizzle-trunk/libdrizzle/jenkins-Libdrizzle-29

« back to all changes in this revision

Viewing changes to libdrizzle/conn_local.h

  • Committer: Continuous Integration
  • Date: 2012-12-31 01:08:39 UTC
  • mfrom: (73.1.3 5.1-trunk)
  • Revision ID: ci@drizzle.org-20121231010839-8hg9bazx84mj03fw
Merge lp:~brianaker/libdrizzle/private-headers-connection-test Build: jenkins-Libdrizzle-25

Show diffs side-by-side

added added

removed removed

Lines of Context:
2
2
 *
3
3
 * Drizzle Client & Protocol Library
4
4
 *
 
5
 * Copyright (C) 2012 Drizzle Developer Group
5
6
 * Copyright (C) 2008 Eric Day (eday@oddments.org)
6
7
 * All rights reserved.
7
8
 *
58
59
 * @param[in] con Connection structure previously initialized with
59
60
 *  drizzle_create(), drizzle_clone(), or related functions.
60
61
 */
61
 
DRIZZLE_LOCAL
62
62
void drizzle_reset_addrinfo(drizzle_st *con);
63
63
 
64
64
/**
75
75
 * @return On success, a pointer to the (possibly allocated) structure. On
76
76
 *  failure this will be NULL.
77
77
 */
78
 
DRIZZLE_LOCAL
79
78
drizzle_result_st *drizzle_command_write(drizzle_st *con,
80
79
                                             drizzle_result_st *result,
81
80
                                             drizzle_command_t command,
82
81
                                             const void *data, size_t size,
83
82
                                             size_t total,
84
83
                                             drizzle_return_t *ret_ptr);
 
84
/**
 
85
 * Set TCP host and port for a connection.
 
86
 *
 
87
 * @param[in] con Connection structure previously initialized with
 
88
 *  drizzle_create(), drizzle_clone(), or related functions.
 
89
 * @param[in] host Host to use for this connection, NULL for default value.
 
90
 * @param[in] port Port to use for this connection, 0 for default value.
 
91
 */
 
92
void drizzle_set_tcp(drizzle_st *con, const char *host, in_port_t port);
 
93
 
 
94
/**
 
95
 * Get unix domain socket for a connection.
 
96
 *
 
97
 * @param[in] con Connection structure previously initialized with
 
98
 *  drizzle_create(), drizzle_clone(), or related functions.
 
99
 * @return Unix domain socket set for this connection, NULL if not set.
 
100
 */
 
101
const char *drizzle_uds(const drizzle_st *con);
 
102
 
 
103
/**
 
104
 * Set username and password for a connection.
 
105
 *
 
106
 * @param[in] con Connection structure previously initialized with
 
107
 *  drizzle_create(), drizzle_clone(), or related functions.
 
108
 * @param[in] user Username to use for this connection.
 
109
 * @param[in] password Password to use for this connection.
 
110
 */
 
111
void drizzle_set_auth(drizzle_st *con, const char *user, const char *password);
 
112
 
 
113
/**
 
114
 * Set database for a connection.
 
115
 *
 
116
 * @param[in] con Connection structure previously initialized with
 
117
 *  drizzle_create(), drizzle_clone(), or related functions.
 
118
 * @param[in] db Database to use with this connection.
 
119
 */
 
120
void drizzle_set_db(drizzle_st *con, const char *db);
85
121
 
86
122
/**
87
123
 * Check if state stack is empty.