CUBRID Engine  latest
clientids Struct Reference

#include <client_credentials.hpp>

Inheritance diagram for clientids:
Inheritance graph
Collaboration diagram for clientids:
Collaboration graph

Public Member Functions

 clientids ()
 
 ~clientids () override
 
const char * get_client_info () const
 
const char * get_db_user () const
 
const char * get_program_name () const
 
const char * get_login_name () const
 
const char * get_host_name () const
 
void set_ids (db_client_type type, const char *client_info, const char *db_user, const char *program_name, const char *login_name, const char *host_name, int process_id)
 
void set_ids (const clientids &other)
 
void set_user (const char *db_user)
 
void set_system_internal ()
 
void set_system_internal_with_user (const char *db_user)
 
void reset ()
 
virtual size_t get_packed_size (cubpacking::packer &serializator, std::size_t start_offset=0) const override
 
virtual void pack (cubpacking::packer &serializator) const override
 
virtual void unpack (cubpacking::unpacker &deserializator) override
 
- Public Member Functions inherited from cubpacking::packable_object
virtual ~packable_object ()
 
virtual bool is_equal (const packable_object *other)
 

Public Attributes

db_client_type client_type
 
std::string client_info
 
std::string db_user
 
std::string program_name
 
std::string login_name
 
std::string host_name
 
int process_id
 

Static Public Attributes

static const char * UNKNOWN_ID = "(unknown)"
 

Private Member Functions

void set_client_info (const char *client_info)
 
void set_program_name (const char *program_name)
 
void set_login_name (const char *login_name)
 
void set_host_name (const char *host_name)
 

Detailed Description

Definition at line 38 of file client_credentials.hpp.

Constructor & Destructor Documentation

clientids::clientids ( )

Definition at line 35 of file client_credentials.cpp.

References db_user, host_name, login_name, process_id, and program_name.

clientids::~clientids ( )
override

Definition at line 46 of file client_credentials.cpp.

Member Function Documentation

const char * clientids::get_client_info ( ) const

Definition at line 51 of file client_credentials.cpp.

References client_info.

Referenced by logtb_descriptors_start_scan().

Here is the caller graph for this function:

const char * clientids::get_login_name ( ) const

Definition at line 69 of file client_credentials.cpp.

References login_name.

Referenced by boot_restart_client(), logtb_descriptors_start_scan(), logtb_dump_tdes(), set_ids(), and xlogtb_get_pack_tran_table().

Here is the caller graph for this function:

size_t clientids::get_packed_size ( cubpacking::packer serializator,
std::size_t  start_offset = 0 
) const
overridevirtual

Implements cubpacking::packable_object.

Reimplemented in boot_client_credential.

Definition at line 175 of file client_credentials.cpp.

References client_type, CLIENTID_PACKER_ARGS, and cubpacking::packer::get_all_packed_size().

Referenced by boot_client_credential::get_packed_size().

Here is the caller graph for this function:

void clientids::pack ( cubpacking::packer serializator) const
overridevirtual

Implements cubpacking::packable_object.

Reimplemented in boot_client_credential.

Definition at line 181 of file client_credentials.cpp.

References client_type, CLIENTID_PACKER_ARGS, and cubpacking::packer::pack_all().

Referenced by boot_client_credential::pack().

Here is the caller graph for this function:

void clientids::reset ( void  )

Definition at line 156 of file client_credentials.cpp.

References client_info, client_type, DB_CLIENT_TYPE_UNKNOWN, db_user, host_name, login_name, process_id, and program_name.

Referenced by cubload::load_task::execute(), logtb_release_tran_index(), and set_system_internal().

Here is the caller graph for this function:

void clientids::set_client_info ( const char *  client_info)
private

Definition at line 103 of file client_credentials.cpp.

References client_info, DB_MAX_IDENTIFIER_LENGTH, and string_ncopy().

Referenced by set_ids().

Here is the caller graph for this function:

void clientids::set_host_name ( const char *  host_name)
private

Definition at line 136 of file client_credentials.cpp.

References CUB_MAXHOSTNAMELEN, host_name, and string_ncopy().

Referenced by set_ids().

Here is the caller graph for this function:

void clientids::set_ids ( db_client_type  type,
const char *  client_info,
const char *  db_user,
const char *  program_name,
const char *  login_name,
const char *  host_name,
int  process_id 
)

Definition at line 81 of file client_credentials.cpp.

References client_type, process_id, set_client_info(), set_host_name(), set_login_name(), set_program_name(), and set_user().

Referenced by cubload::load_task::execute(), logtb_set_tdes(), and set_ids().

Here is the caller graph for this function:

void clientids::set_ids ( const clientids other)
void clientids::set_login_name ( const char *  login_name)
private

Definition at line 130 of file client_credentials.cpp.

References L_cuserid, login_name, and string_ncopy().

Referenced by set_ids().

Here is the caller graph for this function:

void clientids::set_program_name ( const char *  program_name)
private

Definition at line 115 of file client_credentials.cpp.

References basename_r(), NULL, program_name, string_ncopy(), and UNKNOWN_ID.

Referenced by set_ids().

Here is the caller graph for this function:

void clientids::set_system_internal ( )

Definition at line 142 of file client_credentials.cpp.

References client_type, DB_CLIENT_TYPE_SYSTEM_INTERNAL, and reset().

Referenced by logtb_initialize_system_tdes(), and set_system_internal_with_user().

Here is the caller graph for this function:

void clientids::set_system_internal_with_user ( const char *  db_user)

Definition at line 149 of file client_credentials.cpp.

References db_user, and set_system_internal().

Referenced by log_2pc_read_prepare(), log_2pc_recovery_start(), log_recovery_redo(), and log_rv_analysis_end_checkpoint().

Here is the caller graph for this function:

void clientids::set_user ( const char *  db_user)

Definition at line 109 of file client_credentials.cpp.

References db_user, LOG_USERNAME_MAX, and string_ncopy().

Referenced by login_user(), logtb_set_user_name(), and set_ids().

Here is the caller graph for this function:

void clientids::unpack ( cubpacking::unpacker deserializator)
overridevirtual

Implements cubpacking::packable_object.

Reimplemented in boot_client_credential.

Definition at line 187 of file client_credentials.cpp.

References client_type, CLIENTID_PACKER_ARGS, and cubpacking::unpacker::unpack_all().

Referenced by boot_client_credential::unpack().

Here is the caller graph for this function:

Member Data Documentation

std::string clientids::client_info
const char * clientids::UNKNOWN_ID = "(unknown)"
static

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