LUCENE-1142 : Updated Snowball package, org.tartarus distribution revision 500.

Introducing Hungarian, Turkish and Romanian support, updated older stemmers and optimized (reflectionless) SnowballFilter.

IMPORTANT NOTICE ON BACKWARDS COMPATIBILITY: an index created using the 2.3.2 (or older) might not be compatible with these updated classes as some algorithms have changed.



git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@688420 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Karl-Johan Wettin 2008-08-23 22:02:47 +00:00
parent 9fe7a35378
commit 3034575f66
31 changed files with 7395 additions and 1912 deletions

View File

@ -8,6 +8,8 @@ Changes in runtime behavior
API Changes
1.
(None)
Bug fixes
@ -23,6 +25,13 @@ New features
1. LUCENE-1320: ShingleMatrixFilter, multidimensional shingle token filter. (Karl Wettin)
2. LUCENE-1142: Updated Snowball package, org.tartarus distribution revision 500.
Introducing Hungarian, Turkish and Romanian support, updated older stemmers
and optimized (reflectionless) SnowballFilter.
IMPORTANT NOTICE ON BACKWARDS COMPATIBILITY: an index created using the 2.3.2 (or older)
might not be compatible with these updated classes as some algorithms have changed.
(Karl Wettin)
Documentation
(None)

View File

@ -1,16 +1,18 @@
Lucene Snowball README file
$Id$
INTRODUCTION
This project provides pre-compiled version of the Snowball stemmers
based on revision 500 of the Tartarus Snowball repository,
together with classes integrating them with the Lucene search engine.
More documentation is provided in the 'docs' subdirectory.
For more information on Lucene, see:
http://jakarta.apache.org/lucene
IMPORTANT NOTICE ON BACKWARDS COMPATIBILITY!
An index created using the Snowball module in Lucene 2.3.2 and below
might not be compatible with the Snowball module in Lucene 2.4 or greater.
For more information about this issue see:
https://issues.apache.org/jira/browse/LUCENE-1142
For more information on Snowball, see:
http://snowball.tartarus.org/

View File

@ -1,90 +0,0 @@
package net.sf.snowball;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import java.lang.reflect.Method;
import java.io.Reader;
import java.io.Writer;
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.FileInputStream;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.OutputStream;
import java.io.FileOutputStream;
public class TestApp {
public static void main(String[] args) throws Throwable {
if (args.length < 2) {
exitWithUsage();
}
Class stemClass = Class.forName("net.sf.snowball.ext." +
args[0] + "Stemmer");
SnowballProgram stemmer = (SnowballProgram) stemClass.newInstance();
Method stemMethod = stemClass.getMethod("stem", new Class[0]);
Reader reader;
reader = new InputStreamReader(new FileInputStream(args[1]));
reader = new BufferedReader(reader);
StringBuffer input = new StringBuffer();
OutputStream outstream = System.out;
if (args.length > 2 && args[2].equals("-o")) {
outstream = new FileOutputStream(args[3]);
} else if (args.length > 2) {
exitWithUsage();
}
Writer output = new OutputStreamWriter(outstream);
output = new BufferedWriter(output);
int repeat = 1;
if (args.length > 4) {
repeat = Integer.parseInt(args[4]);
}
Object[] emptyArgs = new Object[0];
int character;
while ((character = reader.read()) != -1) {
char ch = (char) character;
if (Character.isWhitespace(ch)) {
if (input.length() > 0) {
stemmer.setCurrent(input.toString());
for (int i = repeat; i != 0; i--) {
stemMethod.invoke(stemmer, emptyArgs);
}
output.write(stemmer.getCurrent());
output.write('\n');
input.delete(0, input.length());
}
} else {
input.append(Character.toLowerCase(ch));
}
}
output.flush();
}
private static void exitWithUsage() {
System.err.println("Usage: TestApp <stemmer name> <input file> [-o <output file>]");
System.exit(1);
}
}

View File

@ -1,5 +0,0 @@
<html>
<body>
Snowball generated stemmer classes.
</body>
</html>

View File

@ -1,5 +0,0 @@
<html>
<body>
Snowball system classes.
</body>
</html>

View File

@ -20,8 +20,6 @@ package org.apache.lucene.analysis.snowball;
import org.apache.lucene.analysis.*;
import org.apache.lucene.analysis.standard.*;
import net.sf.snowball.ext.*;
import java.io.Reader;
import java.util.Set;
@ -30,7 +28,7 @@ import java.util.Set;
*
* Available stemmers are listed in {@link net.sf.snowball.ext}. The name of a
* stemmer is the part of the class name before "Stemmer", e.g., the stemmer in
* {@link EnglishStemmer} is named "English".
* {@link org.tartarus.snowball.ext.EnglishStemmer} is named "English".
*/
public class SnowballAnalyzer extends Analyzer {
private String name;

View File

@ -18,41 +18,41 @@ package org.apache.lucene.analysis.snowball;
*/
import java.io.IOException;
import java.lang.reflect.Method;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.ext.EnglishStemmer;
import org.apache.lucene.analysis.Token;
import org.apache.lucene.analysis.TokenFilter;
import org.apache.lucene.analysis.TokenStream;
import org.tartarus.snowball.SnowballProgram;
/** A filter that stems words using a Snowball-generated stemmer.
/**
* A filter that stems words using a Snowball-generated stemmer.
*
* Available stemmers are listed in {@link net.sf.snowball.ext}. The name of a
* stemmer is the part of the class name before "Stemmer", e.g., the stemmer in
* {@link EnglishStemmer} is named "English".
* Available stemmers are listed in {@link org.tartarus.snowball.ext}.
*/
public class SnowballFilter extends TokenFilter {
private static final Object [] EMPTY_ARGS = new Object[0];
private SnowballProgram stemmer;
private Method stemMethod;
/** Construct the named stemming filter.
public SnowballFilter(TokenStream input, SnowballProgram stemmer) {
super(input);
this.stemmer = stemmer;
}
/**
* Construct the named stemming filter.
*
* Available stemmers are listed in {@link org.tartarus.snowball.ext}.
* The name of a stemmer is the part of the class name before "Stemmer",
* e.g., the stemmer in {@link org.tartarus.snowball.ext.EnglishStemmer} is named "English".
*
* @param in the input tokens to stem
* @param name the name of a stemmer
*/
public SnowballFilter(TokenStream in, String name) {
super(in);
try {
Class stemClass =
Class.forName("net.sf.snowball.ext." + name + "Stemmer");
try {
Class stemClass = Class.forName("org.tartarus.snowball.ext." + name + "Stemmer");
stemmer = (SnowballProgram) stemClass.newInstance();
// why doesn't the SnowballProgram class have an (abstract?) stem method?
stemMethod = stemClass.getMethod("stem", new Class[0]);
} catch (Exception e) {
throw new RuntimeException(e.toString());
}
@ -66,11 +66,7 @@ public class SnowballFilter extends TokenFilter {
return null;
String originalTerm = nextToken.term();
stemmer.setCurrent(originalTerm);
try {
stemMethod.invoke(stemmer, EMPTY_ARGS);
} catch (Exception e) {
throw new RuntimeException(e.toString());
}
stemmer.stem();
String finalTerm = stemmer.getCurrent();
// Don't bother updating, if it is unchanged.
if (!originalTerm.equals(finalTerm))

View File

@ -1,21 +1,5 @@
package net.sf.snowball;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.tartarus.snowball;
import java.lang.reflect.Method;

View File

@ -1,31 +1,22 @@
package net.sf.snowball;
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.tartarus.snowball;
import java.lang.reflect.InvocationTargetException;
public class SnowballProgram {
/**
* This is the rev 500 of the Snowball SVN trunk,
* but modified:
* made abstract and introduced abstract method stem
* to avoid expensive
*/
public abstract class SnowballProgram {
protected SnowballProgram()
{
current = new StringBuffer();
setCurrent("");
}
public abstract boolean stem();
/**
* Set the current string.
*/
@ -44,7 +35,15 @@ public class SnowballProgram {
*/
public String getCurrent()
{
return current.toString();
String result = current.toString();
// Make a new StringBuffer. If we reuse the old one, and a user of
// the library keeps a reference to the buffer returned (for example,
// by converting it to a String in a way which doesn't force a copy),
// the buffer size will not decrease, and we will risk wasting a large
// amount of memory.
// Thanks to Wolfram Esser for spotting this problem.
current = new StringBuffer();
return result;
}
// current string
@ -334,7 +333,7 @@ public class SnowballProgram {
protected int replace_s(int c_bra, int c_ket, String s)
{
int adjustment = s.length() - (c_ket - c_bra);
current.replace(bra, ket, s);
current.replace(c_bra, c_ket, s);
limit += adjustment;
if (cursor >= c_ket) cursor += adjustment;
else if (cursor > c_bra) cursor = c_bra;
@ -425,4 +424,3 @@ extern void debug(struct SN_env * z, int number, int line_count)
};

View File

@ -0,0 +1,78 @@
package org.tartarus.snowball;
import java.lang.reflect.Method;
import java.io.Reader;
import java.io.Writer;
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.FileInputStream;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.OutputStream;
import java.io.FileOutputStream;
public class TestApp {
private static void usage()
{
System.err.println("Usage: TestApp <algorithm> <input file> [-o <output file>]");
}
public static void main(String [] args) throws Throwable {
if (args.length < 2) {
usage();
return;
}
Class stemClass = Class.forName("org.tartarus.snowball.ext." +
args[0] + "Stemmer");
SnowballProgram stemmer = (SnowballProgram) stemClass.newInstance();
Method stemMethod = stemClass.getMethod("stem", new Class[0]);
Reader reader;
reader = new InputStreamReader(new FileInputStream(args[1]));
reader = new BufferedReader(reader);
StringBuffer input = new StringBuffer();
OutputStream outstream;
if (args.length > 2) {
if (args.length == 4 && args[2].equals("-o")) {
outstream = new FileOutputStream(args[3]);
} else {
usage();
return;
}
} else {
outstream = System.out;
}
Writer output = new OutputStreamWriter(outstream);
output = new BufferedWriter(output);
int repeat = 1;
if (args.length > 4) {
repeat = Integer.parseInt(args[4]);
}
Object [] emptyArgs = new Object[0];
int character;
while ((character = reader.read()) != -1) {
char ch = (char) character;
if (Character.isWhitespace((char) ch)) {
if (input.length() > 0) {
stemmer.setCurrent(input.toString());
for (int i = repeat; i != 0; i--) {
stemMethod.invoke(stemmer, emptyArgs);
}
output.write(stemmer.getCurrent());
output.write('\n');
input.delete(0, input.length());
}
} else {
input.append(Character.toLowerCase(ch));
}
}
output.flush();
}
}

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -63,10 +63,12 @@ public class DanishStemmer extends SnowballProgram {
private static final char g_s_ending[] = {239, 254, 42, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16 };
private int I_x;
private int I_p1;
private StringBuffer S_ch = new StringBuffer();
private void copy_from(DanishStemmer other) {
I_x = other.I_x;
I_p1 = other.I_p1;
S_ch = other.S_ch;
super.copy_from(other);
@ -74,28 +76,44 @@ public class DanishStemmer extends SnowballProgram {
private boolean r_mark_regions() {
int v_1;
int v_2;
// (, line 29
I_p1 = limit;
// goto, line 33
// test, line 33
v_1 = cursor;
// (, line 33
// hop, line 33
{
int c = cursor + 3;
if (0 > c || c > limit)
{
return false;
}
cursor = c;
}
// setmark x, line 33
I_x = cursor;
cursor = v_1;
// goto, line 34
golab0: while(true)
{
v_1 = cursor;
v_2 = cursor;
lab1: do {
if (!(in_grouping(g_v, 97, 248)))
{
break lab1;
}
cursor = v_1;
cursor = v_2;
break golab0;
} while (false);
cursor = v_1;
cursor = v_2;
if (cursor >= limit)
{
return false;
}
cursor++;
}
// gopast, line 33
// gopast, line 34
golab2: while(true)
{
lab3: do {
@ -111,16 +129,16 @@ public class DanishStemmer extends SnowballProgram {
}
cursor++;
}
// setmark p1, line 33
// setmark p1, line 34
I_p1 = cursor;
// try, line 34
// try, line 35
lab4: do {
// (, line 34
if (!(I_p1 < 3))
// (, line 35
if (!(I_p1 < I_x))
{
break lab4;
}
I_p1 = 3;
I_p1 = I_x;
} while (false);
return true;
}
@ -129,10 +147,10 @@ public class DanishStemmer extends SnowballProgram {
int among_var;
int v_1;
int v_2;
// (, line 39
// setlimit, line 40
// (, line 40
// setlimit, line 41
v_1 = limit - cursor;
// tomark, line 40
// tomark, line 41
if (cursor < I_p1)
{
return false;
@ -141,34 +159,34 @@ public class DanishStemmer extends SnowballProgram {
v_2 = limit_backward;
limit_backward = cursor;
cursor = limit - v_1;
// (, line 40
// [, line 40
// (, line 41
// [, line 41
ket = cursor;
// substring, line 40
// substring, line 41
among_var = find_among_b(a_0, 32);
if (among_var == 0)
{
limit_backward = v_2;
return false;
}
// ], line 40
// ], line 41
bra = cursor;
limit_backward = v_2;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 47
// delete, line 47
// (, line 48
// delete, line 48
slice_del();
break;
case 2:
// (, line 49
// (, line 50
if (!(in_grouping_b(g_s_ending, 97, 229)))
{
return false;
}
// delete, line 49
// delete, line 50
slice_del();
break;
}
@ -179,13 +197,13 @@ public class DanishStemmer extends SnowballProgram {
int v_1;
int v_2;
int v_3;
// (, line 53
// test, line 54
v_1 = limit - cursor;
// (, line 54
// setlimit, line 55
// test, line 55
v_1 = limit - cursor;
// (, line 55
// setlimit, line 56
v_2 = limit - cursor;
// tomark, line 55
// tomark, line 56
if (cursor < I_p1)
{
return false;
@ -194,28 +212,28 @@ public class DanishStemmer extends SnowballProgram {
v_3 = limit_backward;
limit_backward = cursor;
cursor = limit - v_2;
// (, line 55
// [, line 55
// (, line 56
// [, line 56
ket = cursor;
// substring, line 55
// substring, line 56
if (find_among_b(a_1, 4) == 0)
{
limit_backward = v_3;
return false;
}
// ], line 55
// ], line 56
bra = cursor;
limit_backward = v_3;
cursor = limit - v_1;
// next, line 61
// next, line 62
if (cursor <= limit_backward)
{
return false;
}
cursor--;
// ], line 61
// ], line 62
bra = cursor;
// delete, line 61
// delete, line 62
slice_del();
return true;
}
@ -226,32 +244,32 @@ public class DanishStemmer extends SnowballProgram {
int v_2;
int v_3;
int v_4;
// (, line 64
// do, line 65
// (, line 65
// do, line 66
v_1 = limit - cursor;
lab0: do {
// (, line 65
// [, line 65
// (, line 66
// [, line 66
ket = cursor;
// literal, line 65
// literal, line 66
if (!(eq_s_b(2, "st")))
{
break lab0;
}
// ], line 65
// ], line 66
bra = cursor;
// literal, line 65
// literal, line 66
if (!(eq_s_b(2, "ig")))
{
break lab0;
}
// delete, line 65
// delete, line 66
slice_del();
} while (false);
cursor = limit - v_1;
// setlimit, line 66
// setlimit, line 67
v_2 = limit - cursor;
// tomark, line 66
// tomark, line 67
if (cursor < I_p1)
{
return false;
@ -260,30 +278,30 @@ public class DanishStemmer extends SnowballProgram {
v_3 = limit_backward;
limit_backward = cursor;
cursor = limit - v_2;
// (, line 66
// [, line 66
// (, line 67
// [, line 67
ket = cursor;
// substring, line 66
// substring, line 67
among_var = find_among_b(a_2, 5);
if (among_var == 0)
{
limit_backward = v_3;
return false;
}
// ], line 66
// ], line 67
bra = cursor;
limit_backward = v_3;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 69
// delete, line 69
// (, line 70
// delete, line 70
slice_del();
// do, line 69
// do, line 70
v_4 = limit - cursor;
lab1: do {
// call consonant_pair, line 69
// call consonant_pair, line 70
if (!r_consonant_pair())
{
break lab1;
@ -292,8 +310,8 @@ public class DanishStemmer extends SnowballProgram {
cursor = limit - v_4;
break;
case 2:
// (, line 71
// <-, line 71
// (, line 72
// <-, line 72
slice_from("l\u00F8s");
break;
}
@ -303,10 +321,10 @@ public class DanishStemmer extends SnowballProgram {
private boolean r_undouble() {
int v_1;
int v_2;
// (, line 74
// setlimit, line 75
// (, line 75
// setlimit, line 76
v_1 = limit - cursor;
// tomark, line 75
// tomark, line 76
if (cursor < I_p1)
{
return false;
@ -315,25 +333,25 @@ public class DanishStemmer extends SnowballProgram {
v_2 = limit_backward;
limit_backward = cursor;
cursor = limit - v_1;
// (, line 75
// [, line 75
// (, line 76
// [, line 76
ket = cursor;
if (!(out_grouping_b(g_v, 97, 248)))
{
limit_backward = v_2;
return false;
}
// ], line 75
// ], line 76
bra = cursor;
// -> ch, line 75
// -> ch, line 76
S_ch = slice_to(S_ch);
limit_backward = v_2;
// name ch, line 76
// name ch, line 77
if (!(eq_v_b(S_ch)))
{
return false;
}
// delete, line 77
// delete, line 78
slice_del();
return true;
}
@ -344,54 +362,54 @@ public class DanishStemmer extends SnowballProgram {
int v_3;
int v_4;
int v_5;
// (, line 81
// do, line 83
// (, line 82
// do, line 84
v_1 = cursor;
lab0: do {
// call mark_regions, line 83
// call mark_regions, line 84
if (!r_mark_regions())
{
break lab0;
}
} while (false);
cursor = v_1;
// backwards, line 84
// backwards, line 85
limit_backward = cursor; cursor = limit;
// (, line 84
// do, line 85
// (, line 85
// do, line 86
v_2 = limit - cursor;
lab1: do {
// call main_suffix, line 85
// call main_suffix, line 86
if (!r_main_suffix())
{
break lab1;
}
} while (false);
cursor = limit - v_2;
// do, line 86
// do, line 87
v_3 = limit - cursor;
lab2: do {
// call consonant_pair, line 86
// call consonant_pair, line 87
if (!r_consonant_pair())
{
break lab2;
}
} while (false);
cursor = limit - v_3;
// do, line 87
// do, line 88
v_4 = limit - cursor;
lab3: do {
// call other_suffix, line 87
// call other_suffix, line 88
if (!r_other_suffix())
{
break lab3;
}
} while (false);
cursor = limit - v_4;
// do, line 88
// do, line 89
v_5 = limit - cursor;
lab4: do {
// call undouble, line 88
// call undouble, line 89
if (!r_undouble())
{
break lab4;

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -129,9 +129,9 @@ public class FinnishStemmer extends SnowballProgram {
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_V1[] = {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_V2[] = {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 };
@ -159,7 +159,7 @@ public class FinnishStemmer extends SnowballProgram {
{
v_1 = cursor;
lab1: do {
if (!(in_grouping(g_v, 97, 246)))
if (!(in_grouping(g_V1, 97, 246)))
{
break lab1;
}
@ -177,7 +177,7 @@ public class FinnishStemmer extends SnowballProgram {
golab2: while(true)
{
lab3: do {
if (!(out_grouping(g_v, 97, 246)))
if (!(out_grouping(g_V1, 97, 246)))
{
break lab3;
}
@ -196,7 +196,7 @@ public class FinnishStemmer extends SnowballProgram {
{
v_3 = cursor;
lab5: do {
if (!(in_grouping(g_v, 97, 246)))
if (!(in_grouping(g_V1, 97, 246)))
{
break lab5;
}
@ -214,7 +214,7 @@ public class FinnishStemmer extends SnowballProgram {
golab6: while(true)
{
lab7: do {
if (!(out_grouping(g_v, 97, 246)))
if (!(out_grouping(g_V1, 97, 246)))
{
break lab7;
}
@ -414,14 +414,14 @@ public class FinnishStemmer extends SnowballProgram {
{
return false;
}
if (!(in_grouping_b(g_V, 97, 246)))
if (!(in_grouping_b(g_V2, 97, 246)))
{
return false;
}
return true;
}
private boolean r_case() {
private boolean r_case_ending() {
int among_var;
int v_1;
int v_2;
@ -545,11 +545,11 @@ public class FinnishStemmer extends SnowballProgram {
break;
case 8:
// (, line 119
if (!(in_grouping_b(g_v, 97, 246)))
if (!(in_grouping_b(g_V1, 97, 246)))
{
return false;
}
if (!(out_grouping_b(g_v, 97, 246)))
if (!(out_grouping_b(g_V1, 97, 246)))
{
return false;
}
@ -690,7 +690,7 @@ public class FinnishStemmer extends SnowballProgram {
bra = cursor;
// test, line 162
v_3 = limit - cursor;
if (!(in_grouping_b(g_v, 97, 246)))
if (!(in_grouping_b(g_V1, 97, 246)))
{
limit_backward = v_2;
return false;
@ -810,7 +810,7 @@ public class FinnishStemmer extends SnowballProgram {
}
// ], line 175
bra = cursor;
if (!(out_grouping_b(g_v, 97, 246)))
if (!(out_grouping_b(g_V1, 97, 246)))
{
break lab1;
}
@ -881,7 +881,7 @@ public class FinnishStemmer extends SnowballProgram {
{
v_9 = limit - cursor;
lab7: do {
if (!(out_grouping_b(g_v, 97, 246)))
if (!(out_grouping_b(g_V1, 97, 246)))
{
break lab7;
}
@ -966,8 +966,8 @@ public class FinnishStemmer extends SnowballProgram {
// do, line 190
v_4 = limit - cursor;
lab3: do {
// call case, line 190
if (!r_case())
// call case_ending, line 190
if (!r_case_ending())
{
break lab3;
}

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -66,10 +66,12 @@ public class German2Stemmer extends SnowballProgram {
private static final char g_st_ending[] = {117, 30, 4 };
private int I_x;
private int I_p2;
private int I_p1;
private void copy_from(German2Stemmer other) {
I_x = other.I_x;
I_p2 = other.I_p2;
I_p1 = other.I_p1;
super.copy_from(other);
@ -224,10 +226,26 @@ public class German2Stemmer extends SnowballProgram {
}
private boolean r_mark_regions() {
int v_1;
// (, line 48
I_p1 = limit;
I_p2 = limit;
// gopast, line 53
// test, line 53
v_1 = cursor;
// (, line 53
// hop, line 53
{
int c = cursor + 3;
if (0 > c || c > limit)
{
return false;
}
cursor = c;
}
// setmark x, line 53
I_x = cursor;
cursor = v_1;
// gopast, line 55
golab0: while(true)
{
lab1: do {
@ -243,7 +261,7 @@ public class German2Stemmer extends SnowballProgram {
}
cursor++;
}
// gopast, line 53
// gopast, line 55
golab2: while(true)
{
lab3: do {
@ -259,18 +277,18 @@ public class German2Stemmer extends SnowballProgram {
}
cursor++;
}
// setmark p1, line 53
// setmark p1, line 55
I_p1 = cursor;
// try, line 54
// try, line 56
lab4: do {
// (, line 54
if (!(I_p1 < 3))
// (, line 56
if (!(I_p1 < I_x))
{
break lab4;
}
I_p1 = 3;
I_p1 = I_x;
} while (false);
// gopast, line 55
// gopast, line 57
golab5: while(true)
{
lab6: do {
@ -286,7 +304,7 @@ public class German2Stemmer extends SnowballProgram {
}
cursor++;
}
// gopast, line 55
// gopast, line 57
golab7: while(true)
{
lab8: do {
@ -302,7 +320,7 @@ public class German2Stemmer extends SnowballProgram {
}
cursor++;
}
// setmark p2, line 55
// setmark p2, line 57
I_p2 = cursor;
return true;
}
@ -310,53 +328,53 @@ public class German2Stemmer extends SnowballProgram {
private boolean r_postlude() {
int among_var;
int v_1;
// repeat, line 59
// repeat, line 61
replab0: while(true)
{
v_1 = cursor;
lab1: do {
// (, line 59
// [, line 61
// (, line 61
// [, line 63
bra = cursor;
// substring, line 61
// substring, line 63
among_var = find_among(a_1, 6);
if (among_var == 0)
{
break lab1;
}
// ], line 61
// ], line 63
ket = cursor;
switch(among_var) {
case 0:
break lab1;
case 1:
// (, line 62
// <-, line 62
// (, line 64
// <-, line 64
slice_from("y");
break;
case 2:
// (, line 63
// <-, line 63
// (, line 65
// <-, line 65
slice_from("u");
break;
case 3:
// (, line 64
// <-, line 64
// (, line 66
// <-, line 66
slice_from("a");
break;
case 4:
// (, line 65
// <-, line 65
// (, line 67
// <-, line 67
slice_from("o");
break;
case 5:
// (, line 66
// <-, line 66
// (, line 68
// <-, line 68
slice_from("u");
break;
case 6:
// (, line 67
// next, line 67
// (, line 69
// next, line 69
if (cursor >= limit)
{
break lab1;
@ -399,22 +417,22 @@ public class German2Stemmer extends SnowballProgram {
int v_7;
int v_8;
int v_9;
// (, line 77
// do, line 78
// (, line 79
// do, line 80
v_1 = limit - cursor;
lab0: do {
// (, line 78
// [, line 79
// (, line 80
// [, line 81
ket = cursor;
// substring, line 79
// substring, line 81
among_var = find_among_b(a_2, 7);
if (among_var == 0)
{
break lab0;
}
// ], line 79
// ], line 81
bra = cursor;
// call R1, line 79
// call R1, line 81
if (!r_R1())
{
break lab0;
@ -423,37 +441,37 @@ public class German2Stemmer extends SnowballProgram {
case 0:
break lab0;
case 1:
// (, line 81
// delete, line 81
// (, line 83
// delete, line 83
slice_del();
break;
case 2:
// (, line 84
// (, line 86
if (!(in_grouping_b(g_s_ending, 98, 116)))
{
break lab0;
}
// delete, line 84
// delete, line 86
slice_del();
break;
}
} while (false);
cursor = limit - v_1;
// do, line 88
// do, line 90
v_2 = limit - cursor;
lab1: do {
// (, line 88
// [, line 89
// (, line 90
// [, line 91
ket = cursor;
// substring, line 89
// substring, line 91
among_var = find_among_b(a_3, 4);
if (among_var == 0)
{
break lab1;
}
// ], line 89
// ], line 91
bra = cursor;
// call R1, line 89
// call R1, line 91
if (!r_R1())
{
break lab1;
@ -462,17 +480,17 @@ public class German2Stemmer extends SnowballProgram {
case 0:
break lab1;
case 1:
// (, line 91
// delete, line 91
// (, line 93
// delete, line 93
slice_del();
break;
case 2:
// (, line 94
// (, line 96
if (!(in_grouping_b(g_st_ending, 98, 116)))
{
break lab1;
}
// hop, line 94
// hop, line 96
{
int c = cursor - 3;
if (limit_backward > c || c > limit)
@ -481,27 +499,27 @@ public class German2Stemmer extends SnowballProgram {
}
cursor = c;
}
// delete, line 94
// delete, line 96
slice_del();
break;
}
} while (false);
cursor = limit - v_2;
// do, line 98
// do, line 100
v_3 = limit - cursor;
lab2: do {
// (, line 98
// [, line 99
// (, line 100
// [, line 101
ket = cursor;
// substring, line 99
// substring, line 101
among_var = find_among_b(a_5, 8);
if (among_var == 0)
{
break lab2;
}
// ], line 99
// ], line 101
bra = cursor;
// call R2, line 99
// call R2, line 101
if (!r_R2())
{
break lab2;
@ -510,28 +528,28 @@ public class German2Stemmer extends SnowballProgram {
case 0:
break lab2;
case 1:
// (, line 101
// delete, line 101
// (, line 103
// delete, line 103
slice_del();
// try, line 102
// try, line 104
v_4 = limit - cursor;
lab3: do {
// (, line 102
// [, line 102
// (, line 104
// [, line 104
ket = cursor;
// literal, line 102
// literal, line 104
if (!(eq_s_b(2, "ig")))
{
cursor = limit - v_4;
break lab3;
}
// ], line 102
// ], line 104
bra = cursor;
// not, line 102
// not, line 104
{
v_5 = limit - cursor;
lab4: do {
// literal, line 102
// literal, line 104
if (!(eq_s_b(1, "e")))
{
break lab4;
@ -541,23 +559,23 @@ public class German2Stemmer extends SnowballProgram {
} while (false);
cursor = limit - v_5;
}
// call R2, line 102
// call R2, line 104
if (!r_R2())
{
cursor = limit - v_4;
break lab3;
}
// delete, line 102
// delete, line 104
slice_del();
} while (false);
break;
case 2:
// (, line 105
// not, line 105
// (, line 107
// not, line 107
{
v_6 = limit - cursor;
lab5: do {
// literal, line 105
// literal, line 107
if (!(eq_s_b(1, "e")))
{
break lab5;
@ -566,24 +584,24 @@ public class German2Stemmer extends SnowballProgram {
} while (false);
cursor = limit - v_6;
}
// delete, line 105
// delete, line 107
slice_del();
break;
case 3:
// (, line 108
// delete, line 108
// (, line 110
// delete, line 110
slice_del();
// try, line 109
// try, line 111
v_7 = limit - cursor;
lab6: do {
// (, line 109
// [, line 110
// (, line 111
// [, line 112
ket = cursor;
// or, line 110
// or, line 112
lab7: do {
v_8 = limit - cursor;
lab8: do {
// literal, line 110
// literal, line 112
if (!(eq_s_b(2, "er")))
{
break lab8;
@ -591,45 +609,45 @@ public class German2Stemmer extends SnowballProgram {
break lab7;
} while (false);
cursor = limit - v_8;
// literal, line 110
// literal, line 112
if (!(eq_s_b(2, "en")))
{
cursor = limit - v_7;
break lab6;
}
} while (false);
// ], line 110
// ], line 112
bra = cursor;
// call R1, line 110
// call R1, line 112
if (!r_R1())
{
cursor = limit - v_7;
break lab6;
}
// delete, line 110
// delete, line 112
slice_del();
} while (false);
break;
case 4:
// (, line 114
// delete, line 114
// (, line 116
// delete, line 116
slice_del();
// try, line 115
// try, line 117
v_9 = limit - cursor;
lab9: do {
// (, line 115
// [, line 116
// (, line 117
// [, line 118
ket = cursor;
// substring, line 116
// substring, line 118
among_var = find_among_b(a_4, 2);
if (among_var == 0)
{
cursor = limit - v_9;
break lab9;
}
// ], line 116
// ], line 118
bra = cursor;
// call R2, line 116
// call R2, line 118
if (!r_R2())
{
cursor = limit - v_9;
@ -640,8 +658,8 @@ public class German2Stemmer extends SnowballProgram {
cursor = limit - v_9;
break lab9;
case 1:
// (, line 118
// delete, line 118
// (, line 120
// delete, line 120
slice_del();
break;
}
@ -658,43 +676,43 @@ public class German2Stemmer extends SnowballProgram {
int v_2;
int v_3;
int v_4;
// (, line 128
// do, line 129
// (, line 130
// do, line 131
v_1 = cursor;
lab0: do {
// call prelude, line 129
// call prelude, line 131
if (!r_prelude())
{
break lab0;
}
} while (false);
cursor = v_1;
// do, line 130
// do, line 132
v_2 = cursor;
lab1: do {
// call mark_regions, line 130
// call mark_regions, line 132
if (!r_mark_regions())
{
break lab1;
}
} while (false);
cursor = v_2;
// backwards, line 131
// backwards, line 133
limit_backward = cursor; cursor = limit;
// do, line 132
// do, line 134
v_3 = limit - cursor;
lab2: do {
// call standard_suffix, line 132
// call standard_suffix, line 134
if (!r_standard_suffix())
{
break lab2;
}
} while (false);
cursor = limit - v_3;
cursor = limit_backward; // do, line 133
cursor = limit_backward; // do, line 135
v_4 = cursor;
lab3: do {
// call postlude, line 133
// call postlude, line 135
if (!r_postlude())
{
break lab3;

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -57,10 +57,12 @@ public class GermanStemmer extends SnowballProgram {
private static final char g_st_ending[] = {117, 30, 4 };
private int I_x;
private int I_p2;
private int I_p1;
private void copy_from(GermanStemmer other) {
I_x = other.I_x;
I_p2 = other.I_p2;
I_p1 = other.I_p1;
super.copy_from(other);
@ -186,10 +188,26 @@ public class GermanStemmer extends SnowballProgram {
}
private boolean r_mark_regions() {
int v_1;
// (, line 42
I_p1 = limit;
I_p2 = limit;
// gopast, line 47
// test, line 47
v_1 = cursor;
// (, line 47
// hop, line 47
{
int c = cursor + 3;
if (0 > c || c > limit)
{
return false;
}
cursor = c;
}
// setmark x, line 47
I_x = cursor;
cursor = v_1;
// gopast, line 49
golab0: while(true)
{
lab1: do {
@ -205,7 +223,7 @@ public class GermanStemmer extends SnowballProgram {
}
cursor++;
}
// gopast, line 47
// gopast, line 49
golab2: while(true)
{
lab3: do {
@ -221,18 +239,18 @@ public class GermanStemmer extends SnowballProgram {
}
cursor++;
}
// setmark p1, line 47
// setmark p1, line 49
I_p1 = cursor;
// try, line 48
// try, line 50
lab4: do {
// (, line 48
if (!(I_p1 < 3))
// (, line 50
if (!(I_p1 < I_x))
{
break lab4;
}
I_p1 = 3;
I_p1 = I_x;
} while (false);
// gopast, line 49
// gopast, line 51
golab5: while(true)
{
lab6: do {
@ -248,7 +266,7 @@ public class GermanStemmer extends SnowballProgram {
}
cursor++;
}
// gopast, line 49
// gopast, line 51
golab7: while(true)
{
lab8: do {
@ -264,7 +282,7 @@ public class GermanStemmer extends SnowballProgram {
}
cursor++;
}
// setmark p2, line 49
// setmark p2, line 51
I_p2 = cursor;
return true;
}
@ -272,53 +290,53 @@ public class GermanStemmer extends SnowballProgram {
private boolean r_postlude() {
int among_var;
int v_1;
// repeat, line 53
// repeat, line 55
replab0: while(true)
{
v_1 = cursor;
lab1: do {
// (, line 53
// [, line 55
// (, line 55
// [, line 57
bra = cursor;
// substring, line 55
// substring, line 57
among_var = find_among(a_0, 6);
if (among_var == 0)
{
break lab1;
}
// ], line 55
// ], line 57
ket = cursor;
switch(among_var) {
case 0:
break lab1;
case 1:
// (, line 56
// <-, line 56
// (, line 58
// <-, line 58
slice_from("y");
break;
case 2:
// (, line 57
// <-, line 57
// (, line 59
// <-, line 59
slice_from("u");
break;
case 3:
// (, line 58
// <-, line 58
// (, line 60
// <-, line 60
slice_from("a");
break;
case 4:
// (, line 59
// <-, line 59
// (, line 61
// <-, line 61
slice_from("o");
break;
case 5:
// (, line 60
// <-, line 60
// (, line 62
// <-, line 62
slice_from("u");
break;
case 6:
// (, line 61
// next, line 61
// (, line 63
// next, line 63
if (cursor >= limit)
{
break lab1;
@ -361,22 +379,22 @@ public class GermanStemmer extends SnowballProgram {
int v_7;
int v_8;
int v_9;
// (, line 71
// do, line 72
// (, line 73
// do, line 74
v_1 = limit - cursor;
lab0: do {
// (, line 72
// [, line 73
// (, line 74
// [, line 75
ket = cursor;
// substring, line 73
// substring, line 75
among_var = find_among_b(a_1, 7);
if (among_var == 0)
{
break lab0;
}
// ], line 73
// ], line 75
bra = cursor;
// call R1, line 73
// call R1, line 75
if (!r_R1())
{
break lab0;
@ -385,37 +403,37 @@ public class GermanStemmer extends SnowballProgram {
case 0:
break lab0;
case 1:
// (, line 75
// delete, line 75
// (, line 77
// delete, line 77
slice_del();
break;
case 2:
// (, line 78
// (, line 80
if (!(in_grouping_b(g_s_ending, 98, 116)))
{
break lab0;
}
// delete, line 78
// delete, line 80
slice_del();
break;
}
} while (false);
cursor = limit - v_1;
// do, line 82
// do, line 84
v_2 = limit - cursor;
lab1: do {
// (, line 82
// [, line 83
// (, line 84
// [, line 85
ket = cursor;
// substring, line 83
// substring, line 85
among_var = find_among_b(a_2, 4);
if (among_var == 0)
{
break lab1;
}
// ], line 83
// ], line 85
bra = cursor;
// call R1, line 83
// call R1, line 85
if (!r_R1())
{
break lab1;
@ -424,17 +442,17 @@ public class GermanStemmer extends SnowballProgram {
case 0:
break lab1;
case 1:
// (, line 85
// delete, line 85
// (, line 87
// delete, line 87
slice_del();
break;
case 2:
// (, line 88
// (, line 90
if (!(in_grouping_b(g_st_ending, 98, 116)))
{
break lab1;
}
// hop, line 88
// hop, line 90
{
int c = cursor - 3;
if (limit_backward > c || c > limit)
@ -443,27 +461,27 @@ public class GermanStemmer extends SnowballProgram {
}
cursor = c;
}
// delete, line 88
// delete, line 90
slice_del();
break;
}
} while (false);
cursor = limit - v_2;
// do, line 92
// do, line 94
v_3 = limit - cursor;
lab2: do {
// (, line 92
// [, line 93
// (, line 94
// [, line 95
ket = cursor;
// substring, line 93
// substring, line 95
among_var = find_among_b(a_4, 8);
if (among_var == 0)
{
break lab2;
}
// ], line 93
// ], line 95
bra = cursor;
// call R2, line 93
// call R2, line 95
if (!r_R2())
{
break lab2;
@ -472,28 +490,28 @@ public class GermanStemmer extends SnowballProgram {
case 0:
break lab2;
case 1:
// (, line 95
// delete, line 95
// (, line 97
// delete, line 97
slice_del();
// try, line 96
// try, line 98
v_4 = limit - cursor;
lab3: do {
// (, line 96
// [, line 96
// (, line 98
// [, line 98
ket = cursor;
// literal, line 96
// literal, line 98
if (!(eq_s_b(2, "ig")))
{
cursor = limit - v_4;
break lab3;
}
// ], line 96
// ], line 98
bra = cursor;
// not, line 96
// not, line 98
{
v_5 = limit - cursor;
lab4: do {
// literal, line 96
// literal, line 98
if (!(eq_s_b(1, "e")))
{
break lab4;
@ -503,23 +521,23 @@ public class GermanStemmer extends SnowballProgram {
} while (false);
cursor = limit - v_5;
}
// call R2, line 96
// call R2, line 98
if (!r_R2())
{
cursor = limit - v_4;
break lab3;
}
// delete, line 96
// delete, line 98
slice_del();
} while (false);
break;
case 2:
// (, line 99
// not, line 99
// (, line 101
// not, line 101
{
v_6 = limit - cursor;
lab5: do {
// literal, line 99
// literal, line 101
if (!(eq_s_b(1, "e")))
{
break lab5;
@ -528,24 +546,24 @@ public class GermanStemmer extends SnowballProgram {
} while (false);
cursor = limit - v_6;
}
// delete, line 99
// delete, line 101
slice_del();
break;
case 3:
// (, line 102
// delete, line 102
// (, line 104
// delete, line 104
slice_del();
// try, line 103
// try, line 105
v_7 = limit - cursor;
lab6: do {
// (, line 103
// [, line 104
// (, line 105
// [, line 106
ket = cursor;
// or, line 104
// or, line 106
lab7: do {
v_8 = limit - cursor;
lab8: do {
// literal, line 104
// literal, line 106
if (!(eq_s_b(2, "er")))
{
break lab8;
@ -553,45 +571,45 @@ public class GermanStemmer extends SnowballProgram {
break lab7;
} while (false);
cursor = limit - v_8;
// literal, line 104
// literal, line 106
if (!(eq_s_b(2, "en")))
{
cursor = limit - v_7;
break lab6;
}
} while (false);
// ], line 104
// ], line 106
bra = cursor;
// call R1, line 104
// call R1, line 106
if (!r_R1())
{
cursor = limit - v_7;
break lab6;
}
// delete, line 104
// delete, line 106
slice_del();
} while (false);
break;
case 4:
// (, line 108
// delete, line 108
// (, line 110
// delete, line 110
slice_del();
// try, line 109
// try, line 111
v_9 = limit - cursor;
lab9: do {
// (, line 109
// [, line 110
// (, line 111
// [, line 112
ket = cursor;
// substring, line 110
// substring, line 112
among_var = find_among_b(a_3, 2);
if (among_var == 0)
{
cursor = limit - v_9;
break lab9;
}
// ], line 110
// ], line 112
bra = cursor;
// call R2, line 110
// call R2, line 112
if (!r_R2())
{
cursor = limit - v_9;
@ -602,8 +620,8 @@ public class GermanStemmer extends SnowballProgram {
cursor = limit - v_9;
break lab9;
case 1:
// (, line 112
// delete, line 112
// (, line 114
// delete, line 114
slice_del();
break;
}
@ -620,43 +638,43 @@ public class GermanStemmer extends SnowballProgram {
int v_2;
int v_3;
int v_4;
// (, line 122
// do, line 123
// (, line 124
// do, line 125
v_1 = cursor;
lab0: do {
// call prelude, line 123
// call prelude, line 125
if (!r_prelude())
{
break lab0;
}
} while (false);
cursor = v_1;
// do, line 124
// do, line 126
v_2 = cursor;
lab1: do {
// call mark_regions, line 124
// call mark_regions, line 126
if (!r_mark_regions())
{
break lab1;
}
} while (false);
cursor = v_2;
// backwards, line 125
// backwards, line 127
limit_backward = cursor; cursor = limit;
// do, line 126
// do, line 128
v_3 = limit - cursor;
lab2: do {
// call standard_suffix, line 126
// call standard_suffix, line 128
if (!r_standard_suffix())
{
break lab2;
}
} while (false);
cursor = limit - v_3;
cursor = limit_backward; // do, line 127
cursor = limit_backward; // do, line 129
v_4 = cursor;
lab3: do {
// call postlude, line 127
// call postlude, line 129
if (!r_postlude())
{
break lab3;

File diff suppressed because it is too large Load Diff

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -105,14 +105,15 @@ public class ItalianStemmer extends SnowballProgram {
new Among ( "uzione", -1, 4, "", this),
new Among ( "atore", -1, 2, "", this),
new Among ( "ose", -1, 1, "", this),
new Among ( "ante", -1, 1, "", this),
new Among ( "mente", -1, 1, "", this),
new Among ( "amente", 18, 7, "", this),
new Among ( "amente", 19, 7, "", this),
new Among ( "iste", -1, 1, "", this),
new Among ( "ive", -1, 9, "", this),
new Among ( "anze", -1, 1, "", this),
new Among ( "enze", -1, 5, "", this),
new Among ( "ici", -1, 1, "", this),
new Among ( "atrici", 24, 1, "", this),
new Among ( "atrici", 25, 1, "", this),
new Among ( "ichi", -1, 1, "", this),
new Among ( "abili", -1, 1, "", this),
new Among ( "ibili", -1, 1, "", this),
@ -122,6 +123,7 @@ public class ItalianStemmer extends SnowballProgram {
new Among ( "uzioni", -1, 4, "", this),
new Among ( "atori", -1, 2, "", this),
new Among ( "osi", -1, 1, "", this),
new Among ( "anti", -1, 1, "", this),
new Among ( "amenti", -1, 6, "", this),
new Among ( "imenti", -1, 6, "", this),
new Among ( "isti", -1, 1, "", this),
@ -719,7 +721,7 @@ public class ItalianStemmer extends SnowballProgram {
// [, line 104
ket = cursor;
// substring, line 104
among_var = find_among_b(a_6, 49);
among_var = find_among_b(a_6, 51);
if (among_var == 0)
{
return false;
@ -730,238 +732,238 @@ public class ItalianStemmer extends SnowballProgram {
case 0:
return false;
case 1:
// (, line 110
// call R2, line 110
// (, line 111
// call R2, line 111
if (!r_R2())
{
return false;
}
// delete, line 110
// delete, line 111
slice_del();
break;
case 2:
// (, line 112
// call R2, line 112
// (, line 113
// call R2, line 113
if (!r_R2())
{
return false;
}
// delete, line 112
// delete, line 113
slice_del();
// try, line 113
// try, line 114
v_1 = limit - cursor;
lab0: do {
// (, line 113
// [, line 113
// (, line 114
// [, line 114
ket = cursor;
// literal, line 113
// literal, line 114
if (!(eq_s_b(2, "ic")))
{
cursor = limit - v_1;
break lab0;
}
// ], line 113
// ], line 114
bra = cursor;
// call R2, line 113
// call R2, line 114
if (!r_R2())
{
cursor = limit - v_1;
break lab0;
}
// delete, line 113
// delete, line 114
slice_del();
} while (false);
break;
case 3:
// (, line 116
// call R2, line 116
// (, line 117
// call R2, line 117
if (!r_R2())
{
return false;
}
// <-, line 116
// <-, line 117
slice_from("log");
break;
case 4:
// (, line 118
// call R2, line 118
// (, line 119
// call R2, line 119
if (!r_R2())
{
return false;
}
// <-, line 118
// <-, line 119
slice_from("u");
break;
case 5:
// (, line 120
// call R2, line 120
// (, line 121
// call R2, line 121
if (!r_R2())
{
return false;
}
// <-, line 120
// <-, line 121
slice_from("ente");
break;
case 6:
// (, line 122
// call RV, line 122
// (, line 123
// call RV, line 123
if (!r_RV())
{
return false;
}
// delete, line 122
// delete, line 123
slice_del();
break;
case 7:
// (, line 123
// call R1, line 124
// (, line 124
// call R1, line 125
if (!r_R1())
{
return false;
}
// delete, line 124
// delete, line 125
slice_del();
// try, line 125
// try, line 126
v_2 = limit - cursor;
lab1: do {
// (, line 125
// [, line 126
// (, line 126
// [, line 127
ket = cursor;
// substring, line 126
// substring, line 127
among_var = find_among_b(a_4, 4);
if (among_var == 0)
{
cursor = limit - v_2;
break lab1;
}
// ], line 126
// ], line 127
bra = cursor;
// call R2, line 126
// call R2, line 127
if (!r_R2())
{
cursor = limit - v_2;
break lab1;
}
// delete, line 126
// delete, line 127
slice_del();
switch(among_var) {
case 0:
cursor = limit - v_2;
break lab1;
case 1:
// (, line 127
// [, line 127
// (, line 128
// [, line 128
ket = cursor;
// literal, line 127
// literal, line 128
if (!(eq_s_b(2, "at")))
{
cursor = limit - v_2;
break lab1;
}
// ], line 127
// ], line 128
bra = cursor;
// call R2, line 127
// call R2, line 128
if (!r_R2())
{
cursor = limit - v_2;
break lab1;
}
// delete, line 127
// delete, line 128
slice_del();
break;
}
} while (false);
break;
case 8:
// (, line 132
// call R2, line 133
// (, line 133
// call R2, line 134
if (!r_R2())
{
return false;
}
// delete, line 133
// delete, line 134
slice_del();
// try, line 134
// try, line 135
v_3 = limit - cursor;
lab2: do {
// (, line 134
// [, line 135
// (, line 135
// [, line 136
ket = cursor;
// substring, line 135
// substring, line 136
among_var = find_among_b(a_5, 3);
if (among_var == 0)
{
cursor = limit - v_3;
break lab2;
}
// ], line 135
// ], line 136
bra = cursor;
switch(among_var) {
case 0:
cursor = limit - v_3;
break lab2;
case 1:
// (, line 136
// call R2, line 136
// (, line 137
// call R2, line 137
if (!r_R2())
{
cursor = limit - v_3;
break lab2;
}
// delete, line 136
// delete, line 137
slice_del();
break;
}
} while (false);
break;
case 9:
// (, line 140
// call R2, line 141
// (, line 141
// call R2, line 142
if (!r_R2())
{
return false;
}
// delete, line 141
// delete, line 142
slice_del();
// try, line 142
// try, line 143
v_4 = limit - cursor;
lab3: do {
// (, line 142
// [, line 142
// (, line 143
// [, line 143
ket = cursor;
// literal, line 142
// literal, line 143
if (!(eq_s_b(2, "at")))
{
cursor = limit - v_4;
break lab3;
}
// ], line 142
// ], line 143
bra = cursor;
// call R2, line 142
// call R2, line 143
if (!r_R2())
{
cursor = limit - v_4;
break lab3;
}
// delete, line 142
// delete, line 143
slice_del();
// [, line 142
// [, line 143
ket = cursor;
// literal, line 142
// literal, line 143
if (!(eq_s_b(2, "ic")))
{
cursor = limit - v_4;
break lab3;
}
// ], line 142
// ], line 143
bra = cursor;
// call R2, line 142
// call R2, line 143
if (!r_R2())
{
cursor = limit - v_4;
break lab3;
}
// delete, line 142
// delete, line 143
slice_del();
} while (false);
break;
@ -973,9 +975,9 @@ public class ItalianStemmer extends SnowballProgram {
int among_var;
int v_1;
int v_2;
// setlimit, line 147
// setlimit, line 148
v_1 = limit - cursor;
// tomark, line 147
// tomark, line 148
if (cursor < I_pV)
{
return false;
@ -984,25 +986,25 @@ public class ItalianStemmer extends SnowballProgram {
v_2 = limit_backward;
limit_backward = cursor;
cursor = limit - v_1;
// (, line 147
// [, line 148
// (, line 148
// [, line 149
ket = cursor;
// substring, line 148
// substring, line 149
among_var = find_among_b(a_7, 87);
if (among_var == 0)
{
limit_backward = v_2;
return false;
}
// ], line 148
// ], line 149
bra = cursor;
switch(among_var) {
case 0:
limit_backward = v_2;
return false;
case 1:
// (, line 162
// delete, line 162
// (, line 163
// delete, line 163
slice_del();
break;
}
@ -1013,32 +1015,14 @@ public class ItalianStemmer extends SnowballProgram {
private boolean r_vowel_suffix() {
int v_1;
int v_2;
// (, line 169
// try, line 170
// (, line 170
// try, line 171
v_1 = limit - cursor;
lab0: do {
// (, line 170
// [, line 171
ket = cursor;
if (!(in_grouping_b(g_AEIO, 97, 242)))
{
cursor = limit - v_1;
break lab0;
}
// ], line 171
bra = cursor;
// call RV, line 171
if (!r_RV())
{
cursor = limit - v_1;
break lab0;
}
// delete, line 171
slice_del();
// (, line 171
// [, line 172
ket = cursor;
// literal, line 172
if (!(eq_s_b(1, "i")))
if (!(in_grouping_b(g_AEIO, 97, 242)))
{
cursor = limit - v_1;
break lab0;
@ -1053,33 +1037,51 @@ public class ItalianStemmer extends SnowballProgram {
}
// delete, line 172
slice_del();
// [, line 173
ket = cursor;
// literal, line 173
if (!(eq_s_b(1, "i")))
{
cursor = limit - v_1;
break lab0;
}
// ], line 173
bra = cursor;
// call RV, line 173
if (!r_RV())
{
cursor = limit - v_1;
break lab0;
}
// delete, line 173
slice_del();
} while (false);
// try, line 174
// try, line 175
v_2 = limit - cursor;
lab1: do {
// (, line 174
// [, line 175
// (, line 175
// [, line 176
ket = cursor;
// literal, line 175
// literal, line 176
if (!(eq_s_b(1, "h")))
{
cursor = limit - v_2;
break lab1;
}
// ], line 175
// ], line 176
bra = cursor;
if (!(in_grouping_b(g_CG, 99, 103)))
{
cursor = limit - v_2;
break lab1;
}
// call RV, line 175
// call RV, line 176
if (!r_RV())
{
cursor = limit - v_2;
break lab1;
}
// delete, line 175
// delete, line 176
slice_del();
} while (false);
return true;
@ -1093,49 +1095,49 @@ public class ItalianStemmer extends SnowballProgram {
int v_5;
int v_6;
int v_7;
// (, line 180
// do, line 181
// (, line 181
// do, line 182
v_1 = cursor;
lab0: do {
// call prelude, line 181
// call prelude, line 182
if (!r_prelude())
{
break lab0;
}
} while (false);
cursor = v_1;
// do, line 182
// do, line 183
v_2 = cursor;
lab1: do {
// call mark_regions, line 182
// call mark_regions, line 183
if (!r_mark_regions())
{
break lab1;
}
} while (false);
cursor = v_2;
// backwards, line 183
// backwards, line 184
limit_backward = cursor; cursor = limit;
// (, line 183
// do, line 184
// (, line 184
// do, line 185
v_3 = limit - cursor;
lab2: do {
// call attached_pronoun, line 184
// call attached_pronoun, line 185
if (!r_attached_pronoun())
{
break lab2;
}
} while (false);
cursor = limit - v_3;
// do, line 185
// do, line 186
v_4 = limit - cursor;
lab3: do {
// (, line 185
// or, line 185
// (, line 186
// or, line 186
lab4: do {
v_5 = limit - cursor;
lab5: do {
// call standard_suffix, line 185
// call standard_suffix, line 186
if (!r_standard_suffix())
{
break lab5;
@ -1143,7 +1145,7 @@ public class ItalianStemmer extends SnowballProgram {
break lab4;
} while (false);
cursor = limit - v_5;
// call verb_suffix, line 185
// call verb_suffix, line 186
if (!r_verb_suffix())
{
break lab3;
@ -1151,20 +1153,20 @@ public class ItalianStemmer extends SnowballProgram {
} while (false);
} while (false);
cursor = limit - v_4;
// do, line 186
// do, line 187
v_6 = limit - cursor;
lab6: do {
// call vowel_suffix, line 186
// call vowel_suffix, line 187
if (!r_vowel_suffix())
{
break lab6;
}
} while (false);
cursor = limit - v_6;
cursor = limit_backward; // do, line 188
cursor = limit_backward; // do, line 189
v_7 = cursor;
lab7: do {
// call postlude, line 188
// call postlude, line 189
if (!r_postlude())
{
break lab7;

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -62,39 +62,57 @@ public class NorwegianStemmer extends SnowballProgram {
private static final char g_v[] = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 48, 0, 128 };
private static final char g_s_ending[] = {119, 127, 149, 1 };
private static final char g_s_ending[] = {119, 125, 149, 1 };
private int I_x;
private int I_p1;
private void copy_from(NorwegianStemmer other) {
I_x = other.I_x;
I_p1 = other.I_p1;
super.copy_from(other);
}
private boolean r_mark_regions() {
int v_1;
int v_2;
// (, line 26
I_p1 = limit;
// goto, line 30
// test, line 30
v_1 = cursor;
// (, line 30
// hop, line 30
{
int c = cursor + 3;
if (0 > c || c > limit)
{
return false;
}
cursor = c;
}
// setmark x, line 30
I_x = cursor;
cursor = v_1;
// goto, line 31
golab0: while(true)
{
v_1 = cursor;
v_2 = cursor;
lab1: do {
if (!(in_grouping(g_v, 97, 248)))
{
break lab1;
}
cursor = v_1;
cursor = v_2;
break golab0;
} while (false);
cursor = v_1;
cursor = v_2;
if (cursor >= limit)
{
return false;
}
cursor++;
}
// gopast, line 30
// gopast, line 31
golab2: while(true)
{
lab3: do {
@ -110,16 +128,16 @@ public class NorwegianStemmer extends SnowballProgram {
}
cursor++;
}
// setmark p1, line 30
// setmark p1, line 31
I_p1 = cursor;
// try, line 31
// try, line 32
lab4: do {
// (, line 31
if (!(I_p1 < 3))
// (, line 32
if (!(I_p1 < I_x))
{
break lab4;
}
I_p1 = 3;
I_p1 = I_x;
} while (false);
return true;
}
@ -128,10 +146,11 @@ public class NorwegianStemmer extends SnowballProgram {
int among_var;
int v_1;
int v_2;
// (, line 36
// setlimit, line 37
int v_3;
// (, line 37
// setlimit, line 38
v_1 = limit - cursor;
// tomark, line 37
// tomark, line 38
if (cursor < I_p1)
{
return false;
@ -140,39 +159,57 @@ public class NorwegianStemmer extends SnowballProgram {
v_2 = limit_backward;
limit_backward = cursor;
cursor = limit - v_1;
// (, line 37
// [, line 37
// (, line 38
// [, line 38
ket = cursor;
// substring, line 37
// substring, line 38
among_var = find_among_b(a_0, 29);
if (among_var == 0)
{
limit_backward = v_2;
return false;
}
// ], line 37
// ], line 38
bra = cursor;
limit_backward = v_2;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 43
// delete, line 43
// (, line 44
// delete, line 44
slice_del();
break;
case 2:
// (, line 45
if (!(in_grouping_b(g_s_ending, 98, 122)))
{
return false;
}
// delete, line 45
// (, line 46
// or, line 46
lab0: do {
v_3 = limit - cursor;
lab1: do {
if (!(in_grouping_b(g_s_ending, 98, 122)))
{
break lab1;
}
break lab0;
} while (false);
cursor = limit - v_3;
// (, line 46
// literal, line 46
if (!(eq_s_b(1, "k")))
{
return false;
}
if (!(out_grouping_b(g_v, 97, 248)))
{
return false;
}
} while (false);
// delete, line 46
slice_del();
break;
case 3:
// (, line 47
// <-, line 47
// (, line 48
// <-, line 48
slice_from("er");
break;
}
@ -183,13 +220,13 @@ public class NorwegianStemmer extends SnowballProgram {
int v_1;
int v_2;
int v_3;
// (, line 51
// test, line 52
v_1 = limit - cursor;
// (, line 52
// setlimit, line 53
// test, line 53
v_1 = limit - cursor;
// (, line 53
// setlimit, line 54
v_2 = limit - cursor;
// tomark, line 53
// tomark, line 54
if (cursor < I_p1)
{
return false;
@ -198,28 +235,28 @@ public class NorwegianStemmer extends SnowballProgram {
v_3 = limit_backward;
limit_backward = cursor;
cursor = limit - v_2;
// (, line 53
// [, line 53
// (, line 54
// [, line 54
ket = cursor;
// substring, line 53
// substring, line 54
if (find_among_b(a_1, 2) == 0)
{
limit_backward = v_3;
return false;
}
// ], line 53
// ], line 54
bra = cursor;
limit_backward = v_3;
cursor = limit - v_1;
// next, line 58
// next, line 59
if (cursor <= limit_backward)
{
return false;
}
cursor--;
// ], line 58
// ], line 59
bra = cursor;
// delete, line 58
// delete, line 59
slice_del();
return true;
}
@ -228,10 +265,10 @@ public class NorwegianStemmer extends SnowballProgram {
int among_var;
int v_1;
int v_2;
// (, line 61
// setlimit, line 62
// (, line 62
// setlimit, line 63
v_1 = limit - cursor;
// tomark, line 62
// tomark, line 63
if (cursor < I_p1)
{
return false;
@ -240,25 +277,25 @@ public class NorwegianStemmer extends SnowballProgram {
v_2 = limit_backward;
limit_backward = cursor;
cursor = limit - v_1;
// (, line 62
// [, line 62
// (, line 63
// [, line 63
ket = cursor;
// substring, line 62
// substring, line 63
among_var = find_among_b(a_2, 11);
if (among_var == 0)
{
limit_backward = v_2;
return false;
}
// ], line 62
// ], line 63
bra = cursor;
limit_backward = v_2;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 66
// delete, line 66
// (, line 67
// delete, line 67
slice_del();
break;
}
@ -270,44 +307,44 @@ public class NorwegianStemmer extends SnowballProgram {
int v_2;
int v_3;
int v_4;
// (, line 71
// do, line 73
// (, line 72
// do, line 74
v_1 = cursor;
lab0: do {
// call mark_regions, line 73
// call mark_regions, line 74
if (!r_mark_regions())
{
break lab0;
}
} while (false);
cursor = v_1;
// backwards, line 74
// backwards, line 75
limit_backward = cursor; cursor = limit;
// (, line 74
// do, line 75
// (, line 75
// do, line 76
v_2 = limit - cursor;
lab1: do {
// call main_suffix, line 75
// call main_suffix, line 76
if (!r_main_suffix())
{
break lab1;
}
} while (false);
cursor = limit - v_2;
// do, line 76
// do, line 77
v_3 = limit - cursor;
lab2: do {
// call consonant_pair, line 76
// call consonant_pair, line 77
if (!r_consonant_pair())
{
break lab2;
}
} while (false);
cursor = limit - v_3;
// do, line 77
// do, line 78
v_4 = limit - cursor;
lab3: do {
// call other_suffix, line 77
// call other_suffix, line 78
if (!r_other_suffix())
{
break lab3;

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -29,6 +29,7 @@ public class PortugueseStemmer extends SnowballProgram {
};
private Among a_3[] = {
new Among ( "ante", -1, 1, "", this),
new Among ( "avel", -1, 1, "", this),
new Among ( "\u00EDvel", -1, 1, "", this)
};
@ -41,6 +42,7 @@ public class PortugueseStemmer extends SnowballProgram {
private Among a_5[] = {
new Among ( "ica", -1, 1, "", this),
new Among ( "\u00E2ncia", -1, 1, "", this),
new Among ( "\u00EAncia", -1, 4, "", this),
new Among ( "ira", -1, 9, "", this),
new Among ( "adora", -1, 1, "", this),
@ -50,8 +52,9 @@ public class PortugueseStemmer extends SnowballProgram {
new Among ( "eza", -1, 1, "", this),
new Among ( "log\u00EDa", -1, 2, "", this),
new Among ( "idade", -1, 7, "", this),
new Among ( "ante", -1, 1, "", this),
new Among ( "mente", -1, 6, "", this),
new Among ( "amente", 10, 5, "", this),
new Among ( "amente", 12, 5, "", this),
new Among ( "\u00E1vel", -1, 1, "", this),
new Among ( "\u00EDvel", -1, 1, "", this),
new Among ( "uci\u00F3n", -1, 3, "", this),
@ -75,6 +78,7 @@ public class PortugueseStemmer extends SnowballProgram {
new Among ( "idades", -1, 7, "", this),
new Among ( "uciones", -1, 3, "", this),
new Among ( "adores", -1, 1, "", this),
new Among ( "antes", -1, 1, "", this),
new Among ( "a\u00E7o~es", -1, 1, "", this),
new Among ( "icos", -1, 1, "", this),
new Among ( "ismos", -1, 1, "", this),
@ -574,7 +578,7 @@ public class PortugueseStemmer extends SnowballProgram {
// [, line 77
ket = cursor;
// substring, line 77
among_var = find_among_b(a_5, 42);
among_var = find_among_b(a_5, 45);
if (among_var == 0)
{
return false;
@ -585,235 +589,235 @@ public class PortugueseStemmer extends SnowballProgram {
case 0:
return false;
case 1:
// (, line 91
// call R2, line 92
// (, line 92
// call R2, line 93
if (!r_R2())
{
return false;
}
// delete, line 92
// delete, line 93
slice_del();
break;
case 2:
// (, line 96
// call R2, line 97
// (, line 97
// call R2, line 98
if (!r_R2())
{
return false;
}
// <-, line 97
// <-, line 98
slice_from("log");
break;
case 3:
// (, line 100
// call R2, line 101
// (, line 101
// call R2, line 102
if (!r_R2())
{
return false;
}
// <-, line 101
// <-, line 102
slice_from("u");
break;
case 4:
// (, line 104
// call R2, line 105
// (, line 105
// call R2, line 106
if (!r_R2())
{
return false;
}
// <-, line 105
// <-, line 106
slice_from("ente");
break;
case 5:
// (, line 108
// call R1, line 109
// (, line 109
// call R1, line 110
if (!r_R1())
{
return false;
}
// delete, line 109
// delete, line 110
slice_del();
// try, line 110
// try, line 111
v_1 = limit - cursor;
lab0: do {
// (, line 110
// [, line 111
// (, line 111
// [, line 112
ket = cursor;
// substring, line 111
// substring, line 112
among_var = find_among_b(a_2, 4);
if (among_var == 0)
{
cursor = limit - v_1;
break lab0;
}
// ], line 111
// ], line 112
bra = cursor;
// call R2, line 111
// call R2, line 112
if (!r_R2())
{
cursor = limit - v_1;
break lab0;
}
// delete, line 111
// delete, line 112
slice_del();
switch(among_var) {
case 0:
cursor = limit - v_1;
break lab0;
case 1:
// (, line 112
// [, line 112
// (, line 113
// [, line 113
ket = cursor;
// literal, line 112
// literal, line 113
if (!(eq_s_b(2, "at")))
{
cursor = limit - v_1;
break lab0;
}
// ], line 112
// ], line 113
bra = cursor;
// call R2, line 112
// call R2, line 113
if (!r_R2())
{
cursor = limit - v_1;
break lab0;
}
// delete, line 112
// delete, line 113
slice_del();
break;
}
} while (false);
break;
case 6:
// (, line 120
// call R2, line 121
// (, line 121
// call R2, line 122
if (!r_R2())
{
return false;
}
// delete, line 121
// delete, line 122
slice_del();
// try, line 122
// try, line 123
v_2 = limit - cursor;
lab1: do {
// (, line 122
// [, line 123
// (, line 123
// [, line 124
ket = cursor;
// substring, line 123
among_var = find_among_b(a_3, 2);
// substring, line 124
among_var = find_among_b(a_3, 3);
if (among_var == 0)
{
cursor = limit - v_2;
break lab1;
}
// ], line 123
// ], line 124
bra = cursor;
switch(among_var) {
case 0:
cursor = limit - v_2;
break lab1;
case 1:
// (, line 125
// call R2, line 125
// (, line 127
// call R2, line 127
if (!r_R2())
{
cursor = limit - v_2;
break lab1;
}
// delete, line 125
// delete, line 127
slice_del();
break;
}
} while (false);
break;
case 7:
// (, line 131
// call R2, line 132
// (, line 133
// call R2, line 134
if (!r_R2())
{
return false;
}
// delete, line 132
// delete, line 134
slice_del();
// try, line 133
// try, line 135
v_3 = limit - cursor;
lab2: do {
// (, line 133
// [, line 134
// (, line 135
// [, line 136
ket = cursor;
// substring, line 134
// substring, line 136
among_var = find_among_b(a_4, 3);
if (among_var == 0)
{
cursor = limit - v_3;
break lab2;
}
// ], line 134
// ], line 136
bra = cursor;
switch(among_var) {
case 0:
cursor = limit - v_3;
break lab2;
case 1:
// (, line 137
// call R2, line 137
// (, line 139
// call R2, line 139
if (!r_R2())
{
cursor = limit - v_3;
break lab2;
}
// delete, line 137
// delete, line 139
slice_del();
break;
}
} while (false);
break;
case 8:
// (, line 143
// call R2, line 144
// (, line 145
// call R2, line 146
if (!r_R2())
{
return false;
}
// delete, line 144
// delete, line 146
slice_del();
// try, line 145
// try, line 147
v_4 = limit - cursor;
lab3: do {
// (, line 145
// [, line 146
// (, line 147
// [, line 148
ket = cursor;
// literal, line 146
// literal, line 148
if (!(eq_s_b(2, "at")))
{
cursor = limit - v_4;
break lab3;
}
// ], line 146
// ], line 148
bra = cursor;
// call R2, line 146
// call R2, line 148
if (!r_R2())
{
cursor = limit - v_4;
break lab3;
}
// delete, line 146
// delete, line 148
slice_del();
} while (false);
break;
case 9:
// (, line 150
// call RV, line 151
// (, line 152
// call RV, line 153
if (!r_RV())
{
return false;
}
// literal, line 151
// literal, line 153
if (!(eq_s_b(1, "e")))
{
return false;
}
// <-, line 152
// <-, line 154
slice_from("ir");
break;
}
@ -824,9 +828,9 @@ public class PortugueseStemmer extends SnowballProgram {
int among_var;
int v_1;
int v_2;
// setlimit, line 157
// setlimit, line 159
v_1 = limit - cursor;
// tomark, line 157
// tomark, line 159
if (cursor < I_pV)
{
return false;
@ -835,25 +839,25 @@ public class PortugueseStemmer extends SnowballProgram {
v_2 = limit_backward;
limit_backward = cursor;
cursor = limit - v_1;
// (, line 157
// [, line 158
// (, line 159
// [, line 160
ket = cursor;
// substring, line 158
// substring, line 160
among_var = find_among_b(a_6, 120);
if (among_var == 0)
{
limit_backward = v_2;
return false;
}
// ], line 158
// ], line 160
bra = cursor;
switch(among_var) {
case 0:
limit_backward = v_2;
return false;
case 1:
// (, line 177
// delete, line 177
// (, line 179
// delete, line 179
slice_del();
break;
}
@ -863,28 +867,28 @@ public class PortugueseStemmer extends SnowballProgram {
private boolean r_residual_suffix() {
int among_var;
// (, line 181
// [, line 182
// (, line 183
// [, line 184
ket = cursor;
// substring, line 182
// substring, line 184
among_var = find_among_b(a_7, 7);
if (among_var == 0)
{
return false;
}
// ], line 182
// ], line 184
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 185
// call RV, line 185
// (, line 187
// call RV, line 187
if (!r_RV())
{
return false;
}
// delete, line 185
// delete, line 187
slice_del();
break;
}
@ -896,46 +900,46 @@ public class PortugueseStemmer extends SnowballProgram {
int v_1;
int v_2;
int v_3;
// (, line 189
// [, line 190
// (, line 191
// [, line 192
ket = cursor;
// substring, line 190
// substring, line 192
among_var = find_among_b(a_8, 4);
if (among_var == 0)
{
return false;
}
// ], line 190
// ], line 192
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 192
// call RV, line 192
// (, line 194
// call RV, line 194
if (!r_RV())
{
return false;
}
// delete, line 192
// delete, line 194
slice_del();
// [, line 192
// [, line 194
ket = cursor;
// or, line 192
// or, line 194
lab0: do {
v_1 = limit - cursor;
lab1: do {
// (, line 192
// literal, line 192
// (, line 194
// literal, line 194
if (!(eq_s_b(1, "u")))
{
break lab1;
}
// ], line 192
// ], line 194
bra = cursor;
// test, line 192
// test, line 194
v_2 = limit - cursor;
// literal, line 192
// literal, line 194
if (!(eq_s_b(1, "g")))
{
break lab1;
@ -944,34 +948,34 @@ public class PortugueseStemmer extends SnowballProgram {
break lab0;
} while (false);
cursor = limit - v_1;
// (, line 193
// literal, line 193
// (, line 195
// literal, line 195
if (!(eq_s_b(1, "i")))
{
return false;
}
// ], line 193
// ], line 195
bra = cursor;
// test, line 193
// test, line 195
v_3 = limit - cursor;
// literal, line 193
// literal, line 195
if (!(eq_s_b(1, "c")))
{
return false;
}
cursor = limit - v_3;
} while (false);
// call RV, line 193
// call RV, line 195
if (!r_RV())
{
return false;
}
// delete, line 193
// delete, line 195
slice_del();
break;
case 2:
// (, line 194
// <-, line 194
// (, line 196
// <-, line 196
slice_from("c");
break;
}
@ -989,47 +993,47 @@ public class PortugueseStemmer extends SnowballProgram {
int v_8;
int v_9;
int v_10;
// (, line 199
// do, line 200
// (, line 201
// do, line 202
v_1 = cursor;
lab0: do {
// call prelude, line 200
// call prelude, line 202
if (!r_prelude())
{
break lab0;
}
} while (false);
cursor = v_1;
// do, line 201
// do, line 203
v_2 = cursor;
lab1: do {
// call mark_regions, line 201
// call mark_regions, line 203
if (!r_mark_regions())
{
break lab1;
}
} while (false);
cursor = v_2;
// backwards, line 202
// backwards, line 204
limit_backward = cursor; cursor = limit;
// (, line 202
// do, line 203
// (, line 204
// do, line 205
v_3 = limit - cursor;
lab2: do {
// (, line 203
// or, line 207
// (, line 205
// or, line 209
lab3: do {
v_4 = limit - cursor;
lab4: do {
// (, line 204
// and, line 205
// (, line 206
// and, line 207
v_5 = limit - cursor;
// (, line 204
// or, line 204
// (, line 206
// or, line 206
lab5: do {
v_6 = limit - cursor;
lab6: do {
// call standard_suffix, line 204
// call standard_suffix, line 206
if (!r_standard_suffix())
{
break lab6;
@ -1037,47 +1041,47 @@ public class PortugueseStemmer extends SnowballProgram {
break lab5;
} while (false);
cursor = limit - v_6;
// call verb_suffix, line 204
// call verb_suffix, line 206
if (!r_verb_suffix())
{
break lab4;
}
} while (false);
cursor = limit - v_5;
// do, line 205
// do, line 207
v_7 = limit - cursor;
lab7: do {
// (, line 205
// [, line 205
// (, line 207
// [, line 207
ket = cursor;
// literal, line 205
// literal, line 207
if (!(eq_s_b(1, "i")))
{
break lab7;
}
// ], line 205
// ], line 207
bra = cursor;
// test, line 205
// test, line 207
v_8 = limit - cursor;
// literal, line 205
// literal, line 207
if (!(eq_s_b(1, "c")))
{
break lab7;
}
cursor = limit - v_8;
// call RV, line 205
// call RV, line 207
if (!r_RV())
{
break lab7;
}
// delete, line 205
// delete, line 207
slice_del();
} while (false);
cursor = limit - v_7;
break lab3;
} while (false);
cursor = limit - v_4;
// call residual_suffix, line 207
// call residual_suffix, line 209
if (!r_residual_suffix())
{
break lab2;
@ -1085,20 +1089,20 @@ public class PortugueseStemmer extends SnowballProgram {
} while (false);
} while (false);
cursor = limit - v_3;
// do, line 209
// do, line 211
v_9 = limit - cursor;
lab8: do {
// call residual_form, line 209
// call residual_form, line 211
if (!r_residual_form())
{
break lab8;
}
} while (false);
cursor = limit - v_9;
cursor = limit_backward; // do, line 211
cursor = limit_backward; // do, line 213
v_10 = cursor;
lab9: do {
// call postlude, line 211
// call postlude, line 213
if (!r_postlude())
{
break lab9;

File diff suppressed because it is too large Load Diff

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -10,163 +10,163 @@ import net.sf.snowball.Among;
public class RussianStemmer extends SnowballProgram {
private Among a_0[] = {
new Among ( "\u00D7\u00DB\u00C9", -1, 1, "", this),
new Among ( "\u00C9\u00D7\u00DB\u00C9", 0, 2, "", this),
new Among ( "\u00D9\u00D7\u00DB\u00C9", 0, 2, "", this),
new Among ( "\u00D7", -1, 1, "", this),
new Among ( "\u00C9\u00D7", 3, 2, "", this),
new Among ( "\u00D9\u00D7", 3, 2, "", this),
new Among ( "\u00D7\u00DB\u00C9\u00D3\u00D8", -1, 1, "", this),
new Among ( "\u00C9\u00D7\u00DB\u00C9\u00D3\u00D8", 6, 2, "", this),
new Among ( "\u00D9\u00D7\u00DB\u00C9\u00D3\u00D8", 6, 2, "", this)
new Among ( "\u0432", -1, 1, "", this),
new Among ( "\u0438\u0432", 0, 2, "", this),
new Among ( "\u044B\u0432", 0, 2, "", this),
new Among ( "\u0432\u0448\u0438", -1, 1, "", this),
new Among ( "\u0438\u0432\u0448\u0438", 3, 2, "", this),
new Among ( "\u044B\u0432\u0448\u0438", 3, 2, "", this),
new Among ( "\u0432\u0448\u0438\u0441\u044C", -1, 1, "", this),
new Among ( "\u0438\u0432\u0448\u0438\u0441\u044C", 6, 2, "", this),
new Among ( "\u044B\u0432\u0448\u0438\u0441\u044C", 6, 2, "", this)
};
private Among a_1[] = {
new Among ( "\u00C0\u00C0", -1, 1, "", this),
new Among ( "\u00C5\u00C0", -1, 1, "", this),
new Among ( "\u00CF\u00C0", -1, 1, "", this),
new Among ( "\u00D5\u00C0", -1, 1, "", this),
new Among ( "\u00C5\u00C5", -1, 1, "", this),
new Among ( "\u00C9\u00C5", -1, 1, "", this),
new Among ( "\u00CF\u00C5", -1, 1, "", this),
new Among ( "\u00D9\u00C5", -1, 1, "", this),
new Among ( "\u00C9\u00C8", -1, 1, "", this),
new Among ( "\u00D9\u00C8", -1, 1, "", this),
new Among ( "\u00C9\u00CD\u00C9", -1, 1, "", this),
new Among ( "\u00D9\u00CD\u00C9", -1, 1, "", this),
new Among ( "\u00C5\u00CA", -1, 1, "", this),
new Among ( "\u00C9\u00CA", -1, 1, "", this),
new Among ( "\u00CF\u00CA", -1, 1, "", this),
new Among ( "\u00D9\u00CA", -1, 1, "", this),
new Among ( "\u00C5\u00CD", -1, 1, "", this),
new Among ( "\u00C9\u00CD", -1, 1, "", this),
new Among ( "\u00CF\u00CD", -1, 1, "", this),
new Among ( "\u00D9\u00CD", -1, 1, "", this),
new Among ( "\u00C5\u00C7\u00CF", -1, 1, "", this),
new Among ( "\u00CF\u00C7\u00CF", -1, 1, "", this),
new Among ( "\u00C1\u00D1", -1, 1, "", this),
new Among ( "\u00D1\u00D1", -1, 1, "", this),
new Among ( "\u00C5\u00CD\u00D5", -1, 1, "", this),
new Among ( "\u00CF\u00CD\u00D5", -1, 1, "", this)
new Among ( "\u0435\u0435", -1, 1, "", this),
new Among ( "\u0438\u0435", -1, 1, "", this),
new Among ( "\u043E\u0435", -1, 1, "", this),
new Among ( "\u044B\u0435", -1, 1, "", this),
new Among ( "\u0438\u043C\u0438", -1, 1, "", this),
new Among ( "\u044B\u043C\u0438", -1, 1, "", this),
new Among ( "\u0435\u0439", -1, 1, "", this),
new Among ( "\u0438\u0439", -1, 1, "", this),
new Among ( "\u043E\u0439", -1, 1, "", this),
new Among ( "\u044B\u0439", -1, 1, "", this),
new Among ( "\u0435\u043C", -1, 1, "", this),
new Among ( "\u0438\u043C", -1, 1, "", this),
new Among ( "\u043E\u043C", -1, 1, "", this),
new Among ( "\u044B\u043C", -1, 1, "", this),
new Among ( "\u0435\u0433\u043E", -1, 1, "", this),
new Among ( "\u043E\u0433\u043E", -1, 1, "", this),
new Among ( "\u0435\u043C\u0443", -1, 1, "", this),
new Among ( "\u043E\u043C\u0443", -1, 1, "", this),
new Among ( "\u0438\u0445", -1, 1, "", this),
new Among ( "\u044B\u0445", -1, 1, "", this),
new Among ( "\u0435\u044E", -1, 1, "", this),
new Among ( "\u043E\u044E", -1, 1, "", this),
new Among ( "\u0443\u044E", -1, 1, "", this),
new Among ( "\u044E\u044E", -1, 1, "", this),
new Among ( "\u0430\u044F", -1, 1, "", this),
new Among ( "\u044F\u044F", -1, 1, "", this)
};
private Among a_2[] = {
new Among ( "\u00C5\u00CD", -1, 1, "", this),
new Among ( "\u00CE\u00CE", -1, 1, "", this),
new Among ( "\u00D7\u00DB", -1, 1, "", this),
new Among ( "\u00C9\u00D7\u00DB", 2, 2, "", this),
new Among ( "\u00D9\u00D7\u00DB", 2, 2, "", this),
new Among ( "\u00DD", -1, 1, "", this),
new Among ( "\u00C0\u00DD", 5, 1, "", this),
new Among ( "\u00D5\u00C0\u00DD", 6, 2, "", this)
new Among ( "\u0435\u043C", -1, 1, "", this),
new Among ( "\u043D\u043D", -1, 1, "", this),
new Among ( "\u0432\u0448", -1, 1, "", this),
new Among ( "\u0438\u0432\u0448", 2, 2, "", this),
new Among ( "\u044B\u0432\u0448", 2, 2, "", this),
new Among ( "\u0449", -1, 1, "", this),
new Among ( "\u044E\u0449", 5, 1, "", this),
new Among ( "\u0443\u044E\u0449", 6, 2, "", this)
};
private Among a_3[] = {
new Among ( "\u00D3\u00D1", -1, 1, "", this),
new Among ( "\u00D3\u00D8", -1, 1, "", this)
new Among ( "\u0441\u044C", -1, 1, "", this),
new Among ( "\u0441\u044F", -1, 1, "", this)
};
private Among a_4[] = {
new Among ( "\u00C0", -1, 2, "", this),
new Among ( "\u00D5\u00C0", 0, 2, "", this),
new Among ( "\u00CC\u00C1", -1, 1, "", this),
new Among ( "\u00C9\u00CC\u00C1", 2, 2, "", this),
new Among ( "\u00D9\u00CC\u00C1", 2, 2, "", this),
new Among ( "\u00CE\u00C1", -1, 1, "", this),
new Among ( "\u00C5\u00CE\u00C1", 5, 2, "", this),
new Among ( "\u00C5\u00D4\u00C5", -1, 1, "", this),
new Among ( "\u00C9\u00D4\u00C5", -1, 2, "", this),
new Among ( "\u00CA\u00D4\u00C5", -1, 1, "", this),
new Among ( "\u00C5\u00CA\u00D4\u00C5", 9, 2, "", this),
new Among ( "\u00D5\u00CA\u00D4\u00C5", 9, 2, "", this),
new Among ( "\u00CC\u00C9", -1, 1, "", this),
new Among ( "\u00C9\u00CC\u00C9", 12, 2, "", this),
new Among ( "\u00D9\u00CC\u00C9", 12, 2, "", this),
new Among ( "\u00CA", -1, 1, "", this),
new Among ( "\u00C5\u00CA", 15, 2, "", this),
new Among ( "\u00D5\u00CA", 15, 2, "", this),
new Among ( "\u00CC", -1, 1, "", this),
new Among ( "\u00C9\u00CC", 18, 2, "", this),
new Among ( "\u00D9\u00CC", 18, 2, "", this),
new Among ( "\u00C5\u00CD", -1, 1, "", this),
new Among ( "\u00C9\u00CD", -1, 2, "", this),
new Among ( "\u00D9\u00CD", -1, 2, "", this),
new Among ( "\u00CE", -1, 1, "", this),
new Among ( "\u00C5\u00CE", 24, 2, "", this),
new Among ( "\u00CC\u00CF", -1, 1, "", this),
new Among ( "\u00C9\u00CC\u00CF", 26, 2, "", this),
new Among ( "\u00D9\u00CC\u00CF", 26, 2, "", this),
new Among ( "\u00CE\u00CF", -1, 1, "", this),
new Among ( "\u00C5\u00CE\u00CF", 29, 2, "", this),
new Among ( "\u00CE\u00CE\u00CF", 29, 1, "", this),
new Among ( "\u00C0\u00D4", -1, 1, "", this),
new Among ( "\u00D5\u00C0\u00D4", 32, 2, "", this),
new Among ( "\u00C5\u00D4", -1, 1, "", this),
new Among ( "\u00D5\u00C5\u00D4", 34, 2, "", this),
new Among ( "\u00C9\u00D4", -1, 2, "", this),
new Among ( "\u00D1\u00D4", -1, 2, "", this),
new Among ( "\u00D9\u00D4", -1, 2, "", this),
new Among ( "\u00D4\u00D8", -1, 1, "", this),
new Among ( "\u00C9\u00D4\u00D8", 39, 2, "", this),
new Among ( "\u00D9\u00D4\u00D8", 39, 2, "", this),
new Among ( "\u00C5\u00DB\u00D8", -1, 1, "", this),
new Among ( "\u00C9\u00DB\u00D8", -1, 2, "", this),
new Among ( "\u00CE\u00D9", -1, 1, "", this),
new Among ( "\u00C5\u00CE\u00D9", 44, 2, "", this)
new Among ( "\u043B\u0430", -1, 1, "", this),
new Among ( "\u0438\u043B\u0430", 0, 2, "", this),
new Among ( "\u044B\u043B\u0430", 0, 2, "", this),
new Among ( "\u043D\u0430", -1, 1, "", this),
new Among ( "\u0435\u043D\u0430", 3, 2, "", this),
new Among ( "\u0435\u0442\u0435", -1, 1, "", this),
new Among ( "\u0438\u0442\u0435", -1, 2, "", this),
new Among ( "\u0439\u0442\u0435", -1, 1, "", this),
new Among ( "\u0435\u0439\u0442\u0435", 7, 2, "", this),
new Among ( "\u0443\u0439\u0442\u0435", 7, 2, "", this),
new Among ( "\u043B\u0438", -1, 1, "", this),
new Among ( "\u0438\u043B\u0438", 10, 2, "", this),
new Among ( "\u044B\u043B\u0438", 10, 2, "", this),
new Among ( "\u0439", -1, 1, "", this),
new Among ( "\u0435\u0439", 13, 2, "", this),
new Among ( "\u0443\u0439", 13, 2, "", this),
new Among ( "\u043B", -1, 1, "", this),
new Among ( "\u0438\u043B", 16, 2, "", this),
new Among ( "\u044B\u043B", 16, 2, "", this),
new Among ( "\u0435\u043C", -1, 1, "", this),
new Among ( "\u0438\u043C", -1, 2, "", this),
new Among ( "\u044B\u043C", -1, 2, "", this),
new Among ( "\u043D", -1, 1, "", this),
new Among ( "\u0435\u043D", 22, 2, "", this),
new Among ( "\u043B\u043E", -1, 1, "", this),
new Among ( "\u0438\u043B\u043E", 24, 2, "", this),
new Among ( "\u044B\u043B\u043E", 24, 2, "", this),
new Among ( "\u043D\u043E", -1, 1, "", this),
new Among ( "\u0435\u043D\u043E", 27, 2, "", this),
new Among ( "\u043D\u043D\u043E", 27, 1, "", this),
new Among ( "\u0435\u0442", -1, 1, "", this),
new Among ( "\u0443\u0435\u0442", 30, 2, "", this),
new Among ( "\u0438\u0442", -1, 2, "", this),
new Among ( "\u044B\u0442", -1, 2, "", this),
new Among ( "\u044E\u0442", -1, 1, "", this),
new Among ( "\u0443\u044E\u0442", 34, 2, "", this),
new Among ( "\u044F\u0442", -1, 2, "", this),
new Among ( "\u043D\u044B", -1, 1, "", this),
new Among ( "\u0435\u043D\u044B", 37, 2, "", this),
new Among ( "\u0442\u044C", -1, 1, "", this),
new Among ( "\u0438\u0442\u044C", 39, 2, "", this),
new Among ( "\u044B\u0442\u044C", 39, 2, "", this),
new Among ( "\u0435\u0448\u044C", -1, 1, "", this),
new Among ( "\u0438\u0448\u044C", -1, 2, "", this),
new Among ( "\u044E", -1, 2, "", this),
new Among ( "\u0443\u044E", 44, 2, "", this)
};
private Among a_5[] = {
new Among ( "\u00C0", -1, 1, "", this),
new Among ( "\u00C9\u00C0", 0, 1, "", this),
new Among ( "\u00D8\u00C0", 0, 1, "", this),
new Among ( "\u00C1", -1, 1, "", this),
new Among ( "\u00C5", -1, 1, "", this),
new Among ( "\u00C9\u00C5", 4, 1, "", this),
new Among ( "\u00D8\u00C5", 4, 1, "", this),
new Among ( "\u00C1\u00C8", -1, 1, "", this),
new Among ( "\u00D1\u00C8", -1, 1, "", this),
new Among ( "\u00C9\u00D1\u00C8", 8, 1, "", this),
new Among ( "\u00C9", -1, 1, "", this),
new Among ( "\u00C5\u00C9", 10, 1, "", this),
new Among ( "\u00C9\u00C9", 10, 1, "", this),
new Among ( "\u00C1\u00CD\u00C9", 10, 1, "", this),
new Among ( "\u00D1\u00CD\u00C9", 10, 1, "", this),
new Among ( "\u00C9\u00D1\u00CD\u00C9", 14, 1, "", this),
new Among ( "\u00CA", -1, 1, "", this),
new Among ( "\u00C5\u00CA", 16, 1, "", this),
new Among ( "\u00C9\u00C5\u00CA", 17, 1, "", this),
new Among ( "\u00C9\u00CA", 16, 1, "", this),
new Among ( "\u00CF\u00CA", 16, 1, "", this),
new Among ( "\u00C1\u00CD", -1, 1, "", this),
new Among ( "\u00C5\u00CD", -1, 1, "", this),
new Among ( "\u00C9\u00C5\u00CD", 22, 1, "", this),
new Among ( "\u00CF\u00CD", -1, 1, "", this),
new Among ( "\u00D1\u00CD", -1, 1, "", this),
new Among ( "\u00C9\u00D1\u00CD", 25, 1, "", this),
new Among ( "\u00CF", -1, 1, "", this),
new Among ( "\u00D1", -1, 1, "", this),
new Among ( "\u00C9\u00D1", 28, 1, "", this),
new Among ( "\u00D8\u00D1", 28, 1, "", this),
new Among ( "\u00D5", -1, 1, "", this),
new Among ( "\u00C5\u00D7", -1, 1, "", this),
new Among ( "\u00CF\u00D7", -1, 1, "", this),
new Among ( "\u00D8", -1, 1, "", this),
new Among ( "\u00D9", -1, 1, "", this)
new Among ( "\u0430", -1, 1, "", this),
new Among ( "\u0435\u0432", -1, 1, "", this),
new Among ( "\u043E\u0432", -1, 1, "", this),
new Among ( "\u0435", -1, 1, "", this),
new Among ( "\u0438\u0435", 3, 1, "", this),
new Among ( "\u044C\u0435", 3, 1, "", this),
new Among ( "\u0438", -1, 1, "", this),
new Among ( "\u0435\u0438", 6, 1, "", this),
new Among ( "\u0438\u0438", 6, 1, "", this),
new Among ( "\u0430\u043C\u0438", 6, 1, "", this),
new Among ( "\u044F\u043C\u0438", 6, 1, "", this),
new Among ( "\u0438\u044F\u043C\u0438", 10, 1, "", this),
new Among ( "\u0439", -1, 1, "", this),
new Among ( "\u0435\u0439", 12, 1, "", this),
new Among ( "\u0438\u0435\u0439", 13, 1, "", this),
new Among ( "\u0438\u0439", 12, 1, "", this),
new Among ( "\u043E\u0439", 12, 1, "", this),
new Among ( "\u0430\u043C", -1, 1, "", this),
new Among ( "\u0435\u043C", -1, 1, "", this),
new Among ( "\u0438\u0435\u043C", 18, 1, "", this),
new Among ( "\u043E\u043C", -1, 1, "", this),
new Among ( "\u044F\u043C", -1, 1, "", this),
new Among ( "\u0438\u044F\u043C", 21, 1, "", this),
new Among ( "\u043E", -1, 1, "", this),
new Among ( "\u0443", -1, 1, "", this),
new Among ( "\u0430\u0445", -1, 1, "", this),
new Among ( "\u044F\u0445", -1, 1, "", this),
new Among ( "\u0438\u044F\u0445", 26, 1, "", this),
new Among ( "\u044B", -1, 1, "", this),
new Among ( "\u044C", -1, 1, "", this),
new Among ( "\u044E", -1, 1, "", this),
new Among ( "\u0438\u044E", 30, 1, "", this),
new Among ( "\u044C\u044E", 30, 1, "", this),
new Among ( "\u044F", -1, 1, "", this),
new Among ( "\u0438\u044F", 33, 1, "", this),
new Among ( "\u044C\u044F", 33, 1, "", this)
};
private Among a_6[] = {
new Among ( "\u00CF\u00D3\u00D4", -1, 1, "", this),
new Among ( "\u00CF\u00D3\u00D4\u00D8", -1, 1, "", this)
new Among ( "\u043E\u0441\u0442", -1, 1, "", this),
new Among ( "\u043E\u0441\u0442\u044C", -1, 1, "", this)
};
private Among a_7[] = {
new Among ( "\u00C5\u00CA\u00DB\u00C5", -1, 1, "", this),
new Among ( "\u00CE", -1, 2, "", this),
new Among ( "\u00D8", -1, 3, "", this),
new Among ( "\u00C5\u00CA\u00DB", -1, 1, "", this)
new Among ( "\u0435\u0439\u0448\u0435", -1, 1, "", this),
new Among ( "\u043D", -1, 2, "", this),
new Among ( "\u0435\u0439\u0448", -1, 1, "", this),
new Among ( "\u044C", -1, 3, "", this)
};
private static final char g_v[] = {35, 130, 34, 18 };
private static final char g_v[] = {33, 65, 8, 232 };
private int I_p2;
private int I_pV;
@ -179,18 +179,18 @@ public class RussianStemmer extends SnowballProgram {
private boolean r_mark_regions() {
int v_1;
// (, line 96
// (, line 57
I_pV = limit;
I_p2 = limit;
// do, line 100
// do, line 61
v_1 = cursor;
lab0: do {
// (, line 100
// gopast, line 101
// (, line 61
// gopast, line 62
golab1: while(true)
{
lab2: do {
if (!(in_grouping(g_v, 192, 220)))
if (!(in_grouping(g_v, 1072, 1103)))
{
break lab2;
}
@ -202,13 +202,13 @@ public class RussianStemmer extends SnowballProgram {
}
cursor++;
}
// setmark pV, line 101
// setmark pV, line 62
I_pV = cursor;
// gopast, line 101
// gopast, line 62
golab3: while(true)
{
lab4: do {
if (!(out_grouping(g_v, 192, 220)))
if (!(out_grouping(g_v, 1072, 1103)))
{
break lab4;
}
@ -220,11 +220,11 @@ public class RussianStemmer extends SnowballProgram {
}
cursor++;
}
// gopast, line 102
// gopast, line 63
golab5: while(true)
{
lab6: do {
if (!(in_grouping(g_v, 192, 220)))
if (!(in_grouping(g_v, 1072, 1103)))
{
break lab6;
}
@ -236,11 +236,11 @@ public class RussianStemmer extends SnowballProgram {
}
cursor++;
}
// gopast, line 102
// gopast, line 63
golab7: while(true)
{
lab8: do {
if (!(out_grouping(g_v, 192, 220)))
if (!(out_grouping(g_v, 1072, 1103)))
{
break lab8;
}
@ -252,7 +252,7 @@ public class RussianStemmer extends SnowballProgram {
}
cursor++;
}
// setmark p2, line 102
// setmark p2, line 63
I_p2 = cursor;
} while (false);
cursor = v_1;
@ -270,46 +270,46 @@ public class RussianStemmer extends SnowballProgram {
private boolean r_perfective_gerund() {
int among_var;
int v_1;
// (, line 110
// [, line 111
// (, line 71
// [, line 72
ket = cursor;
// substring, line 111
// substring, line 72
among_var = find_among_b(a_0, 9);
if (among_var == 0)
{
return false;
}
// ], line 111
// ], line 72
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 115
// or, line 115
// (, line 76
// or, line 76
lab0: do {
v_1 = limit - cursor;
lab1: do {
// literal, line 115
if (!(eq_s_b(1, "\u00C1")))
// literal, line 76
if (!(eq_s_b(1, "\u0430")))
{
break lab1;
}
break lab0;
} while (false);
cursor = limit - v_1;
// literal, line 115
if (!(eq_s_b(1, "\u00D1")))
// literal, line 76
if (!(eq_s_b(1, "\u044F")))
{
return false;
}
} while (false);
// delete, line 115
// delete, line 76
slice_del();
break;
case 2:
// (, line 122
// delete, line 122
// (, line 83
// delete, line 83
slice_del();
break;
}
@ -318,23 +318,23 @@ public class RussianStemmer extends SnowballProgram {
private boolean r_adjective() {
int among_var;
// (, line 126
// [, line 127
// (, line 87
// [, line 88
ket = cursor;
// substring, line 127
// substring, line 88
among_var = find_among_b(a_1, 26);
if (among_var == 0)
{
return false;
}
// ], line 127
// ], line 88
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 136
// delete, line 136
// (, line 97
// delete, line 97
slice_del();
break;
}
@ -345,58 +345,58 @@ public class RussianStemmer extends SnowballProgram {
int among_var;
int v_1;
int v_2;
// (, line 140
// call adjective, line 141
// (, line 101
// call adjective, line 102
if (!r_adjective())
{
return false;
}
// try, line 148
// try, line 109
v_1 = limit - cursor;
lab0: do {
// (, line 148
// [, line 149
// (, line 109
// [, line 110
ket = cursor;
// substring, line 149
// substring, line 110
among_var = find_among_b(a_2, 8);
if (among_var == 0)
{
cursor = limit - v_1;
break lab0;
}
// ], line 149
// ], line 110
bra = cursor;
switch(among_var) {
case 0:
cursor = limit - v_1;
break lab0;
case 1:
// (, line 154
// or, line 154
// (, line 115
// or, line 115
lab1: do {
v_2 = limit - cursor;
lab2: do {
// literal, line 154
if (!(eq_s_b(1, "\u00C1")))
// literal, line 115
if (!(eq_s_b(1, "\u0430")))
{
break lab2;
}
break lab1;
} while (false);
cursor = limit - v_2;
// literal, line 154
if (!(eq_s_b(1, "\u00D1")))
// literal, line 115
if (!(eq_s_b(1, "\u044F")))
{
cursor = limit - v_1;
break lab0;
}
} while (false);
// delete, line 154
// delete, line 115
slice_del();
break;
case 2:
// (, line 161
// delete, line 161
// (, line 122
// delete, line 122
slice_del();
break;
}
@ -406,23 +406,23 @@ public class RussianStemmer extends SnowballProgram {
private boolean r_reflexive() {
int among_var;
// (, line 167
// [, line 168
// (, line 128
// [, line 129
ket = cursor;
// substring, line 168
// substring, line 129
among_var = find_among_b(a_3, 2);
if (among_var == 0)
{
return false;
}
// ], line 168
// ], line 129
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 171
// delete, line 171
// (, line 132
// delete, line 132
slice_del();
break;
}
@ -432,46 +432,46 @@ public class RussianStemmer extends SnowballProgram {
private boolean r_verb() {
int among_var;
int v_1;
// (, line 175
// [, line 176
// (, line 136
// [, line 137
ket = cursor;
// substring, line 176
// substring, line 137
among_var = find_among_b(a_4, 46);
if (among_var == 0)
{
return false;
}
// ], line 176
// ], line 137
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 182
// or, line 182
// (, line 143
// or, line 143
lab0: do {
v_1 = limit - cursor;
lab1: do {
// literal, line 182
if (!(eq_s_b(1, "\u00C1")))
// literal, line 143
if (!(eq_s_b(1, "\u0430")))
{
break lab1;
}
break lab0;
} while (false);
cursor = limit - v_1;
// literal, line 182
if (!(eq_s_b(1, "\u00D1")))
// literal, line 143
if (!(eq_s_b(1, "\u044F")))
{
return false;
}
} while (false);
// delete, line 182
// delete, line 143
slice_del();
break;
case 2:
// (, line 190
// delete, line 190
// (, line 151
// delete, line 151
slice_del();
break;
}
@ -480,23 +480,23 @@ public class RussianStemmer extends SnowballProgram {
private boolean r_noun() {
int among_var;
// (, line 198
// [, line 199
// (, line 159
// [, line 160
ket = cursor;
// substring, line 199
// substring, line 160
among_var = find_among_b(a_5, 36);
if (among_var == 0)
{
return false;
}
// ], line 199
// ], line 160
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 206
// delete, line 206
// (, line 167
// delete, line 167
slice_del();
break;
}
@ -505,18 +505,18 @@ public class RussianStemmer extends SnowballProgram {
private boolean r_derivational() {
int among_var;
// (, line 214
// [, line 215
// (, line 175
// [, line 176
ket = cursor;
// substring, line 215
// substring, line 176
among_var = find_among_b(a_6, 2);
if (among_var == 0)
{
return false;
}
// ], line 215
// ], line 176
bra = cursor;
// call R2, line 215
// call R2, line 176
if (!r_R2())
{
return false;
@ -525,8 +525,8 @@ public class RussianStemmer extends SnowballProgram {
case 0:
return false;
case 1:
// (, line 218
// delete, line 218
// (, line 179
// delete, line 179
slice_del();
break;
}
@ -535,54 +535,54 @@ public class RussianStemmer extends SnowballProgram {
private boolean r_tidy_up() {
int among_var;
// (, line 222
// [, line 223
// (, line 183
// [, line 184
ket = cursor;
// substring, line 223
// substring, line 184
among_var = find_among_b(a_7, 4);
if (among_var == 0)
{
return false;
}
// ], line 223
// ], line 184
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 227
// delete, line 227
// (, line 188
// delete, line 188
slice_del();
// [, line 228
// [, line 189
ket = cursor;
// literal, line 228
if (!(eq_s_b(1, "\u00CE")))
// literal, line 189
if (!(eq_s_b(1, "\u043D")))
{
return false;
}
// ], line 228
// ], line 189
bra = cursor;
// literal, line 228
if (!(eq_s_b(1, "\u00CE")))
// literal, line 189
if (!(eq_s_b(1, "\u043D")))
{
return false;
}
// delete, line 228
// delete, line 189
slice_del();
break;
case 2:
// (, line 231
// literal, line 231
if (!(eq_s_b(1, "\u00CE")))
// (, line 192
// literal, line 192
if (!(eq_s_b(1, "\u043D")))
{
return false;
}
// delete, line 231
// delete, line 192
slice_del();
break;
case 3:
// (, line 233
// delete, line 233
// (, line 194
// delete, line 194
slice_del();
break;
}
@ -600,22 +600,22 @@ public class RussianStemmer extends SnowballProgram {
int v_8;
int v_9;
int v_10;
// (, line 238
// do, line 240
// (, line 199
// do, line 201
v_1 = cursor;
lab0: do {
// call mark_regions, line 240
// call mark_regions, line 201
if (!r_mark_regions())
{
break lab0;
}
} while (false);
cursor = v_1;
// backwards, line 241
// backwards, line 202
limit_backward = cursor; cursor = limit;
// setlimit, line 241
// setlimit, line 202
v_2 = limit - cursor;
// tomark, line 241
// tomark, line 202
if (cursor < I_pV)
{
return false;
@ -624,16 +624,16 @@ public class RussianStemmer extends SnowballProgram {
v_3 = limit_backward;
limit_backward = cursor;
cursor = limit - v_2;
// (, line 241
// do, line 242
// (, line 202
// do, line 203
v_4 = limit - cursor;
lab1: do {
// (, line 242
// or, line 243
// (, line 203
// or, line 204
lab2: do {
v_5 = limit - cursor;
lab3: do {
// call perfective_gerund, line 243
// call perfective_gerund, line 204
if (!r_perfective_gerund())
{
break lab3;
@ -641,22 +641,22 @@ public class RussianStemmer extends SnowballProgram {
break lab2;
} while (false);
cursor = limit - v_5;
// (, line 244
// try, line 244
// (, line 205
// try, line 205
v_6 = limit - cursor;
lab4: do {
// call reflexive, line 244
// call reflexive, line 205
if (!r_reflexive())
{
cursor = limit - v_6;
break lab4;
}
} while (false);
// or, line 245
// or, line 206
lab5: do {
v_7 = limit - cursor;
lab6: do {
// call adjectival, line 245
// call adjectival, line 206
if (!r_adjectival())
{
break lab6;
@ -665,7 +665,7 @@ public class RussianStemmer extends SnowballProgram {
} while (false);
cursor = limit - v_7;
lab7: do {
// call verb, line 245
// call verb, line 206
if (!r_verb())
{
break lab7;
@ -673,7 +673,7 @@ public class RussianStemmer extends SnowballProgram {
break lab5;
} while (false);
cursor = limit - v_7;
// call noun, line 245
// call noun, line 206
if (!r_noun())
{
break lab1;
@ -682,37 +682,37 @@ public class RussianStemmer extends SnowballProgram {
} while (false);
} while (false);
cursor = limit - v_4;
// try, line 248
// try, line 209
v_8 = limit - cursor;
lab8: do {
// (, line 248
// [, line 248
// (, line 209
// [, line 209
ket = cursor;
// literal, line 248
if (!(eq_s_b(1, "\u00C9")))
// literal, line 209
if (!(eq_s_b(1, "\u0438")))
{
cursor = limit - v_8;
break lab8;
}
// ], line 248
// ], line 209
bra = cursor;
// delete, line 248
// delete, line 209
slice_del();
} while (false);
// do, line 251
// do, line 212
v_9 = limit - cursor;
lab9: do {
// call derivational, line 251
// call derivational, line 212
if (!r_derivational())
{
break lab9;
}
} while (false);
cursor = limit - v_9;
// do, line 252
// do, line 213
v_10 = limit - cursor;
lab10: do {
// call tidy_up, line 252
// call tidy_up, line 213
if (!r_tidy_up())
{
break lab10;

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -57,7 +57,8 @@ public class SpanishStemmer extends SnowballProgram {
private Among a_4[] = {
new Among ( "able", -1, 1, "", this),
new Among ( "ible", -1, 1, "", this)
new Among ( "ible", -1, 1, "", this),
new Among ( "ante", -1, 1, "", this)
};
private Among a_5[] = {
@ -68,6 +69,7 @@ public class SpanishStemmer extends SnowballProgram {
private Among a_6[] = {
new Among ( "ica", -1, 1, "", this),
new Among ( "ancia", -1, 2, "", this),
new Among ( "encia", -1, 5, "", this),
new Among ( "adora", -1, 2, "", this),
new Among ( "osa", -1, 1, "", this),
@ -78,8 +80,9 @@ public class SpanishStemmer extends SnowballProgram {
new Among ( "idad", -1, 8, "", this),
new Among ( "able", -1, 1, "", this),
new Among ( "ible", -1, 1, "", this),
new Among ( "ante", -1, 2, "", this),
new Among ( "mente", -1, 7, "", this),
new Among ( "amente", 11, 6, "", this),
new Among ( "amente", 13, 6, "", this),
new Among ( "aci\u00F3n", -1, 2, "", this),
new Among ( "uci\u00F3n", -1, 4, "", this),
new Among ( "ico", -1, 1, "", this),
@ -90,6 +93,7 @@ public class SpanishStemmer extends SnowballProgram {
new Among ( "ivo", -1, 9, "", this),
new Among ( "ador", -1, 2, "", this),
new Among ( "icas", -1, 1, "", this),
new Among ( "ancias", -1, 2, "", this),
new Among ( "encias", -1, 5, "", this),
new Among ( "adoras", -1, 2, "", this),
new Among ( "osas", -1, 1, "", this),
@ -103,6 +107,7 @@ public class SpanishStemmer extends SnowballProgram {
new Among ( "aciones", -1, 2, "", this),
new Among ( "uciones", -1, 4, "", this),
new Among ( "adores", -1, 2, "", this),
new Among ( "antes", -1, 2, "", this),
new Among ( "icos", -1, 1, "", this),
new Among ( "ismos", -1, 1, "", this),
new Among ( "osos", -1, 1, "", this),
@ -632,7 +637,7 @@ public class SpanishStemmer extends SnowballProgram {
// [, line 87
ket = cursor;
// substring, line 87
among_var = find_among_b(a_6, 42);
among_var = find_among_b(a_6, 46);
if (among_var == 0)
{
return false;
@ -653,242 +658,242 @@ public class SpanishStemmer extends SnowballProgram {
slice_del();
break;
case 2:
// (, line 103
// call R2, line 104
// (, line 104
// call R2, line 105
if (!r_R2())
{
return false;
}
// delete, line 104
// delete, line 105
slice_del();
// try, line 105
// try, line 106
v_1 = limit - cursor;
lab0: do {
// (, line 105
// [, line 105
// (, line 106
// [, line 106
ket = cursor;
// literal, line 105
// literal, line 106
if (!(eq_s_b(2, "ic")))
{
cursor = limit - v_1;
break lab0;
}
// ], line 105
// ], line 106
bra = cursor;
// call R2, line 105
// call R2, line 106
if (!r_R2())
{
cursor = limit - v_1;
break lab0;
}
// delete, line 105
// delete, line 106
slice_del();
} while (false);
break;
case 3:
// (, line 109
// call R2, line 110
// (, line 110
// call R2, line 111
if (!r_R2())
{
return false;
}
// <-, line 110
// <-, line 111
slice_from("log");
break;
case 4:
// (, line 113
// call R2, line 114
// (, line 114
// call R2, line 115
if (!r_R2())
{
return false;
}
// <-, line 114
// <-, line 115
slice_from("u");
break;
case 5:
// (, line 117
// call R2, line 118
// (, line 118
// call R2, line 119
if (!r_R2())
{
return false;
}
// <-, line 118
// <-, line 119
slice_from("ente");
break;
case 6:
// (, line 121
// call R1, line 122
// (, line 122
// call R1, line 123
if (!r_R1())
{
return false;
}
// delete, line 122
// delete, line 123
slice_del();
// try, line 123
// try, line 124
v_2 = limit - cursor;
lab1: do {
// (, line 123
// [, line 124
// (, line 124
// [, line 125
ket = cursor;
// substring, line 124
// substring, line 125
among_var = find_among_b(a_3, 4);
if (among_var == 0)
{
cursor = limit - v_2;
break lab1;
}
// ], line 124
// ], line 125
bra = cursor;
// call R2, line 124
// call R2, line 125
if (!r_R2())
{
cursor = limit - v_2;
break lab1;
}
// delete, line 124
// delete, line 125
slice_del();
switch(among_var) {
case 0:
cursor = limit - v_2;
break lab1;
case 1:
// (, line 125
// [, line 125
// (, line 126
// [, line 126
ket = cursor;
// literal, line 125
// literal, line 126
if (!(eq_s_b(2, "at")))
{
cursor = limit - v_2;
break lab1;
}
// ], line 125
// ], line 126
bra = cursor;
// call R2, line 125
// call R2, line 126
if (!r_R2())
{
cursor = limit - v_2;
break lab1;
}
// delete, line 125
// delete, line 126
slice_del();
break;
}
} while (false);
break;
case 7:
// (, line 133
// call R2, line 134
// (, line 134
// call R2, line 135
if (!r_R2())
{
return false;
}
// delete, line 134
// delete, line 135
slice_del();
// try, line 135
// try, line 136
v_3 = limit - cursor;
lab2: do {
// (, line 135
// [, line 136
// (, line 136
// [, line 137
ket = cursor;
// substring, line 136
among_var = find_among_b(a_4, 2);
// substring, line 137
among_var = find_among_b(a_4, 3);
if (among_var == 0)
{
cursor = limit - v_3;
break lab2;
}
// ], line 136
// ], line 137
bra = cursor;
switch(among_var) {
case 0:
cursor = limit - v_3;
break lab2;
case 1:
// (, line 138
// call R2, line 138
// (, line 140
// call R2, line 140
if (!r_R2())
{
cursor = limit - v_3;
break lab2;
}
// delete, line 138
// delete, line 140
slice_del();
break;
}
} while (false);
break;
case 8:
// (, line 144
// call R2, line 145
// (, line 146
// call R2, line 147
if (!r_R2())
{
return false;
}
// delete, line 145
// delete, line 147
slice_del();
// try, line 146
// try, line 148
v_4 = limit - cursor;
lab3: do {
// (, line 146
// [, line 147
// (, line 148
// [, line 149
ket = cursor;
// substring, line 147
// substring, line 149
among_var = find_among_b(a_5, 3);
if (among_var == 0)
{
cursor = limit - v_4;
break lab3;
}
// ], line 147
// ], line 149
bra = cursor;
switch(among_var) {
case 0:
cursor = limit - v_4;
break lab3;
case 1:
// (, line 150
// call R2, line 150
// (, line 152
// call R2, line 152
if (!r_R2())
{
cursor = limit - v_4;
break lab3;
}
// delete, line 150
// delete, line 152
slice_del();
break;
}
} while (false);
break;
case 9:
// (, line 156
// call R2, line 157
// (, line 158
// call R2, line 159
if (!r_R2())
{
return false;
}
// delete, line 157
// delete, line 159
slice_del();
// try, line 158
// try, line 160
v_5 = limit - cursor;
lab4: do {
// (, line 158
// [, line 159
// (, line 160
// [, line 161
ket = cursor;
// literal, line 159
// literal, line 161
if (!(eq_s_b(2, "at")))
{
cursor = limit - v_5;
break lab4;
}
// ], line 159
// ], line 161
bra = cursor;
// call R2, line 159
// call R2, line 161
if (!r_R2())
{
cursor = limit - v_5;
break lab4;
}
// delete, line 159
// delete, line 161
slice_del();
} while (false);
break;
@ -900,10 +905,10 @@ public class SpanishStemmer extends SnowballProgram {
int among_var;
int v_1;
int v_2;
// (, line 165
// setlimit, line 166
// (, line 167
// setlimit, line 168
v_1 = limit - cursor;
// tomark, line 166
// tomark, line 168
if (cursor < I_pV)
{
return false;
@ -912,30 +917,30 @@ public class SpanishStemmer extends SnowballProgram {
v_2 = limit_backward;
limit_backward = cursor;
cursor = limit - v_1;
// (, line 166
// [, line 166
// (, line 168
// [, line 168
ket = cursor;
// substring, line 166
// substring, line 168
among_var = find_among_b(a_7, 12);
if (among_var == 0)
{
limit_backward = v_2;
return false;
}
// ], line 166
// ], line 168
bra = cursor;
limit_backward = v_2;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 169
// literal, line 169
// (, line 171
// literal, line 171
if (!(eq_s_b(1, "u")))
{
return false;
}
// delete, line 169
// delete, line 171
slice_del();
break;
}
@ -948,10 +953,10 @@ public class SpanishStemmer extends SnowballProgram {
int v_2;
int v_3;
int v_4;
// (, line 173
// setlimit, line 174
// (, line 175
// setlimit, line 176
v_1 = limit - cursor;
// tomark, line 174
// tomark, line 176
if (cursor < I_pV)
{
return false;
@ -960,37 +965,37 @@ public class SpanishStemmer extends SnowballProgram {
v_2 = limit_backward;
limit_backward = cursor;
cursor = limit - v_1;
// (, line 174
// [, line 174
// (, line 176
// [, line 176
ket = cursor;
// substring, line 174
// substring, line 176
among_var = find_among_b(a_8, 96);
if (among_var == 0)
{
limit_backward = v_2;
return false;
}
// ], line 174
// ], line 176
bra = cursor;
limit_backward = v_2;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 177
// try, line 177
// (, line 179
// try, line 179
v_3 = limit - cursor;
lab0: do {
// (, line 177
// literal, line 177
// (, line 179
// literal, line 179
if (!(eq_s_b(1, "u")))
{
cursor = limit - v_3;
break lab0;
}
// test, line 177
// test, line 179
v_4 = limit - cursor;
// literal, line 177
// literal, line 179
if (!(eq_s_b(1, "g")))
{
cursor = limit - v_3;
@ -998,14 +1003,14 @@ public class SpanishStemmer extends SnowballProgram {
}
cursor = limit - v_4;
} while (false);
// ], line 177
// ], line 179
bra = cursor;
// delete, line 177
// delete, line 179
slice_del();
break;
case 2:
// (, line 198
// delete, line 198
// (, line 200
// delete, line 200
slice_del();
break;
}
@ -1016,31 +1021,21 @@ public class SpanishStemmer extends SnowballProgram {
int among_var;
int v_1;
int v_2;
// (, line 202
// [, line 203
// (, line 204
// [, line 205
ket = cursor;
// substring, line 203
// substring, line 205
among_var = find_among_b(a_9, 8);
if (among_var == 0)
{
return false;
}
// ], line 203
// ], line 205
bra = cursor;
switch(among_var) {
case 0:
return false;
case 1:
// (, line 206
// call RV, line 206
if (!r_RV())
{
return false;
}
// delete, line 206
slice_del();
break;
case 2:
// (, line 208
// call RV, line 208
if (!r_RV())
@ -1049,36 +1044,46 @@ public class SpanishStemmer extends SnowballProgram {
}
// delete, line 208
slice_del();
// try, line 208
break;
case 2:
// (, line 210
// call RV, line 210
if (!r_RV())
{
return false;
}
// delete, line 210
slice_del();
// try, line 210
v_1 = limit - cursor;
lab0: do {
// (, line 208
// [, line 208
// (, line 210
// [, line 210
ket = cursor;
// literal, line 208
// literal, line 210
if (!(eq_s_b(1, "u")))
{
cursor = limit - v_1;
break lab0;
}
// ], line 208
// ], line 210
bra = cursor;
// test, line 208
// test, line 210
v_2 = limit - cursor;
// literal, line 208
// literal, line 210
if (!(eq_s_b(1, "g")))
{
cursor = limit - v_1;
break lab0;
}
cursor = limit - v_2;
// call RV, line 208
// call RV, line 210
if (!r_RV())
{
cursor = limit - v_1;
break lab0;
}
// delete, line 208
// delete, line 210
slice_del();
} while (false);
break;
@ -1093,39 +1098,39 @@ public class SpanishStemmer extends SnowballProgram {
int v_4;
int v_5;
int v_6;
// (, line 213
// do, line 214
// (, line 215
// do, line 216
v_1 = cursor;
lab0: do {
// call mark_regions, line 214
// call mark_regions, line 216
if (!r_mark_regions())
{
break lab0;
}
} while (false);
cursor = v_1;
// backwards, line 215
// backwards, line 217
limit_backward = cursor; cursor = limit;
// (, line 215
// do, line 216
// (, line 217
// do, line 218
v_2 = limit - cursor;
lab1: do {
// call attached_pronoun, line 216
// call attached_pronoun, line 218
if (!r_attached_pronoun())
{
break lab1;
}
} while (false);
cursor = limit - v_2;
// do, line 217
// do, line 219
v_3 = limit - cursor;
lab2: do {
// (, line 217
// or, line 217
// (, line 219
// or, line 219
lab3: do {
v_4 = limit - cursor;
lab4: do {
// call standard_suffix, line 217
// call standard_suffix, line 219
if (!r_standard_suffix())
{
break lab4;
@ -1134,7 +1139,7 @@ public class SpanishStemmer extends SnowballProgram {
} while (false);
cursor = limit - v_4;
lab5: do {
// call y_verb_suffix, line 218
// call y_verb_suffix, line 220
if (!r_y_verb_suffix())
{
break lab5;
@ -1142,7 +1147,7 @@ public class SpanishStemmer extends SnowballProgram {
break lab3;
} while (false);
cursor = limit - v_4;
// call verb_suffix, line 219
// call verb_suffix, line 221
if (!r_verb_suffix())
{
break lab2;
@ -1150,20 +1155,20 @@ public class SpanishStemmer extends SnowballProgram {
} while (false);
} while (false);
cursor = limit - v_3;
// do, line 221
// do, line 223
v_5 = limit - cursor;
lab6: do {
// call residual_suffix, line 221
// call residual_suffix, line 223
if (!r_residual_suffix())
{
break lab6;
}
} while (false);
cursor = limit - v_5;
cursor = limit_backward; // do, line 223
cursor = limit_backward; // do, line 225
v_6 = cursor;
lab7: do {
// call postlude, line 223
// call postlude, line 225
if (!r_postlude())
{
break lab7;

View File

@ -1,8 +1,8 @@
// This file was generated automatically by the Snowball to Java compiler
package net.sf.snowball.ext;
import net.sf.snowball.SnowballProgram;
import net.sf.snowball.Among;
package org.tartarus.snowball.ext;
import org.tartarus.snowball.SnowballProgram;
import org.tartarus.snowball.Among;
/**
* Generated class implementing code defined by a snowball script.
@ -71,30 +71,48 @@ public class SwedishStemmer extends SnowballProgram {
private static final char g_s_ending[] = {119, 127, 149 };
private int I_x;
private int I_p1;
private void copy_from(SwedishStemmer other) {
I_x = other.I_x;
I_p1 = other.I_p1;
super.copy_from(other);
}
private boolean r_mark_regions() {
int v_1;
int v_2;
// (, line 26
I_p1 = limit;
// test, line 29
v_1 = cursor;
// (, line 29
// hop, line 29
{
int c = cursor + 3;
if (0 > c || c > limit)
{
return false;
}
cursor = c;
}
// setmark x, line 29
I_x = cursor;
cursor = v_1;
// goto, line 30
golab0: while(true)
{
v_1 = cursor;
v_2 = cursor;
lab1: do {
if (!(in_grouping(g_v, 97, 246)))
{
break lab1;
}
cursor = v_1;
cursor = v_2;
break golab0;
} while (false);
cursor = v_1;
cursor = v_2;
if (cursor >= limit)
{
return false;
@ -122,11 +140,11 @@ public class SwedishStemmer extends SnowballProgram {
// try, line 31
lab4: do {
// (, line 31
if (!(I_p1 < 3))
if (!(I_p1 < I_x))
{
break lab4;
}
I_p1 = 3;
I_p1 = I_x;
} while (false);
return true;
}

File diff suppressed because it is too large Load Diff

View File

@ -1,5 +1,29 @@
<html>
<body>
Snowball stemmers for Lucene
<p>
Lucene Snowball README file
</p>
<p>
This project provides pre-compiled version of the Snowball stemmers
based on revision 500 of the Tartarus Snowball repository,
together with classes integrating them with the Lucene search engine.
</p>
<p>
See the Snowball <a href ="http://snowball.tartarus.org/">home page</a> for more information about the algorithms.
</p>
<p>
<b>IMPORTANT NOTICE ON BACKWARDS COMPATIBILITY!</b>
</p>
<p>
An index created using the Snowball module in Lucene 2.3.2 and below
might not be compatible with the Snowball module in Lucene 2.4 or greater.
</p>
<p>
For more information about this issue see:
https://issues.apache.org/jira/browse/LUCENE-1142
</p>
</body>
</html>

View File

@ -1,7 +1,6 @@
<?xml version="1.0"?>
<document>
<properties>
<author email="cutting@apache.org">Doug Cutting</author>
<title>Overview - Snowball Stemmers for Lucene</title>
</properties>
<body>
@ -13,14 +12,6 @@ together with classes integrating them with the Lucene search engine.
</p>
</section>
<section name="Download">
<p>
Releases of the stemmers are available
<a href="http://jakarta.apache.org/builds/jakarta-lucene-sandbox/snowball/">
here</a>
</p>
</section>
</body>
</document>