~slub.team/goobi-indexserver/3.x

« back to all changes in this revision

Viewing changes to lucene/contrib/analyzers/common/src/java/org/tartarus/snowball/ext/EnglishStemmer.java

  • Committer: Sebastian Meyer
  • Date: 2012-08-03 09:12:40 UTC
  • Revision ID: sebastian.meyer@slub-dresden.de-20120803091240-x6861b0vabq1xror
Remove Lucene and Solr source code and add patches instead
Fix Bug #985487: Auto-suggestion for the search interface

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
// This file was generated automatically by the Snowball to Java compiler
2
 
 
3
 
package org.tartarus.snowball.ext;
4
 
import org.tartarus.snowball.SnowballProgram;
5
 
import org.tartarus.snowball.Among;
6
 
 
7
 
/**
8
 
 * Generated class implementing code defined by a snowball script.
9
 
 */
10
 
public class EnglishStemmer extends SnowballProgram {
11
 
 
12
 
        private Among a_0[] = {
13
 
            new Among ( "arsen", -1, -1, "", this),
14
 
            new Among ( "commun", -1, -1, "", this),
15
 
            new Among ( "gener", -1, -1, "", this)
16
 
        };
17
 
 
18
 
        private Among a_1[] = {
19
 
            new Among ( "'", -1, 1, "", this),
20
 
            new Among ( "'s'", 0, 1, "", this),
21
 
            new Among ( "'s", -1, 1, "", this)
22
 
        };
23
 
 
24
 
        private Among a_2[] = {
25
 
            new Among ( "ied", -1, 2, "", this),
26
 
            new Among ( "s", -1, 3, "", this),
27
 
            new Among ( "ies", 1, 2, "", this),
28
 
            new Among ( "sses", 1, 1, "", this),
29
 
            new Among ( "ss", 1, -1, "", this),
30
 
            new Among ( "us", 1, -1, "", this)
31
 
        };
32
 
 
33
 
        private Among a_3[] = {
34
 
            new Among ( "", -1, 3, "", this),
35
 
            new Among ( "bb", 0, 2, "", this),
36
 
            new Among ( "dd", 0, 2, "", this),
37
 
            new Among ( "ff", 0, 2, "", this),
38
 
            new Among ( "gg", 0, 2, "", this),
39
 
            new Among ( "bl", 0, 1, "", this),
40
 
            new Among ( "mm", 0, 2, "", this),
41
 
            new Among ( "nn", 0, 2, "", this),
42
 
            new Among ( "pp", 0, 2, "", this),
43
 
            new Among ( "rr", 0, 2, "", this),
44
 
            new Among ( "at", 0, 1, "", this),
45
 
            new Among ( "tt", 0, 2, "", this),
46
 
            new Among ( "iz", 0, 1, "", this)
47
 
        };
48
 
 
49
 
        private Among a_4[] = {
50
 
            new Among ( "ed", -1, 2, "", this),
51
 
            new Among ( "eed", 0, 1, "", this),
52
 
            new Among ( "ing", -1, 2, "", this),
53
 
            new Among ( "edly", -1, 2, "", this),
54
 
            new Among ( "eedly", 3, 1, "", this),
55
 
            new Among ( "ingly", -1, 2, "", this)
56
 
        };
57
 
 
58
 
        private Among a_5[] = {
59
 
            new Among ( "anci", -1, 3, "", this),
60
 
            new Among ( "enci", -1, 2, "", this),
61
 
            new Among ( "ogi", -1, 13, "", this),
62
 
            new Among ( "li", -1, 16, "", this),
63
 
            new Among ( "bli", 3, 12, "", this),
64
 
            new Among ( "abli", 4, 4, "", this),
65
 
            new Among ( "alli", 3, 8, "", this),
66
 
            new Among ( "fulli", 3, 14, "", this),
67
 
            new Among ( "lessli", 3, 15, "", this),
68
 
            new Among ( "ousli", 3, 10, "", this),
69
 
            new Among ( "entli", 3, 5, "", this),
70
 
            new Among ( "aliti", -1, 8, "", this),
71
 
            new Among ( "biliti", -1, 12, "", this),
72
 
            new Among ( "iviti", -1, 11, "", this),
73
 
            new Among ( "tional", -1, 1, "", this),
74
 
            new Among ( "ational", 14, 7, "", this),
75
 
            new Among ( "alism", -1, 8, "", this),
76
 
            new Among ( "ation", -1, 7, "", this),
77
 
            new Among ( "ization", 17, 6, "", this),
78
 
            new Among ( "izer", -1, 6, "", this),
79
 
            new Among ( "ator", -1, 7, "", this),
80
 
            new Among ( "iveness", -1, 11, "", this),
81
 
            new Among ( "fulness", -1, 9, "", this),
82
 
            new Among ( "ousness", -1, 10, "", this)
83
 
        };
84
 
 
85
 
        private Among a_6[] = {
86
 
            new Among ( "icate", -1, 4, "", this),
87
 
            new Among ( "ative", -1, 6, "", this),
88
 
            new Among ( "alize", -1, 3, "", this),
89
 
            new Among ( "iciti", -1, 4, "", this),
90
 
            new Among ( "ical", -1, 4, "", this),
91
 
            new Among ( "tional", -1, 1, "", this),
92
 
            new Among ( "ational", 5, 2, "", this),
93
 
            new Among ( "ful", -1, 5, "", this),
94
 
            new Among ( "ness", -1, 5, "", this)
95
 
        };
96
 
 
97
 
        private Among a_7[] = {
98
 
            new Among ( "ic", -1, 1, "", this),
99
 
            new Among ( "ance", -1, 1, "", this),
100
 
            new Among ( "ence", -1, 1, "", this),
101
 
            new Among ( "able", -1, 1, "", this),
102
 
            new Among ( "ible", -1, 1, "", this),
103
 
            new Among ( "ate", -1, 1, "", this),
104
 
            new Among ( "ive", -1, 1, "", this),
105
 
            new Among ( "ize", -1, 1, "", this),
106
 
            new Among ( "iti", -1, 1, "", this),
107
 
            new Among ( "al", -1, 1, "", this),
108
 
            new Among ( "ism", -1, 1, "", this),
109
 
            new Among ( "ion", -1, 2, "", this),
110
 
            new Among ( "er", -1, 1, "", this),
111
 
            new Among ( "ous", -1, 1, "", this),
112
 
            new Among ( "ant", -1, 1, "", this),
113
 
            new Among ( "ent", -1, 1, "", this),
114
 
            new Among ( "ment", 15, 1, "", this),
115
 
            new Among ( "ement", 16, 1, "", this)
116
 
        };
117
 
 
118
 
        private Among a_8[] = {
119
 
            new Among ( "e", -1, 1, "", this),
120
 
            new Among ( "l", -1, 2, "", this)
121
 
        };
122
 
 
123
 
        private Among a_9[] = {
124
 
            new Among ( "succeed", -1, -1, "", this),
125
 
            new Among ( "proceed", -1, -1, "", this),
126
 
            new Among ( "exceed", -1, -1, "", this),
127
 
            new Among ( "canning", -1, -1, "", this),
128
 
            new Among ( "inning", -1, -1, "", this),
129
 
            new Among ( "earring", -1, -1, "", this),
130
 
            new Among ( "herring", -1, -1, "", this),
131
 
            new Among ( "outing", -1, -1, "", this)
132
 
        };
133
 
 
134
 
        private Among a_10[] = {
135
 
            new Among ( "andes", -1, -1, "", this),
136
 
            new Among ( "atlas", -1, -1, "", this),
137
 
            new Among ( "bias", -1, -1, "", this),
138
 
            new Among ( "cosmos", -1, -1, "", this),
139
 
            new Among ( "dying", -1, 3, "", this),
140
 
            new Among ( "early", -1, 9, "", this),
141
 
            new Among ( "gently", -1, 7, "", this),
142
 
            new Among ( "howe", -1, -1, "", this),
143
 
            new Among ( "idly", -1, 6, "", this),
144
 
            new Among ( "lying", -1, 4, "", this),
145
 
            new Among ( "news", -1, -1, "", this),
146
 
            new Among ( "only", -1, 10, "", this),
147
 
            new Among ( "singly", -1, 11, "", this),
148
 
            new Among ( "skies", -1, 2, "", this),
149
 
            new Among ( "skis", -1, 1, "", this),
150
 
            new Among ( "sky", -1, -1, "", this),
151
 
            new Among ( "tying", -1, 5, "", this),
152
 
            new Among ( "ugly", -1, 8, "", this)
153
 
        };
154
 
 
155
 
        private static final char g_v[] = {17, 65, 16, 1 };
156
 
 
157
 
        private static final char g_v_WXY[] = {1, 17, 65, 208, 1 };
158
 
 
159
 
        private static final char g_valid_LI[] = {55, 141, 2 };
160
 
 
161
 
        private boolean B_Y_found;
162
 
        private int I_p2;
163
 
        private int I_p1;
164
 
 
165
 
        private void copy_from(EnglishStemmer other) {
166
 
            B_Y_found = other.B_Y_found;
167
 
            I_p2 = other.I_p2;
168
 
            I_p1 = other.I_p1;
169
 
            super.copy_from(other);
170
 
        }
171
 
 
172
 
        private boolean r_prelude() {
173
 
            int v_1;
174
 
            int v_2;
175
 
            int v_3;
176
 
            int v_4;
177
 
            int v_5;
178
 
            // (, line 25
179
 
            // unset Y_found, line 26
180
 
            B_Y_found = false;
181
 
            // do, line 27
182
 
            v_1 = cursor;
183
 
            lab0: do {
184
 
                // (, line 27
185
 
                // [, line 27
186
 
                bra = cursor;
187
 
                // literal, line 27
188
 
                if (!(eq_s(1, "'")))
189
 
                {
190
 
                    break lab0;
191
 
                }
192
 
                // ], line 27
193
 
                ket = cursor;
194
 
                // delete, line 27
195
 
                slice_del();
196
 
            } while (false);
197
 
            cursor = v_1;
198
 
            // do, line 28
199
 
            v_2 = cursor;
200
 
            lab1: do {
201
 
                // (, line 28
202
 
                // [, line 28
203
 
                bra = cursor;
204
 
                // literal, line 28
205
 
                if (!(eq_s(1, "y")))
206
 
                {
207
 
                    break lab1;
208
 
                }
209
 
                // ], line 28
210
 
                ket = cursor;
211
 
                // <-, line 28
212
 
                slice_from("Y");
213
 
                // set Y_found, line 28
214
 
                B_Y_found = true;
215
 
            } while (false);
216
 
            cursor = v_2;
217
 
            // do, line 29
218
 
            v_3 = cursor;
219
 
            lab2: do {
220
 
                // repeat, line 29
221
 
                replab3: while(true)
222
 
                {
223
 
                    v_4 = cursor;
224
 
                    lab4: do {
225
 
                        // (, line 29
226
 
                        // goto, line 29
227
 
                        golab5: while(true)
228
 
                        {
229
 
                            v_5 = cursor;
230
 
                            lab6: do {
231
 
                                // (, line 29
232
 
                                if (!(in_grouping(g_v, 97, 121)))
233
 
                                {
234
 
                                    break lab6;
235
 
                                }
236
 
                                // [, line 29
237
 
                                bra = cursor;
238
 
                                // literal, line 29
239
 
                                if (!(eq_s(1, "y")))
240
 
                                {
241
 
                                    break lab6;
242
 
                                }
243
 
                                // ], line 29
244
 
                                ket = cursor;
245
 
                                cursor = v_5;
246
 
                                break golab5;
247
 
                            } while (false);
248
 
                            cursor = v_5;
249
 
                            if (cursor >= limit)
250
 
                            {
251
 
                                break lab4;
252
 
                            }
253
 
                            cursor++;
254
 
                        }
255
 
                        // <-, line 29
256
 
                        slice_from("Y");
257
 
                        // set Y_found, line 29
258
 
                        B_Y_found = true;
259
 
                        continue replab3;
260
 
                    } while (false);
261
 
                    cursor = v_4;
262
 
                    break replab3;
263
 
                }
264
 
            } while (false);
265
 
            cursor = v_3;
266
 
            return true;
267
 
        }
268
 
 
269
 
        private boolean r_mark_regions() {
270
 
            int v_1;
271
 
            int v_2;
272
 
            // (, line 32
273
 
            I_p1 = limit;
274
 
            I_p2 = limit;
275
 
            // do, line 35
276
 
            v_1 = cursor;
277
 
            lab0: do {
278
 
                // (, line 35
279
 
                // or, line 41
280
 
                lab1: do {
281
 
                    v_2 = cursor;
282
 
                    lab2: do {
283
 
                        // among, line 36
284
 
                        if (find_among(a_0, 3) == 0)
285
 
                        {
286
 
                            break lab2;
287
 
                        }
288
 
                        break lab1;
289
 
                    } while (false);
290
 
                    cursor = v_2;
291
 
                    // (, line 41
292
 
                    // gopast, line 41
293
 
                    golab3: while(true)
294
 
                    {
295
 
                        lab4: do {
296
 
                            if (!(in_grouping(g_v, 97, 121)))
297
 
                            {
298
 
                                break lab4;
299
 
                            }
300
 
                            break golab3;
301
 
                        } while (false);
302
 
                        if (cursor >= limit)
303
 
                        {
304
 
                            break lab0;
305
 
                        }
306
 
                        cursor++;
307
 
                    }
308
 
                    // gopast, line 41
309
 
                    golab5: while(true)
310
 
                    {
311
 
                        lab6: do {
312
 
                            if (!(out_grouping(g_v, 97, 121)))
313
 
                            {
314
 
                                break lab6;
315
 
                            }
316
 
                            break golab5;
317
 
                        } while (false);
318
 
                        if (cursor >= limit)
319
 
                        {
320
 
                            break lab0;
321
 
                        }
322
 
                        cursor++;
323
 
                    }
324
 
                } while (false);
325
 
                // setmark p1, line 42
326
 
                I_p1 = cursor;
327
 
                // gopast, line 43
328
 
                golab7: while(true)
329
 
                {
330
 
                    lab8: do {
331
 
                        if (!(in_grouping(g_v, 97, 121)))
332
 
                        {
333
 
                            break lab8;
334
 
                        }
335
 
                        break golab7;
336
 
                    } while (false);
337
 
                    if (cursor >= limit)
338
 
                    {
339
 
                        break lab0;
340
 
                    }
341
 
                    cursor++;
342
 
                }
343
 
                // gopast, line 43
344
 
                golab9: while(true)
345
 
                {
346
 
                    lab10: do {
347
 
                        if (!(out_grouping(g_v, 97, 121)))
348
 
                        {
349
 
                            break lab10;
350
 
                        }
351
 
                        break golab9;
352
 
                    } while (false);
353
 
                    if (cursor >= limit)
354
 
                    {
355
 
                        break lab0;
356
 
                    }
357
 
                    cursor++;
358
 
                }
359
 
                // setmark p2, line 43
360
 
                I_p2 = cursor;
361
 
            } while (false);
362
 
            cursor = v_1;
363
 
            return true;
364
 
        }
365
 
 
366
 
        private boolean r_shortv() {
367
 
            int v_1;
368
 
            // (, line 49
369
 
            // or, line 51
370
 
            lab0: do {
371
 
                v_1 = limit - cursor;
372
 
                lab1: do {
373
 
                    // (, line 50
374
 
                    if (!(out_grouping_b(g_v_WXY, 89, 121)))
375
 
                    {
376
 
                        break lab1;
377
 
                    }
378
 
                    if (!(in_grouping_b(g_v, 97, 121)))
379
 
                    {
380
 
                        break lab1;
381
 
                    }
382
 
                    if (!(out_grouping_b(g_v, 97, 121)))
383
 
                    {
384
 
                        break lab1;
385
 
                    }
386
 
                    break lab0;
387
 
                } while (false);
388
 
                cursor = limit - v_1;
389
 
                // (, line 52
390
 
                if (!(out_grouping_b(g_v, 97, 121)))
391
 
                {
392
 
                    return false;
393
 
                }
394
 
                if (!(in_grouping_b(g_v, 97, 121)))
395
 
                {
396
 
                    return false;
397
 
                }
398
 
                // atlimit, line 52
399
 
                if (cursor > limit_backward)
400
 
                {
401
 
                    return false;
402
 
                }
403
 
            } while (false);
404
 
            return true;
405
 
        }
406
 
 
407
 
        private boolean r_R1() {
408
 
            if (!(I_p1 <= cursor))
409
 
            {
410
 
                return false;
411
 
            }
412
 
            return true;
413
 
        }
414
 
 
415
 
        private boolean r_R2() {
416
 
            if (!(I_p2 <= cursor))
417
 
            {
418
 
                return false;
419
 
            }
420
 
            return true;
421
 
        }
422
 
 
423
 
        private boolean r_Step_1a() {
424
 
            int among_var;
425
 
            int v_1;
426
 
            int v_2;
427
 
            // (, line 58
428
 
            // try, line 59
429
 
            v_1 = limit - cursor;
430
 
            lab0: do {
431
 
                // (, line 59
432
 
                // [, line 60
433
 
                ket = cursor;
434
 
                // substring, line 60
435
 
                among_var = find_among_b(a_1, 3);
436
 
                if (among_var == 0)
437
 
                {
438
 
                    cursor = limit - v_1;
439
 
                    break lab0;
440
 
                }
441
 
                // ], line 60
442
 
                bra = cursor;
443
 
                switch(among_var) {
444
 
                    case 0:
445
 
                        cursor = limit - v_1;
446
 
                        break lab0;
447
 
                    case 1:
448
 
                        // (, line 62
449
 
                        // delete, line 62
450
 
                        slice_del();
451
 
                        break;
452
 
                }
453
 
            } while (false);
454
 
            // [, line 65
455
 
            ket = cursor;
456
 
            // substring, line 65
457
 
            among_var = find_among_b(a_2, 6);
458
 
            if (among_var == 0)
459
 
            {
460
 
                return false;
461
 
            }
462
 
            // ], line 65
463
 
            bra = cursor;
464
 
            switch(among_var) {
465
 
                case 0:
466
 
                    return false;
467
 
                case 1:
468
 
                    // (, line 66
469
 
                    // <-, line 66
470
 
                    slice_from("ss");
471
 
                    break;
472
 
                case 2:
473
 
                    // (, line 68
474
 
                    // or, line 68
475
 
                    lab1: do {
476
 
                        v_2 = limit - cursor;
477
 
                        lab2: do {
478
 
                            // (, line 68
479
 
                            // hop, line 68
480
 
                            {
481
 
                                int c = cursor - 2;
482
 
                                if (limit_backward > c || c > limit)
483
 
                                {
484
 
                                    break lab2;
485
 
                                }
486
 
                                cursor = c;
487
 
                            }
488
 
                            // <-, line 68
489
 
                            slice_from("i");
490
 
                            break lab1;
491
 
                        } while (false);
492
 
                        cursor = limit - v_2;
493
 
                        // <-, line 68
494
 
                        slice_from("ie");
495
 
                    } while (false);
496
 
                    break;
497
 
                case 3:
498
 
                    // (, line 69
499
 
                    // next, line 69
500
 
                    if (cursor <= limit_backward)
501
 
                    {
502
 
                        return false;
503
 
                    }
504
 
                    cursor--;
505
 
                    // gopast, line 69
506
 
                    golab3: while(true)
507
 
                    {
508
 
                        lab4: do {
509
 
                            if (!(in_grouping_b(g_v, 97, 121)))
510
 
                            {
511
 
                                break lab4;
512
 
                            }
513
 
                            break golab3;
514
 
                        } while (false);
515
 
                        if (cursor <= limit_backward)
516
 
                        {
517
 
                            return false;
518
 
                        }
519
 
                        cursor--;
520
 
                    }
521
 
                    // delete, line 69
522
 
                    slice_del();
523
 
                    break;
524
 
            }
525
 
            return true;
526
 
        }
527
 
 
528
 
        private boolean r_Step_1b() {
529
 
            int among_var;
530
 
            int v_1;
531
 
            int v_3;
532
 
            int v_4;
533
 
            // (, line 74
534
 
            // [, line 75
535
 
            ket = cursor;
536
 
            // substring, line 75
537
 
            among_var = find_among_b(a_4, 6);
538
 
            if (among_var == 0)
539
 
            {
540
 
                return false;
541
 
            }
542
 
            // ], line 75
543
 
            bra = cursor;
544
 
            switch(among_var) {
545
 
                case 0:
546
 
                    return false;
547
 
                case 1:
548
 
                    // (, line 77
549
 
                    // call R1, line 77
550
 
                    if (!r_R1())
551
 
                    {
552
 
                        return false;
553
 
                    }
554
 
                    // <-, line 77
555
 
                    slice_from("ee");
556
 
                    break;
557
 
                case 2:
558
 
                    // (, line 79
559
 
                    // test, line 80
560
 
                    v_1 = limit - cursor;
561
 
                    // gopast, line 80
562
 
                    golab0: while(true)
563
 
                    {
564
 
                        lab1: do {
565
 
                            if (!(in_grouping_b(g_v, 97, 121)))
566
 
                            {
567
 
                                break lab1;
568
 
                            }
569
 
                            break golab0;
570
 
                        } while (false);
571
 
                        if (cursor <= limit_backward)
572
 
                        {
573
 
                            return false;
574
 
                        }
575
 
                        cursor--;
576
 
                    }
577
 
                    cursor = limit - v_1;
578
 
                    // delete, line 80
579
 
                    slice_del();
580
 
                    // test, line 81
581
 
                    v_3 = limit - cursor;
582
 
                    // substring, line 81
583
 
                    among_var = find_among_b(a_3, 13);
584
 
                    if (among_var == 0)
585
 
                    {
586
 
                        return false;
587
 
                    }
588
 
                    cursor = limit - v_3;
589
 
                    switch(among_var) {
590
 
                        case 0:
591
 
                            return false;
592
 
                        case 1:
593
 
                            // (, line 83
594
 
                            // <+, line 83
595
 
                            {
596
 
                                int c = cursor;
597
 
                                insert(cursor, cursor, "e");
598
 
                                cursor = c;
599
 
                            }
600
 
                            break;
601
 
                        case 2:
602
 
                            // (, line 86
603
 
                            // [, line 86
604
 
                            ket = cursor;
605
 
                            // next, line 86
606
 
                            if (cursor <= limit_backward)
607
 
                            {
608
 
                                return false;
609
 
                            }
610
 
                            cursor--;
611
 
                            // ], line 86
612
 
                            bra = cursor;
613
 
                            // delete, line 86
614
 
                            slice_del();
615
 
                            break;
616
 
                        case 3:
617
 
                            // (, line 87
618
 
                            // atmark, line 87
619
 
                            if (cursor != I_p1)
620
 
                            {
621
 
                                return false;
622
 
                            }
623
 
                            // test, line 87
624
 
                            v_4 = limit - cursor;
625
 
                            // call shortv, line 87
626
 
                            if (!r_shortv())
627
 
                            {
628
 
                                return false;
629
 
                            }
630
 
                            cursor = limit - v_4;
631
 
                            // <+, line 87
632
 
                            {
633
 
                                int c = cursor;
634
 
                                insert(cursor, cursor, "e");
635
 
                                cursor = c;
636
 
                            }
637
 
                            break;
638
 
                    }
639
 
                    break;
640
 
            }
641
 
            return true;
642
 
        }
643
 
 
644
 
        private boolean r_Step_1c() {
645
 
            int v_1;
646
 
            int v_2;
647
 
            // (, line 93
648
 
            // [, line 94
649
 
            ket = cursor;
650
 
            // or, line 94
651
 
            lab0: do {
652
 
                v_1 = limit - cursor;
653
 
                lab1: do {
654
 
                    // literal, line 94
655
 
                    if (!(eq_s_b(1, "y")))
656
 
                    {
657
 
                        break lab1;
658
 
                    }
659
 
                    break lab0;
660
 
                } while (false);
661
 
                cursor = limit - v_1;
662
 
                // literal, line 94
663
 
                if (!(eq_s_b(1, "Y")))
664
 
                {
665
 
                    return false;
666
 
                }
667
 
            } while (false);
668
 
            // ], line 94
669
 
            bra = cursor;
670
 
            if (!(out_grouping_b(g_v, 97, 121)))
671
 
            {
672
 
                return false;
673
 
            }
674
 
            // not, line 95
675
 
            {
676
 
                v_2 = limit - cursor;
677
 
                lab2: do {
678
 
                    // atlimit, line 95
679
 
                    if (cursor > limit_backward)
680
 
                    {
681
 
                        break lab2;
682
 
                    }
683
 
                    return false;
684
 
                } while (false);
685
 
                cursor = limit - v_2;
686
 
            }
687
 
            // <-, line 96
688
 
            slice_from("i");
689
 
            return true;
690
 
        }
691
 
 
692
 
        private boolean r_Step_2() {
693
 
            int among_var;
694
 
            // (, line 99
695
 
            // [, line 100
696
 
            ket = cursor;
697
 
            // substring, line 100
698
 
            among_var = find_among_b(a_5, 24);
699
 
            if (among_var == 0)
700
 
            {
701
 
                return false;
702
 
            }
703
 
            // ], line 100
704
 
            bra = cursor;
705
 
            // call R1, line 100
706
 
            if (!r_R1())
707
 
            {
708
 
                return false;
709
 
            }
710
 
            switch(among_var) {
711
 
                case 0:
712
 
                    return false;
713
 
                case 1:
714
 
                    // (, line 101
715
 
                    // <-, line 101
716
 
                    slice_from("tion");
717
 
                    break;
718
 
                case 2:
719
 
                    // (, line 102
720
 
                    // <-, line 102
721
 
                    slice_from("ence");
722
 
                    break;
723
 
                case 3:
724
 
                    // (, line 103
725
 
                    // <-, line 103
726
 
                    slice_from("ance");
727
 
                    break;
728
 
                case 4:
729
 
                    // (, line 104
730
 
                    // <-, line 104
731
 
                    slice_from("able");
732
 
                    break;
733
 
                case 5:
734
 
                    // (, line 105
735
 
                    // <-, line 105
736
 
                    slice_from("ent");
737
 
                    break;
738
 
                case 6:
739
 
                    // (, line 107
740
 
                    // <-, line 107
741
 
                    slice_from("ize");
742
 
                    break;
743
 
                case 7:
744
 
                    // (, line 109
745
 
                    // <-, line 109
746
 
                    slice_from("ate");
747
 
                    break;
748
 
                case 8:
749
 
                    // (, line 111
750
 
                    // <-, line 111
751
 
                    slice_from("al");
752
 
                    break;
753
 
                case 9:
754
 
                    // (, line 112
755
 
                    // <-, line 112
756
 
                    slice_from("ful");
757
 
                    break;
758
 
                case 10:
759
 
                    // (, line 114
760
 
                    // <-, line 114
761
 
                    slice_from("ous");
762
 
                    break;
763
 
                case 11:
764
 
                    // (, line 116
765
 
                    // <-, line 116
766
 
                    slice_from("ive");
767
 
                    break;
768
 
                case 12:
769
 
                    // (, line 118
770
 
                    // <-, line 118
771
 
                    slice_from("ble");
772
 
                    break;
773
 
                case 13:
774
 
                    // (, line 119
775
 
                    // literal, line 119
776
 
                    if (!(eq_s_b(1, "l")))
777
 
                    {
778
 
                        return false;
779
 
                    }
780
 
                    // <-, line 119
781
 
                    slice_from("og");
782
 
                    break;
783
 
                case 14:
784
 
                    // (, line 120
785
 
                    // <-, line 120
786
 
                    slice_from("ful");
787
 
                    break;
788
 
                case 15:
789
 
                    // (, line 121
790
 
                    // <-, line 121
791
 
                    slice_from("less");
792
 
                    break;
793
 
                case 16:
794
 
                    // (, line 122
795
 
                    if (!(in_grouping_b(g_valid_LI, 99, 116)))
796
 
                    {
797
 
                        return false;
798
 
                    }
799
 
                    // delete, line 122
800
 
                    slice_del();
801
 
                    break;
802
 
            }
803
 
            return true;
804
 
        }
805
 
 
806
 
        private boolean r_Step_3() {
807
 
            int among_var;
808
 
            // (, line 126
809
 
            // [, line 127
810
 
            ket = cursor;
811
 
            // substring, line 127
812
 
            among_var = find_among_b(a_6, 9);
813
 
            if (among_var == 0)
814
 
            {
815
 
                return false;
816
 
            }
817
 
            // ], line 127
818
 
            bra = cursor;
819
 
            // call R1, line 127
820
 
            if (!r_R1())
821
 
            {
822
 
                return false;
823
 
            }
824
 
            switch(among_var) {
825
 
                case 0:
826
 
                    return false;
827
 
                case 1:
828
 
                    // (, line 128
829
 
                    // <-, line 128
830
 
                    slice_from("tion");
831
 
                    break;
832
 
                case 2:
833
 
                    // (, line 129
834
 
                    // <-, line 129
835
 
                    slice_from("ate");
836
 
                    break;
837
 
                case 3:
838
 
                    // (, line 130
839
 
                    // <-, line 130
840
 
                    slice_from("al");
841
 
                    break;
842
 
                case 4:
843
 
                    // (, line 132
844
 
                    // <-, line 132
845
 
                    slice_from("ic");
846
 
                    break;
847
 
                case 5:
848
 
                    // (, line 134
849
 
                    // delete, line 134
850
 
                    slice_del();
851
 
                    break;
852
 
                case 6:
853
 
                    // (, line 136
854
 
                    // call R2, line 136
855
 
                    if (!r_R2())
856
 
                    {
857
 
                        return false;
858
 
                    }
859
 
                    // delete, line 136
860
 
                    slice_del();
861
 
                    break;
862
 
            }
863
 
            return true;
864
 
        }
865
 
 
866
 
        private boolean r_Step_4() {
867
 
            int among_var;
868
 
            int v_1;
869
 
            // (, line 140
870
 
            // [, line 141
871
 
            ket = cursor;
872
 
            // substring, line 141
873
 
            among_var = find_among_b(a_7, 18);
874
 
            if (among_var == 0)
875
 
            {
876
 
                return false;
877
 
            }
878
 
            // ], line 141
879
 
            bra = cursor;
880
 
            // call R2, line 141
881
 
            if (!r_R2())
882
 
            {
883
 
                return false;
884
 
            }
885
 
            switch(among_var) {
886
 
                case 0:
887
 
                    return false;
888
 
                case 1:
889
 
                    // (, line 144
890
 
                    // delete, line 144
891
 
                    slice_del();
892
 
                    break;
893
 
                case 2:
894
 
                    // (, line 145
895
 
                    // or, line 145
896
 
                    lab0: do {
897
 
                        v_1 = limit - cursor;
898
 
                        lab1: do {
899
 
                            // literal, line 145
900
 
                            if (!(eq_s_b(1, "s")))
901
 
                            {
902
 
                                break lab1;
903
 
                            }
904
 
                            break lab0;
905
 
                        } while (false);
906
 
                        cursor = limit - v_1;
907
 
                        // literal, line 145
908
 
                        if (!(eq_s_b(1, "t")))
909
 
                        {
910
 
                            return false;
911
 
                        }
912
 
                    } while (false);
913
 
                    // delete, line 145
914
 
                    slice_del();
915
 
                    break;
916
 
            }
917
 
            return true;
918
 
        }
919
 
 
920
 
        private boolean r_Step_5() {
921
 
            int among_var;
922
 
            int v_1;
923
 
            int v_2;
924
 
            // (, line 149
925
 
            // [, line 150
926
 
            ket = cursor;
927
 
            // substring, line 150
928
 
            among_var = find_among_b(a_8, 2);
929
 
            if (among_var == 0)
930
 
            {
931
 
                return false;
932
 
            }
933
 
            // ], line 150
934
 
            bra = cursor;
935
 
            switch(among_var) {
936
 
                case 0:
937
 
                    return false;
938
 
                case 1:
939
 
                    // (, line 151
940
 
                    // or, line 151
941
 
                    lab0: do {
942
 
                        v_1 = limit - cursor;
943
 
                        lab1: do {
944
 
                            // call R2, line 151
945
 
                            if (!r_R2())
946
 
                            {
947
 
                                break lab1;
948
 
                            }
949
 
                            break lab0;
950
 
                        } while (false);
951
 
                        cursor = limit - v_1;
952
 
                        // (, line 151
953
 
                        // call R1, line 151
954
 
                        if (!r_R1())
955
 
                        {
956
 
                            return false;
957
 
                        }
958
 
                        // not, line 151
959
 
                        {
960
 
                            v_2 = limit - cursor;
961
 
                            lab2: do {
962
 
                                // call shortv, line 151
963
 
                                if (!r_shortv())
964
 
                                {
965
 
                                    break lab2;
966
 
                                }
967
 
                                return false;
968
 
                            } while (false);
969
 
                            cursor = limit - v_2;
970
 
                        }
971
 
                    } while (false);
972
 
                    // delete, line 151
973
 
                    slice_del();
974
 
                    break;
975
 
                case 2:
976
 
                    // (, line 152
977
 
                    // call R2, line 152
978
 
                    if (!r_R2())
979
 
                    {
980
 
                        return false;
981
 
                    }
982
 
                    // literal, line 152
983
 
                    if (!(eq_s_b(1, "l")))
984
 
                    {
985
 
                        return false;
986
 
                    }
987
 
                    // delete, line 152
988
 
                    slice_del();
989
 
                    break;
990
 
            }
991
 
            return true;
992
 
        }
993
 
 
994
 
        private boolean r_exception2() {
995
 
            // (, line 156
996
 
            // [, line 158
997
 
            ket = cursor;
998
 
            // substring, line 158
999
 
            if (find_among_b(a_9, 8) == 0)
1000
 
            {
1001
 
                return false;
1002
 
            }
1003
 
            // ], line 158
1004
 
            bra = cursor;
1005
 
            // atlimit, line 158
1006
 
            if (cursor > limit_backward)
1007
 
            {
1008
 
                return false;
1009
 
            }
1010
 
            return true;
1011
 
        }
1012
 
 
1013
 
        private boolean r_exception1() {
1014
 
            int among_var;
1015
 
            // (, line 168
1016
 
            // [, line 170
1017
 
            bra = cursor;
1018
 
            // substring, line 170
1019
 
            among_var = find_among(a_10, 18);
1020
 
            if (among_var == 0)
1021
 
            {
1022
 
                return false;
1023
 
            }
1024
 
            // ], line 170
1025
 
            ket = cursor;
1026
 
            // atlimit, line 170
1027
 
            if (cursor < limit)
1028
 
            {
1029
 
                return false;
1030
 
            }
1031
 
            switch(among_var) {
1032
 
                case 0:
1033
 
                    return false;
1034
 
                case 1:
1035
 
                    // (, line 174
1036
 
                    // <-, line 174
1037
 
                    slice_from("ski");
1038
 
                    break;
1039
 
                case 2:
1040
 
                    // (, line 175
1041
 
                    // <-, line 175
1042
 
                    slice_from("sky");
1043
 
                    break;
1044
 
                case 3:
1045
 
                    // (, line 176
1046
 
                    // <-, line 176
1047
 
                    slice_from("die");
1048
 
                    break;
1049
 
                case 4:
1050
 
                    // (, line 177
1051
 
                    // <-, line 177
1052
 
                    slice_from("lie");
1053
 
                    break;
1054
 
                case 5:
1055
 
                    // (, line 178
1056
 
                    // <-, line 178
1057
 
                    slice_from("tie");
1058
 
                    break;
1059
 
                case 6:
1060
 
                    // (, line 182
1061
 
                    // <-, line 182
1062
 
                    slice_from("idl");
1063
 
                    break;
1064
 
                case 7:
1065
 
                    // (, line 183
1066
 
                    // <-, line 183
1067
 
                    slice_from("gentl");
1068
 
                    break;
1069
 
                case 8:
1070
 
                    // (, line 184
1071
 
                    // <-, line 184
1072
 
                    slice_from("ugli");
1073
 
                    break;
1074
 
                case 9:
1075
 
                    // (, line 185
1076
 
                    // <-, line 185
1077
 
                    slice_from("earli");
1078
 
                    break;
1079
 
                case 10:
1080
 
                    // (, line 186
1081
 
                    // <-, line 186
1082
 
                    slice_from("onli");
1083
 
                    break;
1084
 
                case 11:
1085
 
                    // (, line 187
1086
 
                    // <-, line 187
1087
 
                    slice_from("singl");
1088
 
                    break;
1089
 
            }
1090
 
            return true;
1091
 
        }
1092
 
 
1093
 
        private boolean r_postlude() {
1094
 
            int v_1;
1095
 
            int v_2;
1096
 
            // (, line 203
1097
 
            // Boolean test Y_found, line 203
1098
 
            if (!(B_Y_found))
1099
 
            {
1100
 
                return false;
1101
 
            }
1102
 
            // repeat, line 203
1103
 
            replab0: while(true)
1104
 
            {
1105
 
                v_1 = cursor;
1106
 
                lab1: do {
1107
 
                    // (, line 203
1108
 
                    // goto, line 203
1109
 
                    golab2: while(true)
1110
 
                    {
1111
 
                        v_2 = cursor;
1112
 
                        lab3: do {
1113
 
                            // (, line 203
1114
 
                            // [, line 203
1115
 
                            bra = cursor;
1116
 
                            // literal, line 203
1117
 
                            if (!(eq_s(1, "Y")))
1118
 
                            {
1119
 
                                break lab3;
1120
 
                            }
1121
 
                            // ], line 203
1122
 
                            ket = cursor;
1123
 
                            cursor = v_2;
1124
 
                            break golab2;
1125
 
                        } while (false);
1126
 
                        cursor = v_2;
1127
 
                        if (cursor >= limit)
1128
 
                        {
1129
 
                            break lab1;
1130
 
                        }
1131
 
                        cursor++;
1132
 
                    }
1133
 
                    // <-, line 203
1134
 
                    slice_from("y");
1135
 
                    continue replab0;
1136
 
                } while (false);
1137
 
                cursor = v_1;
1138
 
                break replab0;
1139
 
            }
1140
 
            return true;
1141
 
        }
1142
 
 
1143
 
        public boolean stem() {
1144
 
            int v_1;
1145
 
            int v_2;
1146
 
            int v_3;
1147
 
            int v_4;
1148
 
            int v_5;
1149
 
            int v_6;
1150
 
            int v_7;
1151
 
            int v_8;
1152
 
            int v_9;
1153
 
            int v_10;
1154
 
            int v_11;
1155
 
            int v_12;
1156
 
            int v_13;
1157
 
            // (, line 205
1158
 
            // or, line 207
1159
 
            lab0: do {
1160
 
                v_1 = cursor;
1161
 
                lab1: do {
1162
 
                    // call exception1, line 207
1163
 
                    if (!r_exception1())
1164
 
                    {
1165
 
                        break lab1;
1166
 
                    }
1167
 
                    break lab0;
1168
 
                } while (false);
1169
 
                cursor = v_1;
1170
 
                lab2: do {
1171
 
                    // not, line 208
1172
 
                    {
1173
 
                        v_2 = cursor;
1174
 
                        lab3: do {
1175
 
                            // hop, line 208
1176
 
                            {
1177
 
                                int c = cursor + 3;
1178
 
                                if (0 > c || c > limit)
1179
 
                                {
1180
 
                                    break lab3;
1181
 
                                }
1182
 
                                cursor = c;
1183
 
                            }
1184
 
                            break lab2;
1185
 
                        } while (false);
1186
 
                        cursor = v_2;
1187
 
                    }
1188
 
                    break lab0;
1189
 
                } while (false);
1190
 
                cursor = v_1;
1191
 
                // (, line 208
1192
 
                // do, line 209
1193
 
                v_3 = cursor;
1194
 
                lab4: do {
1195
 
                    // call prelude, line 209
1196
 
                    if (!r_prelude())
1197
 
                    {
1198
 
                        break lab4;
1199
 
                    }
1200
 
                } while (false);
1201
 
                cursor = v_3;
1202
 
                // do, line 210
1203
 
                v_4 = cursor;
1204
 
                lab5: do {
1205
 
                    // call mark_regions, line 210
1206
 
                    if (!r_mark_regions())
1207
 
                    {
1208
 
                        break lab5;
1209
 
                    }
1210
 
                } while (false);
1211
 
                cursor = v_4;
1212
 
                // backwards, line 211
1213
 
                limit_backward = cursor; cursor = limit;
1214
 
                // (, line 211
1215
 
                // do, line 213
1216
 
                v_5 = limit - cursor;
1217
 
                lab6: do {
1218
 
                    // call Step_1a, line 213
1219
 
                    if (!r_Step_1a())
1220
 
                    {
1221
 
                        break lab6;
1222
 
                    }
1223
 
                } while (false);
1224
 
                cursor = limit - v_5;
1225
 
                // or, line 215
1226
 
                lab7: do {
1227
 
                    v_6 = limit - cursor;
1228
 
                    lab8: do {
1229
 
                        // call exception2, line 215
1230
 
                        if (!r_exception2())
1231
 
                        {
1232
 
                            break lab8;
1233
 
                        }
1234
 
                        break lab7;
1235
 
                    } while (false);
1236
 
                    cursor = limit - v_6;
1237
 
                    // (, line 215
1238
 
                    // do, line 217
1239
 
                    v_7 = limit - cursor;
1240
 
                    lab9: do {
1241
 
                        // call Step_1b, line 217
1242
 
                        if (!r_Step_1b())
1243
 
                        {
1244
 
                            break lab9;
1245
 
                        }
1246
 
                    } while (false);
1247
 
                    cursor = limit - v_7;
1248
 
                    // do, line 218
1249
 
                    v_8 = limit - cursor;
1250
 
                    lab10: do {
1251
 
                        // call Step_1c, line 218
1252
 
                        if (!r_Step_1c())
1253
 
                        {
1254
 
                            break lab10;
1255
 
                        }
1256
 
                    } while (false);
1257
 
                    cursor = limit - v_8;
1258
 
                    // do, line 220
1259
 
                    v_9 = limit - cursor;
1260
 
                    lab11: do {
1261
 
                        // call Step_2, line 220
1262
 
                        if (!r_Step_2())
1263
 
                        {
1264
 
                            break lab11;
1265
 
                        }
1266
 
                    } while (false);
1267
 
                    cursor = limit - v_9;
1268
 
                    // do, line 221
1269
 
                    v_10 = limit - cursor;
1270
 
                    lab12: do {
1271
 
                        // call Step_3, line 221
1272
 
                        if (!r_Step_3())
1273
 
                        {
1274
 
                            break lab12;
1275
 
                        }
1276
 
                    } while (false);
1277
 
                    cursor = limit - v_10;
1278
 
                    // do, line 222
1279
 
                    v_11 = limit - cursor;
1280
 
                    lab13: do {
1281
 
                        // call Step_4, line 222
1282
 
                        if (!r_Step_4())
1283
 
                        {
1284
 
                            break lab13;
1285
 
                        }
1286
 
                    } while (false);
1287
 
                    cursor = limit - v_11;
1288
 
                    // do, line 224
1289
 
                    v_12 = limit - cursor;
1290
 
                    lab14: do {
1291
 
                        // call Step_5, line 224
1292
 
                        if (!r_Step_5())
1293
 
                        {
1294
 
                            break lab14;
1295
 
                        }
1296
 
                    } while (false);
1297
 
                    cursor = limit - v_12;
1298
 
                } while (false);
1299
 
                cursor = limit_backward;                // do, line 227
1300
 
                v_13 = cursor;
1301
 
                lab15: do {
1302
 
                    // call postlude, line 227
1303
 
                    if (!r_postlude())
1304
 
                    {
1305
 
                        break lab15;
1306
 
                    }
1307
 
                } while (false);
1308
 
                cursor = v_13;
1309
 
            } while (false);
1310
 
            return true;
1311
 
        }
1312
 
 
1313
 
}
1314