Skip to content

File message_catalog.c

FileList > base > message_catalog.c

Go to the source code of this file

  • #include "config.h"
  • #include "message_catalog.h"
  • #include <sys/types.h>
  • #include <sys/stat.h>
  • #include <sys/mman.h>
  • #include <netinet/in.h>
  • #include <errno.h>
  • #include <fcntl.h>
  • #include <stdlib.h>
  • #include <locale.h>
  • #include <string.h>
  • #include <limits.h>
  • #include <stdio.h>
  • #include "porting.h"
  • #include "environment_variable.h"
  • #include "error_code.h"
  • #include "error_manager.h"
  • #include "language_support.h"
  • #include "memory_wrapper.hpp"

Classes

Type Name
struct _nl_cat_d
struct msgcat_def
struct nls_cat_hdr
struct nls_msg_hdr
struct nls_set_hdr

Public Types

Type Name
typedef struct _nl_cat_d * cub_nl_catd

Public Attributes

Type Name
struct msgcat_def msgcat_System = /* multi line expression */

Public Functions

Type Name
int msgcat_close (MSG_CATD msg_catd)
int msgcat_final (void)
MSG_CATD msgcat_get_descriptor (int cat_id)
char * msgcat_gets (MSG_CATD msg_catd, int set_id, int msg_id, const char * s)
int msgcat_init (void)
char * msgcat_message (int cat_id, int set_id, int msg_id)
MSG_CATD msgcat_open (const char * name)
FILE * msgcat_open_file (const char * name)

Public Static Functions

Type Name
int cub_catclose (cub_nl_catd catd)
char * cub_catgets (cub_nl_catd catd, int set_id, int msg_id, const char * s)
cub_nl_catd cub_catopen (const char * name, int type)
cub_nl_catd load_msgcat (const char * path)

Macros

Type Name
define CUB_NL_CAT_LOCALE 1
define CUB_NL_SETD 0
define DEFAULT_NLS_PATH "/usr/[**share**](broker__monitor_8c.md#function-timeout)/[**nls**](broker__monitor_8c.md#function-timeout)/%[**L**](broker__monitor_8c.md#function-timeout)/%[**N.cat:**](broker__monitor_8c.md#function-timeout)/[**usr**](broker__monitor_8c.md#function-timeout)/[**share**](broker__monitor_8c.md#function-timeout)/[**nls**](broker__monitor_8c.md#function-timeout)/%N/%[**L:**](broker__monitor_8c.md#function-timeout)/[**usr**](broker__monitor_8c.md#function-timeout)/[**local**](broker__monitor_8c.md#function-timeout)/[**share**](broker__monitor_8c.md#function-timeout)/[**nls**](broker__monitor_8c.md#function-timeout)/%[**L**](broker__monitor_8c.md#function-timeout)/%[**N.cat:**](broker__monitor_8c.md#function-timeout)/[**usr**](broker__monitor_8c.md#function-timeout)/[**local**](broker__monitor_8c.md#function-timeout)/[**share**](broker__monitor_8c.md#function-timeout)/[**nls**](broker__monitor_8c.md#function-timeout)/%N/%[**L"**](broker__monitor_8c.md#function-timeout)
define ENCODING_LEN 40
define MSGCAT_SYSTEM_DIM ([**sizeof**](broker__monitor_8c.md#function-timeout)([**msgcat\_System**](message__catalog_8c.md#variable-msgcat_system)) / [**sizeof**](broker__monitor_8c.md#function-timeout)([**struct**](broker__monitor_8c.md#function-timeout) [**msgcat\_def**](structmsgcat__def.md)))
define NLS_MAGIC 0xff88ff89

Public Types Documentation

typedef cub_nl_catd

typedef struct _nl_cat_d * cub_nl_catd;

Public Attributes Documentation

variable msgcat_System

struct msgcat_def msgcat_System[];

Public Functions Documentation

function msgcat_close

int msgcat_close (
    MSG_CATD msg_catd
) 

function msgcat_final

int msgcat_final (
    void
) 

function msgcat_get_descriptor

MSG_CATD msgcat_get_descriptor (
    int cat_id
) 

function msgcat_gets

char * msgcat_gets (
    MSG_CATD msg_catd,
    int set_id,
    int msg_id,
    const  char * s
) 

function msgcat_init

int msgcat_init (
    void
) 

function msgcat_message

char * msgcat_message (
    int cat_id,
    int set_id,
    int msg_id
) 

function msgcat_open

MSG_CATD msgcat_open (
    const  char * name
) 

function msgcat_open_file

FILE * msgcat_open_file (
    const  char * name
) 

Public Static Functions Documentation

function cub_catclose

static int cub_catclose (
    cub_nl_catd catd
) 

function cub_catgets

static char * cub_catgets (
    cub_nl_catd catd,
    int set_id,
    int msg_id,
    const  char * s
) 

function cub_catopen

static cub_nl_catd cub_catopen (
    const  char * name,
    int type
) 

function load_msgcat

static cub_nl_catd load_msgcat (
    const  char * path
) 

Macro Definition Documentation

define CUB_NL_CAT_LOCALE

#define CUB_NL_CAT_LOCALE `1`

define CUB_NL_SETD

#define CUB_NL_SETD `0`

define DEFAULT_NLS_PATH

#define DEFAULT_NLS_PATH `"/usr/ share / nls /% L /% N.cat: / usr / share / nls /%N/% L: / usr / local / share / nls /% L /% N.cat: / usr / local / share / nls /%N/% L"`

define ENCODING_LEN

#define ENCODING_LEN `40`

define MSGCAT_SYSTEM_DIM

#define MSGCAT_SYSTEM_DIM `( sizeof ( msgcat_System ) / sizeof ( struct  msgcat_def ))`

define NLS_MAGIC

#define NLS_MAGIC `0xff88ff89`


The documentation for this class was generated from the following file cubrid/src/base/message_catalog.c