~drizzle-trunk/drizzle/development

1 by brian
clean slate
1
/* Copyright (C) 2000 MySQL AB
2
3
   This program is free software; you can redistribute it and/or modify
4
   it under the terms of the GNU General Public License as published by
5
   the Free Software Foundation; version 2 of the License.
6
7
   This program is distributed in the hope that it will be useful,
8
   but WITHOUT ANY WARRANTY; without even the implied warranty of
9
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10
   GNU General Public License for more details.
11
12
   You should have received a copy of the GNU General Public License
13
   along with this program; if not, write to the Free Software
14
   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA */
15
685.1.3 by Monty Taylor
Turned off stdinc - and then fixed the carnage.
16
#include "m_string.h"
17
#include "m_ctype.h"
1 by brian
clean slate
18
19
20
/*
21
22
  This files implements routines which parse XML based
23
  character set and collation description files.
660.1.3 by Eric Herman
removed trailing whitespace with simple script:
24
1 by brian
clean slate
25
  Unicode collations are encoded according to
660.1.3 by Eric Herman
removed trailing whitespace with simple script:
26
1 by brian
clean slate
27
    Unicode Technical Standard #35
28
    Locale Data Markup Language (LDML)
29
    http://www.unicode.org/reports/tr35/
660.1.3 by Eric Herman
removed trailing whitespace with simple script:
30
1 by brian
clean slate
31
  and converted into ICU string according to
660.1.3 by Eric Herman
removed trailing whitespace with simple script:
32
1 by brian
clean slate
33
    Collation Customization
34
    http://oss.software.ibm.com/icu/userguide/Collate_Customization.html
660.1.3 by Eric Herman
removed trailing whitespace with simple script:
35
1 by brian
clean slate
36
*/
37
38
struct my_cs_file_section_st
39
{
40
  int        state;
41
  const char *str;
42
};
43
44
45
#define MY_CS_CSDESCR_SIZE	64
46
#define MY_CS_TAILORING_SIZE	1024
47
48
typedef struct my_cs_file_info
49
{
50
  char   csname[MY_CS_NAME_SIZE];
51
  char   name[MY_CS_NAME_SIZE];
481 by Brian Aker
Remove all of uchar.
52
  unsigned char  ctype[MY_CS_CTYPE_TABLE_SIZE];
53
  unsigned char  to_lower[MY_CS_TO_LOWER_TABLE_SIZE];
54
  unsigned char  to_upper[MY_CS_TO_UPPER_TABLE_SIZE];
55
  unsigned char  sort_order[MY_CS_SORT_ORDER_TABLE_SIZE];
206 by Brian Aker
Removed final uint dead types.
56
  uint16_t tab_to_uni[MY_CS_TO_UNI_TABLE_SIZE];
1 by brian
clean slate
57
  char   comment[MY_CS_CSDESCR_SIZE];
58
  char   tailoring[MY_CS_TAILORING_SIZE];
59
  size_t tailoring_length;
60
  CHARSET_INFO cs;
61
  int (*add_collation)(CHARSET_INFO *cs);
62
} MY_CHARSET_LOADER;