Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf48b9f9

Browse files
committed
Support for automatic code conversion between UNICODE and other
encodings
1 parentde53ce8 commitf48b9f9

File tree

1 file changed

+19
-1
lines changed

1 file changed

+19
-1
lines changed

‎src/include/mb/pg_wchar.h

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* $Id: pg_wchar.h,v 1.17 2000/08/25 14:24:09 ishii Exp $ */
1+
/* $Id: pg_wchar.h,v 1.18 2000/10/12 06:08:28 ishii Exp $ */
22

33
#ifndefPG_WCHAR_H
44
#definePG_WCHAR_H
@@ -82,6 +82,8 @@ typedef struct
8282
* client only */
8383
void(*to_mic) ();/* client encoding to MIC */
8484
void(*from_mic) ();/* MIC to client encoding */
85+
void(*to_unicode) ();/* client encoding to UTF-8 */
86+
void(*from_unicode) ();/* UTF-8 to client encoding */
8587
}pg_encoding_conv_tbl;
8688

8789
externpg_encoding_conv_tblpg_conv_tbl[];
@@ -95,13 +97,27 @@ typedef struct
9597

9698
externpg_wchar_tblpg_wchar_table[];
9799

100+
typedefstruct
101+
{
102+
unsignedintutf;/* UTF-8 */
103+
unsignedintcode;/* local code */
104+
unsignedcharencoding;/* encoding */
105+
}pg_utf_to_local;
106+
107+
typedefstruct
108+
{
109+
unsignedintcode;/* local code */
110+
unsignedintutf;/* UTF-8 */
111+
}pg_local_to_utf;
112+
98113
externintpg_mb2wchar(constunsignedchar*,pg_wchar*);
99114
externintpg_mb2wchar_with_len(constunsignedchar*,pg_wchar*,int);
100115
externintpg_char_and_wchar_strcmp(constchar*,constpg_wchar*);
101116
externintpg_wchar_strncmp(constpg_wchar*,constpg_wchar*,size_t);
102117
externintpg_char_and_wchar_strncmp(constchar*,constpg_wchar*,size_t);
103118
externsize_tpg_wchar_strlen(constpg_wchar*);
104119
externintpg_mblen(constunsignedchar*);
120+
externintpg_mblen_with_encoding(constunsignedchar*,int);
105121
externintpg_encoding_mblen(int,constunsignedchar*);
106122
externintpg_mule_mblen(constunsignedchar*);
107123
externintpg_mic_mblen(constunsignedchar*);
@@ -120,6 +136,8 @@ extern intpg_get_client_encoding(void);
120136
externunsignedchar*pg_client_to_server(unsignedchar*,int);
121137
externunsignedchar*pg_server_to_client(unsignedchar*,int);
122138
externintpg_valid_client_encoding(constchar*);
139+
externpg_encoding_conv_tbl*pg_get_enc_ent(int);
140+
externintpg_utf_mblen(constunsignedchar*);
123141

124142
/* internally-used versions of functions. The PG_xxx forms of these
125143
* functions have fmgr-compatible interfaves.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp