00001 /* Copyright (C) 2000 MySQL AB 00002 00003 This program is free software; you can redistribute it and/or modify 00004 it under the terms of the GNU General Public License as published by 00005 the Free Software Foundation; version 2 of the License. 00006 00007 This program is distributed in the hope that it will be useful, 00008 but WITHOUT ANY WARRANTY; without even the implied warranty of 00009 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00010 GNU General Public License for more details. 00011 00012 You should have received a copy of the GNU General Public License 00013 along with this program; if not, write to the Free Software 00014 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ 00015 00016 #include <config.h> 00017 #include <drizzled/internal/m_string.h> 00018 #include <drizzled/charset_info.h> 00019 00020 namespace drizzled 00021 { 00022 00023 /* 00024 00025 This files implements routines which parse XML based 00026 character set and collation description files. 00027 00028 Unicode collations are encoded according to 00029 00030 Unicode Technical Standard #35 00031 Locale Data Markup Language (LDML) 00032 http://www.unicode.org/reports/tr35/ 00033 00034 and converted into ICU string according to 00035 00036 Collation Customization 00037 http://oss.software.ibm.com/icu/userguide/Collate_Customization.html 00038 00039 */ 00040 00041 00042 #define MY_CS_CSDESCR_SIZE 64 00043 #define MY_CS_TAILORING_SIZE 1024 00044 00045 typedef struct my_cs_file_info 00046 { 00047 char csname[MY_CS_NAME_SIZE]; 00048 char name[MY_CS_NAME_SIZE]; 00049 unsigned char ctype[MY_CS_CTYPE_TABLE_SIZE]; 00050 unsigned char to_lower[MY_CS_TO_LOWER_TABLE_SIZE]; 00051 unsigned char to_upper[MY_CS_TO_UPPER_TABLE_SIZE]; 00052 unsigned char sort_order[MY_CS_SORT_ORDER_TABLE_SIZE]; 00053 uint16_t tab_to_uni[MY_CS_TO_UNI_TABLE_SIZE]; 00054 char comment[MY_CS_CSDESCR_SIZE]; 00055 char tailoring[MY_CS_TAILORING_SIZE]; 00056 size_t tailoring_length; 00057 CHARSET_INFO cs; 00058 int (*add_collation)(CHARSET_INFO *cs); 00059 } MY_CHARSET_LOADER; 00060 00061 } /* namespace drizzled */