ROW_RES Class Reference

#include <pageres.h>

Inheritance diagram for ROW_RES:

ELIST_LINK List of all members.

Detailed Description

Class for getting row results.

See class_def_ROW_RES

Definition at line 113 of file pageres.h.

Public Member Functions

Public Attributes


Constructor & Destructor Documentation

ROW_RES::ROW_RES (  )  [inline]

Definition at line 138 of file pageres.h.

00138               { 
00139     }                            //empty constructor

ROW_RES::ROW_RES ( ROW the_row  ) 

Constructor for ROW results

Definition at line 78 of file pageres.cpp.

References ASSERT_HOST, bold, char_count, WERD_RES::combination, WERD_RES::copy_on(), FALSE, WERD::flag(), font_class, font_class_score, italic, NULL, WERD_RES::part_of_combo, rej_count, row, TRUE, W_FUZZY_NON, whole_word_rej_count, WERD_RES::word, ROW::word_list(), and word_res_list.

00080                   {
00081   WERD_IT word_it (the_row->word_list ());
00082   WERD_RES_IT word_res_it(&word_res_list); 
00083   WERD_RES *combo = NULL;        //current combination of fuzzies
00084   WERD_RES *word_res;            //current word
00085   WERD *copy_word;
00086 
00087   char_count = 0;
00088   rej_count = 0;
00089   whole_word_rej_count = 0;
00090   font_class = -1;
00091   font_class_score = -1.0;
00092   bold = FALSE;
00093   italic = FALSE;
00094 
00095   row = the_row;
00096 
00097   for (word_it.mark_cycle_pt (); !word_it.cycled_list (); word_it.forward ()) {
00098     word_res = new WERD_RES (word_it.data ());
00099 
00100     if (word_res->word->flag (W_FUZZY_NON)) {
00101       ASSERT_HOST (combo != NULL);
00102       word_res->part_of_combo = TRUE;
00103       combo->copy_on (word_res);
00104     }
00105     if (word_it.data_relative (1)->flag (W_FUZZY_NON)) {
00106       if (combo == NULL) {
00107         copy_word = new WERD;
00108                                  //deep copy
00109         *copy_word = *(word_it.data ());
00110         combo = new WERD_RES (copy_word);
00111         combo->combination = TRUE;
00112         word_res_it.add_to_end (combo);
00113       }
00114       word_res->part_of_combo = TRUE;
00115     }
00116     else
00117       combo = NULL;
00118     word_res_it.add_to_end (word_res);
00119   }
00120 }

ROW_RES::~ROW_RES (  )  [inline]

Definition at line 144 of file pageres.h.

00144                 {                //destructor
00145     }


Member Function Documentation

void ELIST_LINK::de_serialise_asc ( FILE *  f  )  [inherited]

Reimplemented in ICOORDELT.

Definition at line 39 of file elst.cpp.

References ABORT, ERRCODE::error(), and SERIALISE_LINKS.

00040                                            {
00041   SERIALISE_LINKS.error ("ELIST_LINK::de_serialise_asc", ABORT,
00042     "Don't call this, override!");
00043 }

void ELIST_LINK::serialise_asc ( FILE *  f  )  [inherited]

Generates an error, as it should never be called.

Definition at line 32 of file elst.cpp.

References ABORT, ERRCODE::error(), and SERIALISE_LINKS.

00033                                         {
00034   SERIALISE_LINKS.error ("ELIST_LINK::serialise_asc", ABORT,
00035     "Don't call this, override!");
00036 }


Member Data Documentation

INT32 ROW_RES::bold

Definition at line 128 of file pageres.h.

Referenced by font_recognition_pass(), ROW_RES(), and write_shm_text().

INT32 ROW_RES::char_count

Chars in block.

Definition at line 119 of file pageres.h.

Referenced by doc_and_block_rejection(), PAGE_RES_IT::rej_stat_word(), ROW_RES(), and unrej_good_quality_words().

INT8 ROW_RES::font1

primary font

Definition at line 130 of file pageres.h.

Referenced by font_recognition_pass(), and write_shm_text().

INT8 ROW_RES::font1_count

number of voters

Definition at line 132 of file pageres.h.

Referenced by font_recognition_pass(), and write_shm_text().

INT8 ROW_RES::font2

Definition at line 134 of file pageres.h.

Referenced by font_recognition_pass().

INT8 ROW_RES::font2_count

number of voters

Definition at line 136 of file pageres.h.

Referenced by font_recognition_pass().

INT16 ROW_RES::font_class

Definition at line 126 of file pageres.h.

Referenced by ROW_RES().

float ROW_RES::font_class_score

Definition at line 125 of file pageres.h.

Referenced by ROW_RES().

INT32 ROW_RES::italic

Definition at line 127 of file pageres.h.

Referenced by font_recognition_pass(), ROW_RES(), and write_shm_text().

INT32 ROW_RES::rej_count

Rejected chars.

Definition at line 121 of file pageres.h.

Referenced by doc_and_block_rejection(), PAGE_RES_IT::rej_stat_word(), ROW_RES(), and unrej_good_quality_words().

ROW* ROW_RES::row

Real row.

Definition at line 117 of file pageres.h.

Referenced by doc_and_block_rejection(), recog_all_words(), ROW_RES(), unrej_good_quality_words(), and write_shm_text().

INT32 ROW_RES::whole_word_rej_count

rejs in total rej wds

Definition at line 123 of file pageres.h.

Referenced by doc_and_block_rejection(), PAGE_RES_IT::rej_stat_word(), ROW_RES(), and unrej_good_quality_words().

WERD_RES_LIST ROW_RES::word_res_list

Definition at line 124 of file pageres.h.

Referenced by add_in_one_row(), and ROW_RES().


The documentation for this class was generated from the following files:
Generated on Wed Feb 28 19:49:33 2007 for Tesseract by  doxygen 1.5.1