michael@0: /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #include "nsSBCharSetProber.h" michael@0: michael@0: michael@0: michael@0: //KOI8-R language model michael@0: //Character Mapping Table: michael@0: static const unsigned char KOI8R_CharToOrderMap[] = michael@0: { michael@0: 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 michael@0: 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 michael@0: +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 michael@0: 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 michael@0: 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 michael@0: 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 michael@0: 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 michael@0: 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 michael@0: 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, //80 michael@0: 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, //90 michael@0: 223,224,225, 68,226,227,228,229,230,231,232,233,234,235,236,237, //a0 michael@0: 238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253, //b0 michael@0: 27, 3, 21, 28, 13, 2, 39, 19, 26, 4, 23, 11, 8, 12, 5, 1, //c0 michael@0: 15, 16, 9, 7, 6, 14, 24, 10, 17, 18, 20, 25, 30, 29, 22, 54, //d0 michael@0: 59, 37, 44, 58, 41, 48, 53, 46, 55, 42, 60, 36, 49, 38, 31, 34, //e0 michael@0: 35, 43, 45, 32, 40, 52, 56, 33, 61, 62, 51, 57, 47, 63, 50, 70, //f0 michael@0: }; michael@0: michael@0: static const unsigned char win1251_CharToOrderMap[] = michael@0: { michael@0: 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 michael@0: 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 michael@0: +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 michael@0: 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 michael@0: 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 michael@0: 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 michael@0: 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 michael@0: 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 michael@0: 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, michael@0: 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, michael@0: 223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238, michael@0: 239,240,241,242,243,244,245,246, 68,247,248,249,250,251,252,253, michael@0: 37, 44, 33, 46, 41, 48, 56, 51, 42, 60, 36, 49, 38, 31, 34, 35, michael@0: 45, 32, 40, 52, 53, 55, 58, 50, 57, 63, 70, 62, 61, 47, 59, 43, michael@0: 3, 21, 10, 19, 13, 2, 24, 20, 4, 23, 11, 8, 12, 5, 1, 15, michael@0: 9, 7, 6, 14, 39, 26, 28, 22, 25, 29, 54, 18, 17, 30, 27, 16, michael@0: }; michael@0: michael@0: static const unsigned char latin5_CharToOrderMap[] = michael@0: { michael@0: 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 michael@0: 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 michael@0: +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 michael@0: 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 michael@0: 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 michael@0: 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 michael@0: 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 michael@0: 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 michael@0: 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, michael@0: 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, michael@0: 223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238, michael@0: 37, 44, 33, 46, 41, 48, 56, 51, 42, 60, 36, 49, 38, 31, 34, 35, michael@0: 45, 32, 40, 52, 53, 55, 58, 50, 57, 63, 70, 62, 61, 47, 59, 43, michael@0: 3, 21, 10, 19, 13, 2, 24, 20, 4, 23, 11, 8, 12, 5, 1, 15, michael@0: 9, 7, 6, 14, 39, 26, 28, 22, 25, 29, 54, 18, 17, 30, 27, 16, michael@0: 239, 68,240,241,242,243,244,245,246,247,248,249,250,251,252,255, michael@0: }; michael@0: michael@0: static const unsigned char macCyrillic_CharToOrderMap[] = michael@0: { michael@0: 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 michael@0: 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 michael@0: +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 michael@0: 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 michael@0: 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 michael@0: 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 michael@0: 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 michael@0: 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 michael@0: 37, 44, 33, 46, 41, 48, 56, 51, 42, 60, 36, 49, 38, 31, 34, 35, michael@0: 45, 32, 40, 52, 53, 55, 58, 50, 57, 63, 70, 62, 61, 47, 59, 43, michael@0: 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, michael@0: 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, michael@0: 223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238, michael@0: 239,240,241,242,243,244,245,246,247,248,249,250,251,252, 68, 16, michael@0: 3, 21, 10, 19, 13, 2, 24, 20, 4, 23, 11, 8, 12, 5, 1, 15, michael@0: 9, 7, 6, 14, 39, 26, 28, 22, 25, 29, 54, 18, 17, 30, 27,255, michael@0: }; michael@0: michael@0: static const unsigned char IBM855_CharToOrderMap[] = michael@0: { michael@0: 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 michael@0: 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 michael@0: +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 michael@0: 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 michael@0: 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 michael@0: 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 michael@0: 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 michael@0: 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 michael@0: 191,192,193,194, 68,195,196,197,198,199,200,201,202,203,204,205, michael@0: 206,207,208,209,210,211,212,213,214,215,216,217, 27, 59, 54, 70, michael@0: 3, 37, 21, 44, 28, 58, 13, 41, 2, 48, 39, 53, 19, 46,218,219, michael@0: 220,221,222,223,224, 26, 55, 4, 42,225,226,227,228, 23, 60,229, michael@0: 230,231,232,233,234,235, 11, 36,236,237,238,239,240,241,242,243, michael@0: 8, 49, 12, 38, 5, 31, 1, 34, 15,244,245,246,247, 35, 16,248, michael@0: 43, 9, 45, 7, 32, 6, 40, 14, 52, 24, 56, 10, 33, 17, 61,249, michael@0: 250, 18, 62, 20, 51, 25, 57, 30, 47, 29, 63, 22, 50,251,252,255, michael@0: }; michael@0: michael@0: static const unsigned char IBM866_CharToOrderMap[] = michael@0: { michael@0: 255,255,255,255,255,255,255,255,255,255,254,255,255,254,255,255, //00 michael@0: 255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255, //10 michael@0: +253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, //20 michael@0: 252,252,252,252,252,252,252,252,252,252,253,253,253,253,253,253, //30 michael@0: 253,142,143,144,145,146,147,148,149,150,151,152, 74,153, 75,154, //40 michael@0: 155,156,157,158,159,160,161,162,163,164,165,253,253,253,253,253, //50 michael@0: 253, 71,172, 66,173, 65,174, 76,175, 64,176,177, 77, 72,178, 69, //60 michael@0: 67,179, 78, 73,180,181, 79,182,183,184,185,253,253,253,253,253, //70 michael@0: 37, 44, 33, 46, 41, 48, 56, 51, 42, 60, 36, 49, 38, 31, 34, 35, michael@0: 45, 32, 40, 52, 53, 55, 58, 50, 57, 63, 70, 62, 61, 47, 59, 43, michael@0: 3, 21, 10, 19, 13, 2, 24, 20, 4, 23, 11, 8, 12, 5, 1, 15, michael@0: 191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206, michael@0: 207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222, michael@0: 223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238, michael@0: 9, 7, 6, 14, 39, 26, 28, 22, 25, 29, 54, 18, 17, 30, 27, 16, michael@0: 239, 68,240,241,242,243,244,245,246,247,248,249,250,251,252,255, michael@0: }; michael@0: michael@0: //Model Table: michael@0: //total sequences: 100% michael@0: //first 512 sequences: 97.6601% michael@0: //first 1024 sequences: 2.3389% michael@0: //rest sequences: 0.1237% michael@0: //negative sequences: 0.0009% michael@0: static const uint8_t RussianLangModel[] = michael@0: { michael@0: 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, michael@0: 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, michael@0: 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, michael@0: 0,0,0,0,0,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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, michael@0: 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, michael@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,0,0,0,0,0,0,1, michael@0: 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, michael@0: 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, michael@0: 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, michael@0: 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, michael@0: 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, michael@0: }; michael@0: michael@0: michael@0: const SequenceModel Koi8rModel = michael@0: { michael@0: KOI8R_CharToOrderMap, michael@0: RussianLangModel, michael@0: (float)0.976601, michael@0: false, michael@0: "KOI8-R" michael@0: }; michael@0: michael@0: const SequenceModel Win1251Model = michael@0: { michael@0: win1251_CharToOrderMap, michael@0: RussianLangModel, michael@0: (float)0.976601, michael@0: false, michael@0: "windows-1251" michael@0: }; michael@0: michael@0: const SequenceModel Latin5Model = michael@0: { michael@0: latin5_CharToOrderMap, michael@0: RussianLangModel, michael@0: (float)0.976601, michael@0: false, michael@0: "ISO-8859-5" michael@0: }; michael@0: michael@0: const SequenceModel MacCyrillicModel = michael@0: { michael@0: macCyrillic_CharToOrderMap, michael@0: RussianLangModel, michael@0: (float)0.976601, michael@0: false, michael@0: "x-mac-cyrillic" michael@0: }; michael@0: michael@0: const SequenceModel Ibm866Model = michael@0: { michael@0: IBM866_CharToOrderMap, michael@0: RussianLangModel, michael@0: (float)0.976601, michael@0: false, michael@0: "IBM866" michael@0: }; michael@0: michael@0: const SequenceModel Ibm855Model = michael@0: { michael@0: IBM855_CharToOrderMap, michael@0: RussianLangModel, michael@0: (float)0.976601, michael@0: false, michael@0: "IBM855" michael@0: };