MySQL 9.1.0
Source Code Documentation
s_mysql_mysql_command_options Struct Reference

A service that provides the apis for mysql command get_option and set_option. More...

#include <mysql_command_services.h>

Public Attributes

mysql_service_status_t(* set )(MYSQL_H mysql, int option, const void *arg)
 Calls mysql_options api to sets connect options for connection-establishment functions such as real_connect(). More...
 
mysql_service_status_t(* get )(MYSQL_H mysql, int option, const void *arg)
 Calls mysql_get_option api to returns the value of a mysql_options() option. More...
 

Detailed Description

A service that provides the apis for mysql command get_option and set_option.

Member Data Documentation

◆ get

mysql_service_status_t(* s_mysql_mysql_command_options::get) (MYSQL_H mysql, int option, const void *arg)

Calls mysql_get_option api to returns the value of a mysql_options() option.

Parameters
[in]mysqlA valid mysql object.
[in]optionThe option argument is the option that you want to get.
[out]argThe arg argument is the value for the option to store.
Return values
truefailure
falsesuccess

◆ set

mysql_service_status_t(* s_mysql_mysql_command_options::set) (MYSQL_H mysql, int option, const void *arg)

Calls mysql_options api to sets connect options for connection-establishment functions such as real_connect().

Parameters
[in]mysqlA valid mysql object.
[in]optionThe option argument is the option that you want to set.
[in]argThe arg argument is the value for the option.

-----------—+----------------------------—+-----------------------------—+ Type | Option |Explanation | -----------—+----------------------------—+-----------------------------—+ const char * |MYSQL_COMMAND_CONSUMER_SERVICE |The service (implementation) | | |name/prefix to look for in the | | |registry and direct all the | | |calls to. | -----------—+----------------------------—+-----------------------------—+ MYSQL_THD |MYSQL_COMMAND_LOCAL_THD_HANDLE |The THD to run the query in. | | |If null a new internal THD will | | |be created. | -----------—+----------------------------—+-----------------------------—+ const char * |MYSQL_COMMAND_PROTOCOL |Could be valid socket meaning co| | |nnect to remote server, could be| | |"local"(default) meaning connect| | |to the current server. | -----------—+----------------------------—+-----------------------------—+ const char * |MYSQL_COMMAND_USER_NAME |The user name to send to the | | |server/set into the thread's | | |security context. | -----------—+----------------------------—+-----------------------------—+ const char * |MYSQL_COMMAND_HOST_NAME |The host name to use to | | |connect/set into the thread's | | |security context. | -----------—+----------------------------—+-----------------------------—+ int |MYSQL_COMMAND_TCPIP_PORT |The port to use to connect. | -----------—+----------------------------—+-----------------------------—+

Note
For the other mysql client options it calls the mysql_options api.
Return values
truefailure
falsesuccess

The documentation for this struct was generated from the following file: