/** @file
 *  @brief Map string to language code
 */
/* Warning: This file is generated by ./languages/collate-sbl - do not modify directly! */
/* Copyright (C) 2007,2012,2013,2015,2025 Olly Betts
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License as
 * published by the Free Software Foundation; either version 2 of the
 * License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, see
 * <https://www.gnu.org/licenses/>.
 */

#ifndef XAPIAN_INCLUDED_SBL_DISPATCH_H
#define XAPIAN_INCLUDED_SBL_DISPATCH_H

enum sbl_code {
    NONE = 0,
    ARABIC = 1,
    ARMENIAN = 2,
    BASQUE = 3,
    CATALAN = 4,
    CZECH = 5,
    DANISH = 6,
    DUTCH = 7,
    DUTCH_PORTER = 8,
    EARLYMODERNENGLISH = 9,
    ENGLISH = 10,
    ESPERANTO = 11,
    ESTONIAN = 12,
    FINNISH = 13,
    FRENCH = 14,
    GERMAN = 15,
    GREEK = 16,
    HINDI = 17,
    HUNGARIAN = 18,
    INDONESIAN = 19,
    IRISH = 20,
    ITALIAN = 21,
    LITHUANIAN = 22,
    LOVINS = 23,
    NEPALI = 24,
    NORWEGIAN = 25,
    PERSIAN = 26,
    POLISH = 27,
    PORTER = 28,
    PORTUGUESE = 29,
    ROMANIAN = 30,
    RUSSIAN = 31,
    SERBIAN = 32,
    SESOTHO = 33,
    SPANISH = 34,
    SWEDISH = 35,
    TAMIL = 36,
    TURKISH = 37,
    YIDDISH = 38
};

static const unsigned char tab[] = {
    18,

    1,0, (369&255),(369>>8), 1,0, (0&255),(0>>8), (163&255),(163>>8), (200&255),(200>>8), (264&255),(264>>8), (70&255),(70>>8),
    (98&255),(98>>8), (129&255),(129>>8), 1,0, (43&255),(43>>8), 1,0, 1,0, (6&255),(6>>8), 1,0,
    1,0, (23&255),(23>>8),

    (1 - 1),
    NONE, 'n','o','n','e',

    (1 - 1),
    DUTCH, 'k','r','a','a','i','j','_','p','o','h','l','m','a','n','n',

    (1 - 1),
    EARLYMODERNENGLISH, 'e','a','r','l','y','m','o','d','e','r','n','e','n','g','l','i','s','h',

    (2 - 1),
    DUTCH_PORTER, 'd','u','t','c','h','_','p','o','r','t','e','r',
    EARLYMODERNENGLISH, 'e','a','r','l','y','e','n','g','l','i','s','h',

    (3 - 1),
    ARMENIAN, 'a','r','m','e','n','i','a','n',
    ESTONIAN, 'e','s','t','o','n','i','a','n',
    ROMANIAN, 'r','o','m','a','n','i','a','n',

    (3 - 1),
    ESPERANTO, 'e','s','p','e','r','a','n','t','o',
    HUNGARIAN, 'h','u','n','g','a','r','i','a','n',
    NORWEGIAN, 'n','o','r','w','e','g','i','a','n',

    (3 - 1),
    INDONESIAN, 'i','n','d','o','n','e','s','i','a','n',
    LITHUANIAN, 'l','i','t','h','u','a','n','i','a','n',
    PORTUGUESE, 'p','o','r','t','u','g','u','e','s','e',

    (6 - 1),
    CZECH, 'c','z','e','c','h',
    DUTCH, 'd','u','t','c','h',
    GREEK, 'g','r','e','e','k',
    HINDI, 'h','i','n','d','i',
    IRISH, 'i','r','i','s','h',
    TAMIL, 't','a','m','i','l',

    (9 - 1),
    ARABIC, 'a','r','a','b','i','c',
    BASQUE, 'b','a','s','q','u','e',
    DANISH, 'd','a','n','i','s','h',
    FRENCH, 'f','r','e','n','c','h',
    GERMAN, 'g','e','r','m','a','n',
    LOVINS, 'l','o','v','i','n','s',
    NEPALI, 'n','e','p','a','l','i',
    POLISH, 'p','o','l','i','s','h',
    PORTER, 'p','o','r','t','e','r',

    (13 - 1),
    CATALAN, 'c','a','t','a','l','a','n',
    ENGLISH, 'e','n','g','l','i','s','h',
    FINNISH, 'f','i','n','n','i','s','h',
    GERMAN, 'g','e','r','m','a','n','2',
    ITALIAN, 'i','t','a','l','i','a','n',
    PERSIAN, 'p','e','r','s','i','a','n',
    RUSSIAN, 'r','u','s','s','i','a','n',
    SERBIAN, 's','e','r','b','i','a','n',
    SESOTHO, 's','e','s','o','t','h','o',
    SPANISH, 's','p','a','n','i','s','h',
    SWEDISH, 's','w','e','d','i','s','h',
    TURKISH, 't','u','r','k','i','s','h',
    YIDDISH, 'y','i','d','d','i','s','h',

    (36 - 1),
    ARABIC, 'a','r',
    CATALAN, 'c','a',
    CZECH, 'c','s',
    DANISH, 'd','a',
    GERMAN, 'd','e',
    GREEK, 'e','l',
    ENGLISH, 'e','n',
    ESPERANTO, 'e','o',
    SPANISH, 'e','s',
    ESTONIAN, 'e','t',
    BASQUE, 'e','u',
    PERSIAN, 'f','a',
    FINNISH, 'f','i',
    FRENCH, 'f','r',
    IRISH, 'g','a',
    HINDI, 'h','i',
    HUNGARIAN, 'h','u',
    ARMENIAN, 'h','y',
    INDONESIAN, 'i','d',
    ITALIAN, 'i','t',
    LITHUANIAN, 'l','t',
    NORWEGIAN, 'n','b',
    NEPALI, 'n','e',
    DUTCH, 'n','l',
    NORWEGIAN, 'n','n',
    NORWEGIAN, 'n','o',
    POLISH, 'p','l',
    PORTUGUESE, 'p','t',
    ROMANIAN, 'r','o',
    RUSSIAN, 'r','u',
    SERBIAN, 's','r',
    SESOTHO, 's','t',
    SWEDISH, 's','v',
    TAMIL, 't','a',
    TURKISH, 't','r',
    YIDDISH, 'y','i'
};

#define SNOWBALL_DISPATCH \
    case ARABIC: internal = new Xapian::Internal::Snowball::Arabic; return; \
    case ARMENIAN: internal = new Xapian::Internal::Snowball::Armenian; return; \
    case BASQUE: internal = new Xapian::Internal::Snowball::Basque; return; \
    case CATALAN: internal = new Xapian::Internal::Snowball::Catalan; return; \
    case CZECH: internal = new Xapian::Internal::Snowball::Czech; return; \
    case DANISH: internal = new Xapian::Internal::Snowball::Danish; return; \
    case DUTCH: internal = new Xapian::Internal::Snowball::Dutch; return; \
    case DUTCH_PORTER: internal = new Xapian::Internal::Snowball::DutchPorter; return; \
    case EARLYMODERNENGLISH: internal = new Xapian::Internal::Snowball::Earlymodernenglish; return; \
    case ENGLISH: internal = new Xapian::Internal::Snowball::English; return; \
    case ESPERANTO: internal = new Xapian::Internal::Snowball::Esperanto; return; \
    case ESTONIAN: internal = new Xapian::Internal::Snowball::Estonian; return; \
    case FINNISH: internal = new Xapian::Internal::Snowball::Finnish; return; \
    case FRENCH: internal = new Xapian::Internal::Snowball::French; return; \
    case GERMAN: internal = new Xapian::Internal::Snowball::German; return; \
    case GREEK: internal = new Xapian::Internal::Snowball::Greek; return; \
    case HINDI: internal = new Xapian::Internal::Snowball::Hindi; return; \
    case HUNGARIAN: internal = new Xapian::Internal::Snowball::Hungarian; return; \
    case INDONESIAN: internal = new Xapian::Internal::Snowball::Indonesian; return; \
    case IRISH: internal = new Xapian::Internal::Snowball::Irish; return; \
    case ITALIAN: internal = new Xapian::Internal::Snowball::Italian; return; \
    case LITHUANIAN: internal = new Xapian::Internal::Snowball::Lithuanian; return; \
    case LOVINS: internal = new Xapian::Internal::Snowball::Lovins; return; \
    case NEPALI: internal = new Xapian::Internal::Snowball::Nepali; return; \
    case NORWEGIAN: internal = new Xapian::Internal::Snowball::Norwegian; return; \
    case PERSIAN: internal = new Xapian::Internal::Snowball::Persian; return; \
    case POLISH: internal = new Xapian::Internal::Snowball::Polish; return; \
    case PORTER: internal = new Xapian::Internal::Snowball::Porter; return; \
    case PORTUGUESE: internal = new Xapian::Internal::Snowball::Portuguese; return; \
    case ROMANIAN: internal = new Xapian::Internal::Snowball::Romanian; return; \
    case RUSSIAN: internal = new Xapian::Internal::Snowball::Russian; return; \
    case SERBIAN: internal = new Xapian::Internal::Snowball::Serbian; return; \
    case SESOTHO: internal = new Xapian::Internal::Snowball::Sesotho; return; \
    case SPANISH: internal = new Xapian::Internal::Snowball::Spanish; return; \
    case SWEDISH: internal = new Xapian::Internal::Snowball::Swedish; return; \
    case TAMIL: internal = new Xapian::Internal::Snowball::Tamil; return; \
    case TURKISH: internal = new Xapian::Internal::Snowball::Turkish; return; \
    case YIDDISH: internal = new Xapian::Internal::Snowball::Yiddish; return; \
    case NONE: return;

#define LANGSTRING "arabic armenian basque catalan czech danish dutch dutch_porter earlymodernenglish english esperanto estonian finnish french german greek hindi hungarian indonesian irish italian lithuanian lovins nepali norwegian persian polish porter portuguese romanian russian serbian sesotho spanish swedish tamil turkish yiddish"

#endif
