MySQL 9.1.0
Source Code Documentation
Channel_info Class Referenceabstract

This abstract base class represents connection channel information about a new connection. More...

#include <channel_info.h>

Inheritance diagram for Channel_info:
[legend]

Public Member Functions

virtual ~Channel_info ()=default
 
virtual THDcreate_thd ()
 Instantiate and initialize THD object and vio. More...
 
virtual void send_error_and_close_channel (uint errorcode, int error, bool senderror)
 Send error back to the client and close the channel. More...
 
ulonglong get_prior_thr_create_utime () const
 
void set_prior_thr_create_utime ()
 
virtual bool is_admin_connection () const
 

Protected Member Functions

virtual Viocreate_and_init_vio () const =0
 Create and initialize a Vio object. More...
 
 Channel_info ()
 

Private Attributes

ulonglong prior_thr_create_utime
 

Detailed Description

This abstract base class represents connection channel information about a new connection.

Its subclasses encapsulate differences between different connection channel types.

Currently we support local and TCP/IP sockets (all platforms), named pipes and shared memory (Windows only).

Constructor & Destructor Documentation

◆ Channel_info()

Channel_info::Channel_info ( )
inlineprotected

◆ ~Channel_info()

virtual Channel_info::~Channel_info ( )
virtualdefault

Member Function Documentation

◆ create_and_init_vio()

virtual Vio * Channel_info::create_and_init_vio ( ) const
protectedpure virtual

Create and initialize a Vio object.

Returns
a pointer to the initialized a vio object.

Implemented in Channel_info_named_pipe, Channel_info_shared_mem, Channel_info_local_socket, and Channel_info_tcpip_socket.

◆ create_thd()

THD * Channel_info::create_thd ( )
virtual

Instantiate and initialize THD object and vio.

Returns
pointer to initialized THD object.
Return values
NULLTHD object allocation fails.

Reimplemented in Channel_info_named_pipe, Channel_info_shared_mem, Channel_info_local_socket, and Channel_info_tcpip_socket.

◆ get_prior_thr_create_utime()

ulonglong Channel_info::get_prior_thr_create_utime ( ) const
inline

◆ is_admin_connection()

virtual bool Channel_info::is_admin_connection ( ) const
inlinevirtual

Reimplemented in Channel_info_tcpip_socket.

◆ send_error_and_close_channel()

void Channel_info::send_error_and_close_channel ( uint  errorcode,
int  error,
bool  senderror 
)
virtual

Send error back to the client and close the channel.

Parameters
errorcodecode indicating type of error.
erroroperating system specific error code.
senderrortrue if the error need to be sent to client else false.

Reimplemented in Channel_info_named_pipe, Channel_info_shared_mem, Channel_info_local_socket, and Channel_info_tcpip_socket.

◆ set_prior_thr_create_utime()

void Channel_info::set_prior_thr_create_utime ( )
inline

Member Data Documentation

◆ prior_thr_create_utime

ulonglong Channel_info::prior_thr_create_utime
private

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