(linenum→info "unix/slp.c:2238")

anthy/9100e/anthy/convdb.h

    1: /* 変換結果のデータベース */
    2: #ifndef _convdb_h_included_
    3: #define _convdb_h_included_
    4: 
    5: #include <anthy/anthy.h>
    6: 
    7: /* 不明, OK, 誤変換, don't careの4つのカテゴリーに分類する */
    8: #define CHK_UNKNOWN 0
    9: #define CHK_OK 1
   10: #define CHK_MISS 2
   11: #define CHK_DONTCARE 3
   12: 
   13: /**/
   14: #define CONV_OK 0
   15: #define CONV_SIZE_MISS 1
   16: #define CONV_CAND_MISS 2
   17: #define CONV_INVALID 4
   18: 
   19: /* 変換前と変換後の文字列、結果に対する判定を格納する */
   20: struct conv_res {
   21:   /* 検索のキー */
   22:   char *src_str;
   23:   char *res_str;
   24:   /* 候補を割り当てたもの */
   25:   char *cand_str;
   26:   /**/
   27:   int *cand_check;
   28:   /**/
   29:   int check;
   30:   int used;
   31:   /**/
   32:   struct conv_res *next;
   33: };
   34: 
   35: /* 変換結果のカウント */
   36: struct res_stat {
   37:   int unknown;
   38:   int ok;
   39:   int miss;
   40:   int dontcare;
   41: };
   42: 
   43: /* 変換結果のデータベース */
   44: struct res_db {
   45:   /**/
   46:   struct conv_res res_list;
   47:   struct conv_res *tail;
   48:   /**/
   49:   int total;
   50:   struct res_stat res, split;
   51: };
   52: 
   53: struct res_db *create_db(void);
   54: void read_db(struct res_db *db, const char *fn);
   55: struct conv_res *find_conv_res(struct res_db *db, anthy_context_t ac,
   56:                                const char *src, int conv);
   57: void print_size_miss_segment_info(anthy_context_t ac, int nth);
   58: void print_cand_miss_segment_info(anthy_context_t ac, int nth);
   59: void print_context_info(anthy_context_t ac, struct conv_res *cr);
   60: 
   61: #endif
Syntax (Markdown)