7 extern const unsigned char chise_db_dir[];
9 typedef enum CHISE_DS_Type
15 typedef struct CHISE_DS CHISE_DS;
18 CHISE_DS_open (CHISE_DS_Type type, const unsigned char *location,
19 DBTYPE subtype, int modemask);
21 int CHISE_DS_close (CHISE_DS *ds);
24 typedef int CHISE_Char_ID;
27 typedef DBT CHISE_Value;
30 chise_value_size (const CHISE_Value *s)
36 chise_value_data (const CHISE_Value *s)
42 chise_value_to_c_string (const CHISE_Value *s)
48 typedef struct CHISE_Feature_Table CHISE_Feature_Table;
49 typedef CHISE_Feature_Table* CHISE_Feature;
52 chise_ds_get_feature (CHISE_DS *ds, const unsigned char *name);
55 chise_ds_load_char_feature_value (CHISE_DS *ds,
57 const unsigned char *name,
58 CHISE_Value *valdatum);
60 int chise_feature_setup_db (CHISE_Feature feature, int writable);
62 int chise_feature_sync (CHISE_Feature feature);
64 int chise_char_set_feature_value (CHISE_Char_ID cid,
65 CHISE_Feature feature,
66 unsigned char *value);
68 int chise_char_load_feature_value (CHISE_Char_ID cid,
69 CHISE_Feature feature,
70 CHISE_Value *valdatum);
73 chise_ds_load_char_feature_value (CHISE_DS *ds,
75 const unsigned char *name,
76 CHISE_Value *valdatum)
79 chise_char_load_feature_value (cid, chise_ds_get_feature (ds, name),
84 chise_char_gets_feature_value (CHISE_Char_ID cid,
85 CHISE_Feature feature,
86 unsigned char *dst, size_t size);
89 chise_char_feature_value_iterate (CHISE_Feature feature,
90 int (*func) (CHISE_Char_ID cid,
91 CHISE_Feature feature,
92 CHISE_Value *valdatum));
96 chise_char_feature_str_iterate (CHISE_Feature feature,
97 int (*func) (CHISE_Char_ID cid,
98 CHISE_Feature feature,
103 typedef struct CHISE_CCS_Table CHISE_CCS_Table;
104 typedef CHISE_CCS_Table* CHISE_CCS;
107 chise_ds_get_ccs (CHISE_DS *ds, const unsigned char *name);
109 static inline CHISE_Char_ID
110 chise_ds_decode_char (CHISE_DS *ds,
111 const unsigned char *ccs, int code_point);
113 int chise_ccs_setup_db (CHISE_CCS ccs, int writable);
115 int chise_ccs_sync (CHISE_CCS ccs);
117 int chise_ccs_set_decoded_char (CHISE_CCS ccs,
118 int code_point, CHISE_Char_ID cid);
120 CHISE_Char_ID chise_ccs_decode (CHISE_CCS ccs, int code_point);
122 static inline CHISE_Char_ID
123 chise_ds_decode_char (CHISE_DS *ds,
124 const unsigned char *name, int code_point)
127 chise_ccs_decode (chise_ds_get_ccs (ds, name), code_point);
130 #endif /* !_CHISE_H */