⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 finnishstemmer.java

📁 lucene2.2.0版本
💻 JAVA
📖 第 1 页 / 共 3 页
字号:
// This file was generated automatically by the Snowball to Java compilerpackage net.sf.snowball.ext;import net.sf.snowball.SnowballProgram;import net.sf.snowball.Among;/** * Generated class implementing code defined by a snowball script. */public class FinnishStemmer extends SnowballProgram {        private Among a_0[] = {            new Among ( "pa", -1, 1, "", this),            new Among ( "sti", -1, 2, "", this),            new Among ( "kaan", -1, 1, "", this),            new Among ( "han", -1, 1, "", this),            new Among ( "kin", -1, 1, "", this),            new Among ( "h\u00E4n", -1, 1, "", this),            new Among ( "k\u00E4\u00E4n", -1, 1, "", this),            new Among ( "ko", -1, 1, "", this),            new Among ( "p\u00E4", -1, 1, "", this),            new Among ( "k\u00F6", -1, 1, "", this)        };        private Among a_1[] = {            new Among ( "lla", -1, -1, "", this),            new Among ( "na", -1, -1, "", this),            new Among ( "ssa", -1, -1, "", this),            new Among ( "ta", -1, -1, "", this),            new Among ( "lta", 3, -1, "", this),            new Among ( "sta", 3, -1, "", this)        };        private Among a_2[] = {            new Among ( "ll\u00E4", -1, -1, "", this),            new Among ( "n\u00E4", -1, -1, "", this),            new Among ( "ss\u00E4", -1, -1, "", this),            new Among ( "t\u00E4", -1, -1, "", this),            new Among ( "lt\u00E4", 3, -1, "", this),            new Among ( "st\u00E4", 3, -1, "", this)        };        private Among a_3[] = {            new Among ( "lle", -1, -1, "", this),            new Among ( "ine", -1, -1, "", this)        };        private Among a_4[] = {            new Among ( "nsa", -1, 3, "", this),            new Among ( "mme", -1, 3, "", this),            new Among ( "nne", -1, 3, "", this),            new Among ( "ni", -1, 2, "", this),            new Among ( "si", -1, 1, "", this),            new Among ( "an", -1, 4, "", this),            new Among ( "en", -1, 6, "", this),            new Among ( "\u00E4n", -1, 5, "", this),            new Among ( "ns\u00E4", -1, 3, "", this)        };        private Among a_5[] = {            new Among ( "aa", -1, -1, "", this),            new Among ( "ee", -1, -1, "", this),            new Among ( "ii", -1, -1, "", this),            new Among ( "oo", -1, -1, "", this),            new Among ( "uu", -1, -1, "", this),            new Among ( "\u00E4\u00E4", -1, -1, "", this),            new Among ( "\u00F6\u00F6", -1, -1, "", this)        };        private Among a_6[] = {            new Among ( "a", -1, 8, "", this),            new Among ( "lla", 0, -1, "", this),            new Among ( "na", 0, -1, "", this),            new Among ( "ssa", 0, -1, "", this),            new Among ( "ta", 0, -1, "", this),            new Among ( "lta", 4, -1, "", this),            new Among ( "sta", 4, -1, "", this),            new Among ( "tta", 4, 9, "", this),            new Among ( "lle", -1, -1, "", this),            new Among ( "ine", -1, -1, "", this),            new Among ( "ksi", -1, -1, "", this),            new Among ( "n", -1, 7, "", this),            new Among ( "han", 11, 1, "", this),            new Among ( "den", 11, -1, "r_VI", this),            new Among ( "seen", 11, -1, "r_LONG", this),            new Among ( "hen", 11, 2, "", this),            new Among ( "tten", 11, -1, "r_VI", this),            new Among ( "hin", 11, 3, "", this),            new Among ( "siin", 11, -1, "r_VI", this),            new Among ( "hon", 11, 4, "", this),            new Among ( "h\u00E4n", 11, 5, "", this),            new Among ( "h\u00F6n", 11, 6, "", this),            new Among ( "\u00E4", -1, 8, "", this),            new Among ( "ll\u00E4", 22, -1, "", this),            new Among ( "n\u00E4", 22, -1, "", this),            new Among ( "ss\u00E4", 22, -1, "", this),            new Among ( "t\u00E4", 22, -1, "", this),            new Among ( "lt\u00E4", 26, -1, "", this),            new Among ( "st\u00E4", 26, -1, "", this),            new Among ( "tt\u00E4", 26, 9, "", this)        };        private Among a_7[] = {            new Among ( "eja", -1, -1, "", this),            new Among ( "mma", -1, 1, "", this),            new Among ( "imma", 1, -1, "", this),            new Among ( "mpa", -1, 1, "", this),            new Among ( "impa", 3, -1, "", this),            new Among ( "mmi", -1, 1, "", this),            new Among ( "immi", 5, -1, "", this),            new Among ( "mpi", -1, 1, "", this),            new Among ( "impi", 7, -1, "", this),            new Among ( "ej\u00E4", -1, -1, "", this),            new Among ( "mm\u00E4", -1, 1, "", this),            new Among ( "imm\u00E4", 10, -1, "", this),            new Among ( "mp\u00E4", -1, 1, "", this),            new Among ( "imp\u00E4", 12, -1, "", this)        };        private Among a_8[] = {            new Among ( "i", -1, -1, "", this),            new Among ( "j", -1, -1, "", this)        };        private Among a_9[] = {            new Among ( "mma", -1, 1, "", this),            new Among ( "imma", 0, -1, "", this)        };        private static final char g_AEI[] = {17, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8 };        private static final char g_v[] = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32 };        private static final char g_V[] = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32 };        private static final char g_particle_end[] = {17, 97, 24, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32 };        private boolean B_ending_removed;        private StringBuffer S_x = new StringBuffer();        private int I_p2;        private int I_p1;        private void copy_from(FinnishStemmer other) {            B_ending_removed = other.B_ending_removed;            S_x = other.S_x;            I_p2 = other.I_p2;            I_p1 = other.I_p1;            super.copy_from(other);        }        private boolean r_mark_regions() {            int v_1;            int v_3;            // (, line 41            I_p1 = limit;            I_p2 = limit;            // goto, line 46            golab0: while(true)            {                v_1 = cursor;                lab1: do {                    if (!(in_grouping(g_v, 97, 246)))                    {                        break lab1;                    }                    cursor = v_1;                    break golab0;                } while (false);                cursor = v_1;                if (cursor >= limit)                {                    return false;                }                cursor++;            }            // gopast, line 46            golab2: while(true)            {                lab3: do {                    if (!(out_grouping(g_v, 97, 246)))                    {                        break lab3;                    }                    break golab2;                } while (false);                if (cursor >= limit)                {                    return false;                }                cursor++;            }            // setmark p1, line 46            I_p1 = cursor;            // goto, line 47            golab4: while(true)            {                v_3 = cursor;                lab5: do {                    if (!(in_grouping(g_v, 97, 246)))                    {                        break lab5;                    }                    cursor = v_3;                    break golab4;                } while (false);                cursor = v_3;                if (cursor >= limit)                {                    return false;                }                cursor++;            }            // gopast, line 47            golab6: while(true)            {                lab7: do {                    if (!(out_grouping(g_v, 97, 246)))                    {                        break lab7;                    }                    break golab6;                } while (false);                if (cursor >= limit)                {                    return false;                }                cursor++;            }            // setmark p2, line 47            I_p2 = cursor;            return true;        }        private boolean r_R2() {            if (!(I_p2 <= cursor))            {                return false;            }            return true;        }        private boolean r_particle_etc() {            int among_var;            int v_1;            int v_2;            // (, line 54            // setlimit, line 55            v_1 = limit - cursor;            // tomark, line 55            if (cursor < I_p1)            {                return false;            }            cursor = I_p1;            v_2 = limit_backward;            limit_backward = cursor;            cursor = limit - v_1;            // (, line 55            // [, line 55            ket = cursor;            // substring, line 55            among_var = find_among_b(a_0, 10);            if (among_var == 0)            {                limit_backward = v_2;                return false;            }            // ], line 55            bra = cursor;            limit_backward = v_2;            switch(among_var) {                case 0:                    return false;                case 1:                    // (, line 62                    if (!(in_grouping_b(g_particle_end, 97, 246)))                    {                        return false;                    }                    break;                case 2:                    // (, line 64                    // call R2, line 64                    if (!r_R2())                    {                        return false;                    }                    break;            }            // delete, line 66            slice_del();            return true;        }        private boolean r_possessive() {            int among_var;            int v_1;            int v_2;            int v_3;            // (, line 68            // setlimit, line 69            v_1 = limit - cursor;            // tomark, line 69            if (cursor < I_p1)            {                return false;            }            cursor = I_p1;            v_2 = limit_backward;            limit_backward = cursor;            cursor = limit - v_1;            // (, line 69            // [, line 69            ket = cursor;            // substring, line 69            among_var = find_among_b(a_4, 9);            if (among_var == 0)            {                limit_backward = v_2;                return false;            }            // ], line 69            bra = cursor;            limit_backward = v_2;            switch(among_var) {                case 0:                    return false;                case 1:                    // (, line 72                    // not, line 72                    {                        v_3 = limit - cursor;                        lab0: do {                            // literal, line 72                            if (!(eq_s_b(1, "k")))                            {                                break lab0;                            }                            return false;                        } while (false);                        cursor = limit - v_3;                    }                    // delete, line 72                    slice_del();                    break;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -