Home | History | Annotate | Download | only in makeconv

Lines Matching refs:table

41 CnvExtAddTable(NewConverter *cnvData, UCMTable *table, UConverterStaticData *staticData);
52 /* toUnicode (state table in ucm->states) */
126 /* write the header and base table name for an extension-only table */
140 /* write the header and the base table name */
291 * the toUnicode table.
293 * for the base toUnicode table but not for the base fromUnicode table.
294 * The table must be sorted.
298 reduceToUMappings(UCMTable *table) {
304 mappings=table->mappings;
305 map=table->reverseMap;
306 count=table->mappingsLength;
328 getToUnicodeValue(CnvExtData *extData, UCMTable *table, UCMapping *m) {
343 u32=UCM_GET_CODE_POINTS(table, m);
394 * One function invocation generates one section table.
399 * 2. Allocate the section table with possible optimization for linear access.
400 * 3. Write temporary version of the section table with start indexes of
402 * 4. Iterate through the table once more, and depending on the subsection length:
403 * 0: write 0 as a result value (unused byte in linear-access section table)
411 generateToUTable(CnvExtData *extData, UCMTable *table,
423 mappings=table->mappings;
424 map=table->reverseMap;
428 bytes=UCM_GET_BYTES(table, m);
435 bytes=UCM_GET_BYTES(table, m);
448 * for the root table and for fairly full tables:
452 * exception: use a compact table if count==0x100 because
460 fprintf(stderr, "error: toUnicode extension table section overflow: %ld section entries\n", (long)count);
470 /* step 3: write temporary section table with subsection starts */
472 j=0; /* section table index */
475 bytes=UCM_GET_BYTES(table, m);
481 /* write empty subsections for unused units in a linear table */
505 /* leave the value zero: empty subsection for unused unit in a linear table */
519 ucm_printMapping(table, m, stderr);
520 ucm_printMapping(table
524 defaultValue=getToUnicodeValue(extData, table, m);
531 /* write the index to the subsection table */
535 if(!generateToUTable(extData, table, subStart, subLimit, unitIndex+1, defaultValue)) {
544 * Generate the toUTable and toUUChars from the input table.
545 * The input table must be sorted, and all precision flags must be 0..3.
546 * This function will modify the table's reverseMap.
549 makeToUTable(CnvExtData *extData, UCMTable *table) {
552 toUCount=reduceToUMappings(table);
557 return generateToUTable(extData, table, 0, toUCount, 0, 0);
576 * which are irrelevant for the fromUnicode extension table.
582 * The table must be sorted.
586 prepareFromUMappings(UCMTable *table) {
592 mappings=table->mappings;
593 map=table->reverseMap;
594 count=table->mappingsLength;
618 u32=UCM_GET_CODE_POINTS(table, m);
635 getFromUBytesValue(CnvExtData *extData, UCMTable *table, UCMapping *m) {
652 bytes=UCM_GET_BYTES(table, m);
680 u16Length=U16_LENGTH(UCM_GET_CODE_POINTS(table, m)[0])+(m->uLen-2);
708 generateFromUTable(CnvExtData *extData, UCMTable *table,
721 mappings=table->mappings;
722 map=table->reverseMap;
726 uchars=(UChar *)UCM_GET_CODE_POINTS(table, m);
733 uchars=(UChar *)UCM_GET_CODE_POINTS(table, m);
754 /* step 3: write temporary section table with subsection starts */
756 j=0; /* section table index */
759 uchars=(UChar *)UCM_GET_CODE_POINTS(table, m);
790 ucm_printMapping(table, m, stderr);
791 ucm_printMapping(table, mappings+map[subStart], stderr);
795 defaultValue=getFromUBytesValue(extData, table, m);
802 /* write the index to the subsection table */
806 if(!generateFromUTable(extData, table, subStart, subLimit, unitIndex+1, defaultValue)) {
927 generateFromUTrie(CnvExtData *extData, UCMTable *table, int32_t mapLength) {
940 mappings=table->mappings;
941 map=table->reverseMap;
950 codePoints=UCM_GET_CODE_POINTS(table, m);
959 codePoints=UCM_GET_CODE_POINTS(table, m);
966 * because the table is sorted lexically
970 codePoints=UCM_GET_CODE_POINTS(table, m);
978 ucm_printMapping(table, m, stderr);
979 ucm_printMapping(table, mappings+map[subStart], stderr);
983 value=getFromUBytesValue(extData, table, m);
990 /* write the index to the subsection table */
994 if(!generateFromUTable(extData, table, subStart, subLimit, 2, value)) {
1003 * Generate the fromU data structures from the input table.
1004 * The input table must be sorted, and all precision flags must be 0..3.
1005 * This function will modify the table's reverseMap.
1008 makeFromUTable(CnvExtData *extData, UCMTable *table) {
1012 fromUCount=prepareFromUMappings(table);
1034 if(!generateFromUTrie(extData, table, fromUCount)) {
1054 CnvExtAddTable(NewConverter *cnvData, UCMTable *table, UConverterStaticData *staticData) {
1057 if(table->unicodeMask&UCNV_HAS_SURROGATES) {
1067 * assume that the table is sorted
1074 makeToUTable(extData, table) &&
1075 makeFromUTable(extData, table);