All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
ADAPT_RESULTS Struct Reference

Public Member Functions

void Initialize ()
 
void ComputeBest ()
 

Public Attributes

inT32 BlobLength
 
bool HasNonfragment
 
UNICHAR_ID best_unichar_id
 
int best_match_index
 
FLOAT32 best_rating
 
GenericVector< UnicharRatingmatch
 
GenericVector< CP_RESULT_STRUCTCPResults
 

Detailed Description

Definition at line 82 of file adaptmatch.cpp.

Member Function Documentation

void ADAPT_RESULTS::ComputeBest ( )
inline

Definition at line 99 of file adaptmatch.cpp.

99  {
100  best_unichar_id = INVALID_UNICHAR_ID;
101  best_match_index = -1;
103  for (int i = 0; i < match.size(); ++i) {
104  if (match[i].rating > best_rating) {
105  best_rating = match[i].rating;
106  best_unichar_id = match[i].unichar_id;
107  best_match_index = i;
108  }
109  }
110  }
int size() const
Definition: genericvector.h:72
GenericVector< UnicharRating > match
Definition: adaptmatch.cpp:88
UNICHAR_ID best_unichar_id
Definition: adaptmatch.cpp:85
int best_match_index
Definition: adaptmatch.cpp:86
FLOAT32 best_rating
Definition: adaptmatch.cpp:87
#define WORST_POSSIBLE_RATING
Definition: adaptmatch.cpp:77
void ADAPT_RESULTS::Initialize ( )
inline

Initializes data members to the default values. Sets the initial rating of each class to be the worst possible rating (1.0).

Definition at line 93 of file adaptmatch.cpp.

93  {
95  HasNonfragment = false;
96  ComputeBest();
97  }
inT32 BlobLength
Definition: adaptmatch.cpp:83
void ComputeBest()
Definition: adaptmatch.cpp:99
bool HasNonfragment
Definition: adaptmatch.cpp:84
#define MAX_INT32
Definition: host.h:120

Member Data Documentation

int ADAPT_RESULTS::best_match_index

Definition at line 86 of file adaptmatch.cpp.

FLOAT32 ADAPT_RESULTS::best_rating

Definition at line 87 of file adaptmatch.cpp.

UNICHAR_ID ADAPT_RESULTS::best_unichar_id

Definition at line 85 of file adaptmatch.cpp.

inT32 ADAPT_RESULTS::BlobLength

Definition at line 83 of file adaptmatch.cpp.

GenericVector<CP_RESULT_STRUCT> ADAPT_RESULTS::CPResults

Definition at line 89 of file adaptmatch.cpp.

bool ADAPT_RESULTS::HasNonfragment

Definition at line 84 of file adaptmatch.cpp.

GenericVector<UnicharRating> ADAPT_RESULTS::match

Definition at line 88 of file adaptmatch.cpp.


The documentation for this struct was generated from the following file: