00001 00002 // File: conversion.h 00003 // Description: Collection of utility functions for A_CHOICE conversions. 00004 // TODO(daria): delete this file when conversion to unichar_ids 00005 // is finished and all permuters are completely updated/replaced. 00006 // Author: Daria Antonova 00007 // Created: Mon Jun 23 11:26:43 PDT 2008 00008 // 00009 // (C) Copyright 2007, Google Inc. 00010 // Licensed under the Apache License, Version 2.0 (the "License"); 00011 // you may not use this file except in compliance with the License. 00012 // You may obtain a copy of the License at 00013 // http://www.apache.org/licenses/LICENSE-2.0 00014 // Unless required by applicable law or agreed to in writing, software 00015 // distributed under the License is distributed on an "AS IS" BASIS, 00016 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00017 // See the License for the specific language governing permissions and 00018 // limitations under the License. 00019 // 00021 00022 #ifndef TESSERACT_DICT_CONVERSION_H_ 00023 #define TESSERACT_DICT_CONVERSION_H_ 00024 00025 #include "choicearr.h" 00026 #include "choices.h" 00027 #include "ratngs.h" 00028 #include "unicharset.h" 00029 00030 void convert_to_word_choice(const A_CHOICE *a_choice, 00031 const UNICHARSET ¤t_unicharset, 00032 WERD_CHOICE *word_choice); 00033 00034 WERD_CHOICE *get_best_delete_other( 00035 const UNICHARSET ¤t_unicharset, 00036 WERD_CHOICE *choice, 00037 A_CHOICE *a_choice); 00038 00039 CHOICES_LIST convert_to_choices_list( 00040 const BLOB_CHOICE_LIST_VECTOR &char_choices, 00041 const UNICHARSET ¤t_unicharset); 00042 00043 #endif // TESSERACT_DICT_CONVERSION_H_