File indexing completed on 2024-06-02 04:53:36
0001 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 0002 /* ***** BEGIN LICENSE BLOCK ***** 0003 * Version: MPL 1.1/GPL 2.0/LGPL 2.1 0004 * 0005 * The contents of this file are subject to the Mozilla Public License Version 0006 * 1.1 (the "License"); you may not use this file except in compliance with 0007 * the License. You may obtain a copy of the License at 0008 * http://www.mozilla.org/MPL/ 0009 * 0010 * Software distributed under the License is distributed on an "AS IS" basis, 0011 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License 0012 * for the specific language governing rights and limitations under the 0013 * License. 0014 * 0015 * The Original Code is Mozilla Communicator client code. 0016 * 0017 * The Initial Developer of the Original Code is 0018 * Netscape Communications Corporation. 0019 * Portions created by the Initial Developer are Copyright (C) 1998 0020 * the Initial Developer. All Rights Reserved. 0021 * 0022 * Contributor(s): 0023 * 0024 * Alternatively, the contents of this file may be used under the terms of 0025 * either the GNU General Public License Version 2 or later (the "GPL"), or 0026 * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), 0027 * in which case the provisions of the GPL or the LGPL are applicable instead 0028 * of those above. If you wish to allow use of your version of this file only 0029 * under the terms of either the GPL or the LGPL, and not to allow others to 0030 * use your version of this file under the terms of the MPL, indicate your 0031 * decision by deleting the provisions above and replace them with the notice 0032 * and other provisions required by the GPL or the LGPL. If you do not delete 0033 * the provisions above, a recipient may use your version of this file under 0034 * the terms of any one of the MPL, the GPL or the LGPL. 0035 * 0036 * ***** END LICENSE BLOCK ***** */ 0037 0038 #pragma GCC visibility push(hidden) 0039 0040 #include "nsSBCharSetProber.h" 0041 0042 0043 0044 //KOI8-R language model 0045 //Character Mapping Table: 0046 unsigned char KOI8R_CharToOrderMap[] = 0047 { 0048 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 0049 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 0050 +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 0051 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 0052 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 0053 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 0054 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 0055 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 0056 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, //80 0057 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, //90 0058 223,224,225, 68,226,227,228,229,230,231,232,233,234,235,236,237, //a0 0059 238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253, //b0 0060 27, 3, 21, 28, 13, 2, 39, 19, 26, 4, 23, 11, 8, 12, 5, 1, //c0 0061 15, 16, 9, 7, 6, 14, 24, 10, 17, 18, 20, 25, 30, 29, 22, 54, //d0 0062 59, 37, 44, 58, 41, 48, 53, 46, 55, 42, 60, 36, 49, 38, 31, 34, //e0 0063 35, 43, 45, 32, 40, 52, 56, 33, 61, 62, 51, 57, 47, 63, 50, 70, //f0 0064 }; 0065 0066 unsigned char win1251_CharToOrderMap[] = 0067 { 0068 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 0069 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 0070 +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 0071 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 0072 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 0073 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 0074 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 0075 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 0076 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, 0077 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, 0078 223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238, 0079 239,240,241,242,243,244,245,246, 68,247,248,249,250,251,252,253, 0080 37, 44, 33, 46, 41, 48, 56, 51, 42, 60, 36, 49, 38, 31, 34, 35, 0081 45, 32, 40, 52, 53, 55, 58, 50, 57, 63, 70, 62, 61, 47, 59, 43, 0082 3, 21, 10, 19, 13, 2, 24, 20, 4, 23, 11, 8, 12, 5, 1, 15, 0083 9, 7, 6, 14, 39, 26, 28, 22, 25, 29, 54, 18, 17, 30, 27, 16, 0084 }; 0085 0086 unsigned char latin5_CharToOrderMap[] = 0087 { 0088 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 0089 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 0090 +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 0091 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 0092 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 0093 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 0094 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 0095 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 0096 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, 0097 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, 0098 223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238, 0099 37, 44, 33, 46, 41, 48, 56, 51, 42, 60, 36, 49, 38, 31, 34, 35, 0100 45, 32, 40, 52, 53, 55, 58, 50, 57, 63, 70, 62, 61, 47, 59, 43, 0101 3, 21, 10, 19, 13, 2, 24, 20, 4, 23, 11, 8, 12, 5, 1, 15, 0102 9, 7, 6, 14, 39, 26, 28, 22, 25, 29, 54, 18, 17, 30, 27, 16, 0103 239, 68,240,241,242,243,244,245,246,247,248,249,250,251,252,255, 0104 }; 0105 0106 unsigned char macCyrillic_CharToOrderMap[] = 0107 { 0108 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 0109 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 0110 +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 0111 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 0112 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 0113 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 0114 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 0115 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 0116 37, 44, 33, 46, 41, 48, 56, 51, 42, 60, 36, 49, 38, 31, 34, 35, 0117 45, 32, 40, 52, 53, 55, 58, 50, 57, 63, 70, 62, 61, 47, 59, 43, 0118 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, 0119 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, 0120 223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238, 0121 239,240,241,242,243,244,245,246,247,248,249,250,251,252, 68, 16, 0122 3, 21, 10, 19, 13, 2, 24, 20, 4, 23, 11, 8, 12, 5, 1, 15, 0123 9, 7, 6, 14, 39, 26, 28, 22, 25, 29, 54, 18, 17, 30, 27,255, 0124 }; 0125 0126 unsigned char IBM855_CharToOrderMap[] = 0127 { 0128 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 0129 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 0130 +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 0131 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 0132 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 0133 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 0134 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 0135 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 0136 191,192,193,194, 68,195,196,197,198,199,200,201,202,203,204,205, 0137 206,207,208,209,210,211,212,213,214,215,216,217, 27, 59, 54, 70, 0138 3, 37, 21, 44, 28, 58, 13, 41, 2, 48, 39, 53, 19, 46,218,219, 0139 220,221,222,223,224, 26, 55, 4, 42,225,226,227,228, 23, 60,229, 0140 230,231,232,233,234,235, 11, 36,236,237,238,239,240,241,242,243, 0141 8, 49, 12, 38, 5, 31, 1, 34, 15,244,245,246,247, 35, 16,248, 0142 43, 9, 45, 7, 32, 6, 40, 14, 52, 24, 56, 10, 33, 17, 61,249, 0143 250, 18, 62, 20, 51, 25, 57, 30, 47, 29, 63, 22, 50,251,252,255, 0144 }; 0145 0146 unsigned char IBM866_CharToOrderMap[] = 0147 { 0148 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 0149 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 0150 +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 0151 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 0152 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 0153 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 0154 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 0155 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 0156 37, 44, 33, 46, 41, 48, 56, 51, 42, 60, 36, 49, 38, 31, 34, 35, 0157 45, 32, 40, 52, 53, 55, 58, 50, 57, 63, 70, 62, 61, 47, 59, 43, 0158 3, 21, 10, 19, 13, 2, 24, 20, 4, 23, 11, 8, 12, 5, 1, 15, 0159 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, 0160 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, 0161 223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238, 0162 9, 7, 6, 14, 39, 26, 28, 22, 25, 29, 54, 18, 17, 30, 27, 16, 0163 239, 68,240,241,242,243,244,245,246,247,248,249,250,251,252,255, 0164 }; 0165 0166 //Model Table: 0167 //total sequences: 100% 0168 //first 512 sequences: 97.6601% 0169 //first 1024 sequences: 2.3389% 0170 //rest sequences: 0.1237% 0171 //negative sequences: 0.0009% 0172 char RussianLangModel[] = 0173 { 0174 0,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,1,1,3,3,3,3,1,3,3,3,2,3,2,3,3, 0175 3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,0,3,2,2,2,2,2,0,0,2, 0176 3,3,3,2,3,3,3,3,3,3,3,3,3,3,2,3,3,0,0,3,3,3,3,3,3,3,3,3,2,3,2,0, 0177 0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0178 3,3,3,2,2,3,3,3,3,3,3,3,3,3,2,3,3,0,0,3,3,3,3,3,3,3,3,2,3,3,1,0, 0179 0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0180 3,2,3,2,3,3,3,3,3,3,3,3,3,3,3,3,3,0,0,3,3,3,3,3,3,3,3,3,3,3,2,1, 0181 0,0,0,0,0,0,0,2,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0182 3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,3,3,0,0,3,3,3,3,3,3,3,3,3,3,3,2,1, 0183 0,0,0,0,0,1,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0184 3,3,3,3,3,3,3,3,2,2,2,3,1,3,3,1,3,3,3,3,2,2,3,0,2,2,2,3,3,2,1,0, 0185 0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0, 0186 3,3,3,3,3,3,2,3,3,3,3,3,2,2,3,2,3,3,3,2,1,2,2,0,1,2,2,2,2,2,2,0, 0187 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0,1,0,0,0,1,0,1,0,0,1,0,1,0,0,0,0,1, 0293 0,0,0,0,0,1,0,0,1,1,0,0,1,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1, 0294 2,2,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1, 0295 1,0,0,0,1,0,0,0,1,1,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,1,0,0,0,0,0, 0296 2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1, 0297 1,1,1,0,1,0,1,0,0,1,1,1,1,0,0,0,1,0,0,0,0,1,0,0,0,1,0,1,0,0,0,0, 0298 1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1, 0299 1,1,0,1,1,0,1,0,1,0,0,0,0,1,1,0,1,1,0,0,0,0,0,1,0,1,1,0,1,0,0,0, 0300 0,1,1,1,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0301 0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0, 0302 }; 0303 0304 0305 SequenceModel Koi8rModel = 0306 { 0307 KOI8R_CharToOrderMap, 0308 RussianLangModel, 0309 (float)0.976601, 0310 PR_FALSE, 0311 "KOI8-R" 0312 }; 0313 0314 SequenceModel Win1251Model = 0315 { 0316 win1251_CharToOrderMap, 0317 RussianLangModel, 0318 (float)0.976601, 0319 PR_FALSE, 0320 "windows-1251" 0321 }; 0322 0323 SequenceModel Latin5Model = 0324 { 0325 latin5_CharToOrderMap, 0326 RussianLangModel, 0327 (float)0.976601, 0328 PR_FALSE, 0329 "ISO-8859-5" 0330 }; 0331 0332 SequenceModel MacCyrillicModel = 0333 { 0334 macCyrillic_CharToOrderMap, 0335 RussianLangModel, 0336 (float)0.976601, 0337 PR_FALSE, 0338 "x-mac-cyrillic" 0339 }; 0340 0341 SequenceModel Ibm866Model = 0342 { 0343 IBM866_CharToOrderMap, 0344 RussianLangModel, 0345 (float)0.976601, 0346 PR_FALSE, 0347 "IBM866" 0348 }; 0349 0350 SequenceModel Ibm855Model = 0351 { 0352 IBM855_CharToOrderMap, 0353 RussianLangModel, 0354 (float)0.976601, 0355 PR_FALSE, 0356 "IBM855" 0357 }; 0358 0359 #pragma GCC visibility pop 0360