morfologik-svn Mailing List for Morfologik
Brought to you by:
dawidweiss,
milek_pl
You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(6) |
Sep
(7) |
Oct
(2) |
Nov
|
Dec
(5) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
|
Feb
(5) |
Mar
(7) |
Apr
(11) |
May
(16) |
Jun
|
Jul
|
Aug
(2) |
Sep
(22) |
Oct
(2) |
Nov
|
Dec
(8) |
2008 |
Jan
(2) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(5) |
2009 |
Jan
(3) |
Feb
(1) |
Mar
(40) |
Apr
(3) |
May
|
Jun
(1) |
Jul
|
Aug
(9) |
Sep
(5) |
Oct
|
Nov
|
Dec
|
2010 |
Jan
|
Feb
(9) |
Mar
(11) |
Apr
(43) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(7) |
Nov
(51) |
Dec
|
2011 |
Jan
(19) |
Feb
(15) |
Mar
(2) |
Apr
(23) |
May
|
Jun
(12) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2012 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
(4) |
Jun
(34) |
Jul
|
Aug
|
Sep
|
Oct
(5) |
Nov
|
Dec
|
2013 |
Jan
|
Feb
|
Mar
(11) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
|
|
|
|
1
|
2
|
3
|
4
(1) |
5
|
6
|
7
(5) |
8
|
9
|
10
(3) |
11
|
12
|
13
|
14
|
15
|
16
|
17
|
18
|
19
|
20
|
21
|
22
|
23
|
24
|
25
|
26
|
27
|
28
|
29
|
30
|
31
|
|
|
|
|
|
From: <mil...@us...> - 2009-08-10 17:29:08
|
Revision: 170 http://morfologik.svn.sourceforge.net/morfologik/?rev=170&view=rev Author: milek_pl Date: 2009-08-10 17:28:54 +0000 (Mon, 10 Aug 2009) Log Message: ----------- start 1.3-dev for real Modified Paths: -------------- morfologik-stemming/trunk/build.xml Modified: morfologik-stemming/trunk/build.xml =================================================================== --- morfologik-stemming/trunk/build.xml 2009-08-10 17:15:33 UTC (rev 169) +++ morfologik-stemming/trunk/build.xml 2009-08-10 17:28:54 UTC (rev 170) @@ -1,6 +1,6 @@ <project name="Stempelator" default="build"> <property name="build.name" value="morfologik-stemming" /> - <property name="build.ver" value="1.2" /> + <property name="build.ver" value="1.3-dev" /> <property name="tmp.dir" value="tmp" /> <property name="build.dir" value="${tmp.dir}/build" /> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mil...@us...> - 2009-08-10 17:15:49
|
Revision: 169 http://morfologik.svn.sourceforge.net/morfologik/?rev=169&view=rev Author: milek_pl Date: 2009-08-10 17:15:33 +0000 (Mon, 10 Aug 2009) Log Message: ----------- Modified Paths: -------------- morfologik-stemming/tags/1.2.1/build.xml Added Paths: ----------- morfologik-stemming/tags/1.2.1/ Modified: morfologik-stemming/tags/1.2.1/build.xml =================================================================== --- morfologik-stemming/trunk/build.xml 2009-08-10 07:42:59 UTC (rev 168) +++ morfologik-stemming/tags/1.2.1/build.xml 2009-08-10 17:15:33 UTC (rev 169) @@ -1,6 +1,6 @@ <project name="Stempelator" default="build"> <property name="build.name" value="morfologik-stemming" /> - <property name="build.ver" value="1.2" /> + <property name="build.ver" value="1.2.1" /> <property name="tmp.dir" value="tmp" /> <property name="build.dir" value="${tmp.dir}/build" /> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <daw...@us...> - 2009-08-10 07:43:13
|
Revision: 168 http://morfologik.svn.sourceforge.net/morfologik/?rev=168&view=rev Author: dawidweiss Date: 2009-08-10 07:42:59 +0000 (Mon, 10 Aug 2009) Log Message: ----------- Added JUnit tests for the launcher. Modified Paths: -------------- morfologik-stemming/trunk/src/morfologik/tools/DumpTool.java morfologik-stemming/trunk/src/morfologik/tools/Launcher.java morfologik-stemming/trunk/src/morfologik/tools/PolishStemmingTool.java Added Paths: ----------- morfologik-stemming/trunk/src-test/morfologik/tools/ morfologik-stemming/trunk/src-test/morfologik/tools/LauncherTest.java Modified: morfologik-stemming/trunk/src/morfologik/tools/DumpTool.java =================================================================== --- morfologik-stemming/trunk/src/morfologik/tools/DumpTool.java 2009-08-07 18:01:32 UTC (rev 167) +++ morfologik-stemming/trunk/src/morfologik/tools/DumpTool.java 2009-08-10 07:42:59 UTC (rev 168) @@ -232,7 +232,7 @@ } /** - * Program's entry point. + * Command line entry point. */ public static void main(String[] args) throws Exception { final DumpTool fsaDump = new DumpTool(); Modified: morfologik-stemming/trunk/src/morfologik/tools/Launcher.java =================================================================== --- morfologik-stemming/trunk/src/morfologik/tools/Launcher.java 2009-08-07 18:01:32 UTC (rev 167) +++ morfologik-stemming/trunk/src/morfologik/tools/Launcher.java 2009-08-10 07:42:59 UTC (rev 168) @@ -11,7 +11,7 @@ /** * Tool description. */ - private final static class ToolInfo { + final static class ToolInfo { public final Class<? extends Tool> clazz; public final String info; @@ -19,15 +19,24 @@ this.clazz = clazz; this.info = info; } + + public void invoke(String[] subArgs) throws Exception { + final Method m = clazz.getMethod("main", + new Class[] { String[].class }); + m.invoke(null, new Object[] { subArgs }); + } } /** * Known tools. */ - private static TreeMap<String, ToolInfo> tools; + static TreeMap<String, ToolInfo> tools; static { tools = new TreeMap<String, ToolInfo>(); - tools.put("dump", new ToolInfo(DumpTool.class, "Dump an FSA dictionary.")); tools.put("plstem", new ToolInfo(PolishStemmingTool.class, "Apply Polish stemming to the input.")); + tools.put("dump", new ToolInfo(DumpTool.class, + "Dump an FSA dictionary.")); + tools.put("plstem", new ToolInfo(PolishStemmingTool.class, + "Apply Polish stemming to the input.")); } /** @@ -52,9 +61,7 @@ System.arraycopy(args, 1, subArgs, 0, subArgs.length); final ToolInfo toolInfo = (ToolInfo) tools.get(toolName); - final Method m = toolInfo.clazz.getMethod("main", - new Class[] { String[].class }); - m.invoke(null, new Object[] { subArgs }); + toolInfo.invoke(subArgs); } } } Modified: morfologik-stemming/trunk/src/morfologik/tools/PolishStemmingTool.java =================================================================== --- morfologik-stemming/trunk/src/morfologik/tools/PolishStemmingTool.java 2009-08-07 18:01:32 UTC (rev 167) +++ morfologik-stemming/trunk/src/morfologik/tools/PolishStemmingTool.java 2009-08-10 07:42:59 UTC (rev 168) @@ -177,4 +177,12 @@ } return encoding; } + + /** + * Command line entry point. + */ + public static void main(String[] args) throws Exception { + final PolishStemmingTool tool = new PolishStemmingTool(); + tool.go(args); + } } \ No newline at end of file Added: morfologik-stemming/trunk/src-test/morfologik/tools/LauncherTest.java =================================================================== --- morfologik-stemming/trunk/src-test/morfologik/tools/LauncherTest.java (rev 0) +++ morfologik-stemming/trunk/src-test/morfologik/tools/LauncherTest.java 2009-08-10 07:42:59 UTC (rev 168) @@ -0,0 +1,25 @@ +package morfologik.tools; + +import java.util.Map; + +import morfologik.tools.Launcher.ToolInfo; + +import org.junit.Assert; +import org.junit.Test; + +/* + * + */ +public class LauncherTest { + /* */ + @Test + public void testTools() throws Exception { + for (Map.Entry<String, ToolInfo> e : Launcher.tools.entrySet()) { + try { + e.getValue().invoke(new String [] {}); + } catch (Throwable t) { + Assert.fail("Unable to launch " + e.getKey() + ": " + t.getMessage()); + } + } + } +} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mil...@us...> - 2009-08-07 18:01:41
|
Revision: 167 http://morfologik.svn.sourceforge.net/morfologik/?rev=167&view=rev Author: milek_pl Date: 2009-08-07 18:01:32 +0000 (Fri, 07 Aug 2009) Log Message: ----------- start 1.3 Added Paths: ----------- morfologik-stemming/tags/1.3-dev/ morfologik-stemming/tags/1.3-dev/.settings/org.eclipse.core.resources.prefs morfologik-stemming/tags/1.3-dev/build.xml Removed Paths: ------------- morfologik-stemming/tags/1.3-dev/build.xml Copied: morfologik-stemming/tags/1.3-dev/.settings/org.eclipse.core.resources.prefs (from rev 164, morfologik-stemming/trunk/.settings/org.eclipse.core.resources.prefs) =================================================================== --- morfologik-stemming/tags/1.3-dev/.settings/org.eclipse.core.resources.prefs (rev 0) +++ morfologik-stemming/tags/1.3-dev/.settings/org.eclipse.core.resources.prefs 2009-08-07 18:01:32 UTC (rev 167) @@ -0,0 +1,3 @@ +#Tue Mar 17 15:23:20 CET 2009 +eclipse.preferences.version=1 +encoding/<project>=UTF-8 Deleted: morfologik-stemming/tags/1.3-dev/build.xml =================================================================== --- morfologik-stemming/trunk/build.xml 2009-08-07 12:25:31 UTC (rev 163) +++ morfologik-stemming/tags/1.3-dev/build.xml 2009-08-07 18:01:32 UTC (rev 167) @@ -1,177 +0,0 @@ -<project name="Stempelator" default="build"> - <property name="build.name" value="morfologik-stemming" /> - <property name="build.ver" value="1.2-dev" /> - - <property name="tmp.dir" value="tmp" /> - <property name="build.dir" value="${tmp.dir}/build" /> - <property name="build.test.dir" value="${tmp.dir}/test" /> - <property name="dist.dir" value="dist" /> - - <property name="jarfile-nodict" value="${tmp.dir}/bin/${build.name}-nodict-${build.ver}.jar" /> - <property name="jarfile" value="${tmp.dir}/bin/${build.name}-${build.ver}.jar" /> - - <property name="srczip" value="${dist.dir}/${build.name}-${build.ver}-src.zip" /> - <property name="binzip" value="${dist.dir}/${build.name}-${build.ver}.zip" /> - - - <path id="compile.classpath"> - <fileset dir="lib"> - <include name="**/*.jar" /> - </fileset> - </path> - - <fileset dir="lib" id="runtime.dependencies"> - <include name="**/*.jar" /> - <exclude name="junit*.jar" /> - </fileset> - - - <target name="init"> - <tstamp /> - <mkdir dir="${build.dir}" /> - <mkdir dir="${build.test.dir}" /> - <mkdir dir="${dist.dir}" /> - </target> - - - - <target name="clean"> - <delete dir="${build.dir}" failonerror="false" /> - <delete dir="${dist.dir}" failonerror="false" /> - <delete dir="${tmp.dir}" failonerror="false"> - <exclude name="eclipse/**" /> - </delete> - </target> - - - - <target name="compile" depends="init"> - <javac classpath="${classpath}" destdir="${build.dir}" encoding="UTF-8" - source="1.5" target="1.5"> - <classpath refid="compile.classpath" /> - <include name="**/*.java" /> - <src location="src" /> - </javac> - - <!-- Copy additional resources to the build folder. --> - <copy todir="${build.dir}"> - <fileset dir="src"> - <exclude name="**/*.java" /> - </fileset> - </copy> - </target> - - - - <target name="compile.test" depends="init,compile"> - <javac classpath="${classpath}" destdir="${build.test.dir}" encoding="UTF-8"> - <classpath refid="compile.classpath" /> - <classpath location="${build.dir}" /> - - <src location="src-test" /> - </javac> - - <!-- Copy additional resources to the build folder. --> - <copy todir="${build.test.dir}"> - <fileset dir="src-test"> - <exclude name="**/*.java" /> - </fileset> - </copy> - </target> - - - - <target name="test" depends="compile, compile.test"> - <mkdir dir="${tmp.dir}/tests" /> - <junit printsummary="yes" haltonfailure="yes"> - <classpath refid="compile.classpath" /> - <classpath location="${build.dir}" /> - <classpath location="${build.test.dir}" /> - - <formatter type="plain" /> - - <batchtest todir="${tmp.dir}/tests"> - <fileset dir="src-test"> - <include name="**/*Test.java" /> - </fileset> - </batchtest> - </junit> - </target> - - - - <target name="javadoc" depends="init"> - <javadoc sourcepath="src" packagenames="morfologik.*" destdir="${tmp.dir}/javadoc"> - <classpath refid="compile.classpath" /> - </javadoc> - </target> - - - - <target name="jar" depends="clean, compile"> - <mkdir dir="${tmp.dir}/bin" /> - - <property name="main.class" value="morfologik.tools.Launcher" /> - - <pathconvert property="manifest.classpath" pathsep=" "> - <flattenmapper /> - <path> - <fileset refid="runtime.dependencies" /> - </path> - </pathconvert> - - <jar jarfile="${jarfile}"> - <fileset dir="${build.dir}" /> - <zipfileset file="LICENSE" fullpath="META-INF/Morfologik.LICENSE" /> - <manifest> - <attribute name="Main-Class" value="${main.class}" /> - <attribute name="Class-Path" value="${manifest.classpath}" /> - </manifest> - </jar> - - <jar jarfile="${jarfile-nodict}"> - <fileset dir="${build.dir}"> - <exclude name="morfologik/dictionaries/**" /> - </fileset> - <zipfileset file="LICENSE" fullpath="META-INF/Morfologik.LICENSE" /> - <manifest> - <attribute name="Main-Class" value="${main.class}" /> - <attribute name="Class-Path" value="${manifest.classpath}" /> - </manifest> - </jar> - </target> - - - - <target name="build" depends="jar"> - <copy todir="${tmp.dir}/bin"> - <fileset refid="runtime.dependencies" /> - <fileset dir="."> - <include name="LICENSE*.txt" /> - <include name="README.txt" /> - <include name="version.txt" /> - </fileset> - </copy> - </target> - - - - <target name="dist" depends="clean,test,build,javadoc"> - <!-- Package source distribution --> - <fileset dir="." id="srcdistfiles"> - <exclude name="tmp/**" /> - <exclude name="dist/**" /> - <exclude name=".settings/**" /> - <exclude name="${srczip}" /> - </fileset> - - <zip destfile="${srczip}"> - <fileset refid="srcdistfiles" /> - <zipfileset prefix="doc/api" dir="${tmp.dir}/javadoc" /> - </zip> - <zip destfile="${binzip}"> - <fileset dir="${tmp.dir}/bin" /> - <zipfileset prefix="api" dir="${tmp.dir}/javadoc" /> - </zip> - </target> -</project> Copied: morfologik-stemming/tags/1.3-dev/build.xml (from rev 164, morfologik-stemming/trunk/build.xml) =================================================================== --- morfologik-stemming/tags/1.3-dev/build.xml (rev 0) +++ morfologik-stemming/tags/1.3-dev/build.xml 2009-08-07 18:01:32 UTC (rev 167) @@ -0,0 +1,177 @@ +<project name="Stempelator" default="build"> + <property name="build.name" value="morfologik-stemming" /> + <property name="build.ver" value="1.3-dev" /> + + <property name="tmp.dir" value="tmp" /> + <property name="build.dir" value="${tmp.dir}/build" /> + <property name="build.test.dir" value="${tmp.dir}/test" /> + <property name="dist.dir" value="dist" /> + + <property name="jarfile-nodict" value="${tmp.dir}/bin/${build.name}-nodict-${build.ver}.jar" /> + <property name="jarfile" value="${tmp.dir}/bin/${build.name}-${build.ver}.jar" /> + + <property name="srczip" value="${dist.dir}/${build.name}-${build.ver}-src.zip" /> + <property name="binzip" value="${dist.dir}/${build.name}-${build.ver}.zip" /> + + + <path id="compile.classpath"> + <fileset dir="lib"> + <include name="**/*.jar" /> + </fileset> + </path> + + <fileset dir="lib" id="runtime.dependencies"> + <include name="**/*.jar" /> + <exclude name="junit*.jar" /> + </fileset> + + + <target name="init"> + <tstamp /> + <mkdir dir="${build.dir}" /> + <mkdir dir="${build.test.dir}" /> + <mkdir dir="${dist.dir}" /> + </target> + + + + <target name="clean"> + <delete dir="${build.dir}" failonerror="false" /> + <delete dir="${dist.dir}" failonerror="false" /> + <delete dir="${tmp.dir}" failonerror="false"> + <exclude name="eclipse/**" /> + </delete> + </target> + + + + <target name="compile" depends="init"> + <javac classpath="${classpath}" destdir="${build.dir}" encoding="UTF-8" + source="1.5" target="1.5"> + <classpath refid="compile.classpath" /> + <include name="**/*.java" /> + <src location="src" /> + </javac> + + <!-- Copy additional resources to the build folder. --> + <copy todir="${build.dir}"> + <fileset dir="src"> + <exclude name="**/*.java" /> + </fileset> + </copy> + </target> + + + + <target name="compile.test" depends="init,compile"> + <javac classpath="${classpath}" destdir="${build.test.dir}" encoding="UTF-8"> + <classpath refid="compile.classpath" /> + <classpath location="${build.dir}" /> + + <src location="src-test" /> + </javac> + + <!-- Copy additional resources to the build folder. --> + <copy todir="${build.test.dir}"> + <fileset dir="src-test"> + <exclude name="**/*.java" /> + </fileset> + </copy> + </target> + + + + <target name="test" depends="compile, compile.test"> + <mkdir dir="${tmp.dir}/tests" /> + <junit printsummary="yes" haltonfailure="yes"> + <classpath refid="compile.classpath" /> + <classpath location="${build.dir}" /> + <classpath location="${build.test.dir}" /> + + <formatter type="plain" /> + + <batchtest todir="${tmp.dir}/tests"> + <fileset dir="src-test"> + <include name="**/*Test.java" /> + </fileset> + </batchtest> + </junit> + </target> + + + + <target name="javadoc" depends="init"> + <javadoc sourcepath="src" packagenames="morfologik.*" destdir="${tmp.dir}/javadoc"> + <classpath refid="compile.classpath" /> + </javadoc> + </target> + + + + <target name="jar" depends="clean, compile"> + <mkdir dir="${tmp.dir}/bin" /> + + <property name="main.class" value="morfologik.tools.Launcher" /> + + <pathconvert property="manifest.classpath" pathsep=" "> + <flattenmapper /> + <path> + <fileset refid="runtime.dependencies" /> + </path> + </pathconvert> + + <jar jarfile="${jarfile}"> + <fileset dir="${build.dir}" /> + <zipfileset file="LICENSE" fullpath="META-INF/Morfologik.LICENSE" /> + <manifest> + <attribute name="Main-Class" value="${main.class}" /> + <attribute name="Class-Path" value="${manifest.classpath}" /> + </manifest> + </jar> + + <jar jarfile="${jarfile-nodict}"> + <fileset dir="${build.dir}"> + <exclude name="morfologik/dictionaries/**" /> + </fileset> + <zipfileset file="LICENSE" fullpath="META-INF/Morfologik.LICENSE" /> + <manifest> + <attribute name="Main-Class" value="${main.class}" /> + <attribute name="Class-Path" value="${manifest.classpath}" /> + </manifest> + </jar> + </target> + + + + <target name="build" depends="jar"> + <copy todir="${tmp.dir}/bin"> + <fileset refid="runtime.dependencies" /> + <fileset dir="."> + <include name="LICENSE*.txt" /> + <include name="README.txt" /> + <include name="version.txt" /> + </fileset> + </copy> + </target> + + + + <target name="dist" depends="clean,test,build,javadoc"> + <!-- Package source distribution --> + <fileset dir="." id="srcdistfiles"> + <exclude name="tmp/**" /> + <exclude name="dist/**" /> + <exclude name=".settings/**" /> + <exclude name="${srczip}" /> + </fileset> + + <zip destfile="${srczip}"> + <fileset refid="srcdistfiles" /> + <zipfileset prefix="doc/api" dir="${tmp.dir}/javadoc" /> + </zip> + <zip destfile="${binzip}"> + <fileset dir="${tmp.dir}/bin" /> + <zipfileset prefix="api" dir="${tmp.dir}/javadoc" /> + </zip> + </target> +</project> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mil...@us...> - 2009-08-07 17:42:22
|
Revision: 166 http://morfologik.svn.sourceforge.net/morfologik/?rev=166&view=rev Author: milek_pl Date: 2009-08-07 17:42:15 +0000 (Fri, 07 Aug 2009) Log Message: ----------- Added Paths: ----------- morfologik-stemming/tags/1.2/ morfologik-stemming/tags/1.2/.settings/org.eclipse.core.resources.prefs morfologik-stemming/tags/1.2/build.xml Removed Paths: ------------- morfologik-stemming/tags/1.2/build.xml Copied: morfologik-stemming/tags/1.2/.settings/org.eclipse.core.resources.prefs (from rev 164, morfologik-stemming/trunk/.settings/org.eclipse.core.resources.prefs) =================================================================== --- morfologik-stemming/tags/1.2/.settings/org.eclipse.core.resources.prefs (rev 0) +++ morfologik-stemming/tags/1.2/.settings/org.eclipse.core.resources.prefs 2009-08-07 17:42:15 UTC (rev 166) @@ -0,0 +1,3 @@ +#Tue Mar 17 15:23:20 CET 2009 +eclipse.preferences.version=1 +encoding/<project>=UTF-8 Deleted: morfologik-stemming/tags/1.2/build.xml =================================================================== --- morfologik-stemming/trunk/build.xml 2009-08-07 12:25:31 UTC (rev 163) +++ morfologik-stemming/tags/1.2/build.xml 2009-08-07 17:42:15 UTC (rev 166) @@ -1,177 +0,0 @@ -<project name="Stempelator" default="build"> - <property name="build.name" value="morfologik-stemming" /> - <property name="build.ver" value="1.2-dev" /> - - <property name="tmp.dir" value="tmp" /> - <property name="build.dir" value="${tmp.dir}/build" /> - <property name="build.test.dir" value="${tmp.dir}/test" /> - <property name="dist.dir" value="dist" /> - - <property name="jarfile-nodict" value="${tmp.dir}/bin/${build.name}-nodict-${build.ver}.jar" /> - <property name="jarfile" value="${tmp.dir}/bin/${build.name}-${build.ver}.jar" /> - - <property name="srczip" value="${dist.dir}/${build.name}-${build.ver}-src.zip" /> - <property name="binzip" value="${dist.dir}/${build.name}-${build.ver}.zip" /> - - - <path id="compile.classpath"> - <fileset dir="lib"> - <include name="**/*.jar" /> - </fileset> - </path> - - <fileset dir="lib" id="runtime.dependencies"> - <include name="**/*.jar" /> - <exclude name="junit*.jar" /> - </fileset> - - - <target name="init"> - <tstamp /> - <mkdir dir="${build.dir}" /> - <mkdir dir="${build.test.dir}" /> - <mkdir dir="${dist.dir}" /> - </target> - - - - <target name="clean"> - <delete dir="${build.dir}" failonerror="false" /> - <delete dir="${dist.dir}" failonerror="false" /> - <delete dir="${tmp.dir}" failonerror="false"> - <exclude name="eclipse/**" /> - </delete> - </target> - - - - <target name="compile" depends="init"> - <javac classpath="${classpath}" destdir="${build.dir}" encoding="UTF-8" - source="1.5" target="1.5"> - <classpath refid="compile.classpath" /> - <include name="**/*.java" /> - <src location="src" /> - </javac> - - <!-- Copy additional resources to the build folder. --> - <copy todir="${build.dir}"> - <fileset dir="src"> - <exclude name="**/*.java" /> - </fileset> - </copy> - </target> - - - - <target name="compile.test" depends="init,compile"> - <javac classpath="${classpath}" destdir="${build.test.dir}" encoding="UTF-8"> - <classpath refid="compile.classpath" /> - <classpath location="${build.dir}" /> - - <src location="src-test" /> - </javac> - - <!-- Copy additional resources to the build folder. --> - <copy todir="${build.test.dir}"> - <fileset dir="src-test"> - <exclude name="**/*.java" /> - </fileset> - </copy> - </target> - - - - <target name="test" depends="compile, compile.test"> - <mkdir dir="${tmp.dir}/tests" /> - <junit printsummary="yes" haltonfailure="yes"> - <classpath refid="compile.classpath" /> - <classpath location="${build.dir}" /> - <classpath location="${build.test.dir}" /> - - <formatter type="plain" /> - - <batchtest todir="${tmp.dir}/tests"> - <fileset dir="src-test"> - <include name="**/*Test.java" /> - </fileset> - </batchtest> - </junit> - </target> - - - - <target name="javadoc" depends="init"> - <javadoc sourcepath="src" packagenames="morfologik.*" destdir="${tmp.dir}/javadoc"> - <classpath refid="compile.classpath" /> - </javadoc> - </target> - - - - <target name="jar" depends="clean, compile"> - <mkdir dir="${tmp.dir}/bin" /> - - <property name="main.class" value="morfologik.tools.Launcher" /> - - <pathconvert property="manifest.classpath" pathsep=" "> - <flattenmapper /> - <path> - <fileset refid="runtime.dependencies" /> - </path> - </pathconvert> - - <jar jarfile="${jarfile}"> - <fileset dir="${build.dir}" /> - <zipfileset file="LICENSE" fullpath="META-INF/Morfologik.LICENSE" /> - <manifest> - <attribute name="Main-Class" value="${main.class}" /> - <attribute name="Class-Path" value="${manifest.classpath}" /> - </manifest> - </jar> - - <jar jarfile="${jarfile-nodict}"> - <fileset dir="${build.dir}"> - <exclude name="morfologik/dictionaries/**" /> - </fileset> - <zipfileset file="LICENSE" fullpath="META-INF/Morfologik.LICENSE" /> - <manifest> - <attribute name="Main-Class" value="${main.class}" /> - <attribute name="Class-Path" value="${manifest.classpath}" /> - </manifest> - </jar> - </target> - - - - <target name="build" depends="jar"> - <copy todir="${tmp.dir}/bin"> - <fileset refid="runtime.dependencies" /> - <fileset dir="."> - <include name="LICENSE*.txt" /> - <include name="README.txt" /> - <include name="version.txt" /> - </fileset> - </copy> - </target> - - - - <target name="dist" depends="clean,test,build,javadoc"> - <!-- Package source distribution --> - <fileset dir="." id="srcdistfiles"> - <exclude name="tmp/**" /> - <exclude name="dist/**" /> - <exclude name=".settings/**" /> - <exclude name="${srczip}" /> - </fileset> - - <zip destfile="${srczip}"> - <fileset refid="srcdistfiles" /> - <zipfileset prefix="doc/api" dir="${tmp.dir}/javadoc" /> - </zip> - <zip destfile="${binzip}"> - <fileset dir="${tmp.dir}/bin" /> - <zipfileset prefix="api" dir="${tmp.dir}/javadoc" /> - </zip> - </target> -</project> Copied: morfologik-stemming/tags/1.2/build.xml (from rev 164, morfologik-stemming/trunk/build.xml) =================================================================== --- morfologik-stemming/tags/1.2/build.xml (rev 0) +++ morfologik-stemming/tags/1.2/build.xml 2009-08-07 17:42:15 UTC (rev 166) @@ -0,0 +1,177 @@ +<project name="Stempelator" default="build"> + <property name="build.name" value="morfologik-stemming" /> + <property name="build.ver" value="1.2" /> + + <property name="tmp.dir" value="tmp" /> + <property name="build.dir" value="${tmp.dir}/build" /> + <property name="build.test.dir" value="${tmp.dir}/test" /> + <property name="dist.dir" value="dist" /> + + <property name="jarfile-nodict" value="${tmp.dir}/bin/${build.name}-nodict-${build.ver}.jar" /> + <property name="jarfile" value="${tmp.dir}/bin/${build.name}-${build.ver}.jar" /> + + <property name="srczip" value="${dist.dir}/${build.name}-${build.ver}-src.zip" /> + <property name="binzip" value="${dist.dir}/${build.name}-${build.ver}.zip" /> + + + <path id="compile.classpath"> + <fileset dir="lib"> + <include name="**/*.jar" /> + </fileset> + </path> + + <fileset dir="lib" id="runtime.dependencies"> + <include name="**/*.jar" /> + <exclude name="junit*.jar" /> + </fileset> + + + <target name="init"> + <tstamp /> + <mkdir dir="${build.dir}" /> + <mkdir dir="${build.test.dir}" /> + <mkdir dir="${dist.dir}" /> + </target> + + + + <target name="clean"> + <delete dir="${build.dir}" failonerror="false" /> + <delete dir="${dist.dir}" failonerror="false" /> + <delete dir="${tmp.dir}" failonerror="false"> + <exclude name="eclipse/**" /> + </delete> + </target> + + + + <target name="compile" depends="init"> + <javac classpath="${classpath}" destdir="${build.dir}" encoding="UTF-8" + source="1.5" target="1.5"> + <classpath refid="compile.classpath" /> + <include name="**/*.java" /> + <src location="src" /> + </javac> + + <!-- Copy additional resources to the build folder. --> + <copy todir="${build.dir}"> + <fileset dir="src"> + <exclude name="**/*.java" /> + </fileset> + </copy> + </target> + + + + <target name="compile.test" depends="init,compile"> + <javac classpath="${classpath}" destdir="${build.test.dir}" encoding="UTF-8"> + <classpath refid="compile.classpath" /> + <classpath location="${build.dir}" /> + + <src location="src-test" /> + </javac> + + <!-- Copy additional resources to the build folder. --> + <copy todir="${build.test.dir}"> + <fileset dir="src-test"> + <exclude name="**/*.java" /> + </fileset> + </copy> + </target> + + + + <target name="test" depends="compile, compile.test"> + <mkdir dir="${tmp.dir}/tests" /> + <junit printsummary="yes" haltonfailure="yes"> + <classpath refid="compile.classpath" /> + <classpath location="${build.dir}" /> + <classpath location="${build.test.dir}" /> + + <formatter type="plain" /> + + <batchtest todir="${tmp.dir}/tests"> + <fileset dir="src-test"> + <include name="**/*Test.java" /> + </fileset> + </batchtest> + </junit> + </target> + + + + <target name="javadoc" depends="init"> + <javadoc sourcepath="src" packagenames="morfologik.*" destdir="${tmp.dir}/javadoc"> + <classpath refid="compile.classpath" /> + </javadoc> + </target> + + + + <target name="jar" depends="clean, compile"> + <mkdir dir="${tmp.dir}/bin" /> + + <property name="main.class" value="morfologik.tools.Launcher" /> + + <pathconvert property="manifest.classpath" pathsep=" "> + <flattenmapper /> + <path> + <fileset refid="runtime.dependencies" /> + </path> + </pathconvert> + + <jar jarfile="${jarfile}"> + <fileset dir="${build.dir}" /> + <zipfileset file="LICENSE" fullpath="META-INF/Morfologik.LICENSE" /> + <manifest> + <attribute name="Main-Class" value="${main.class}" /> + <attribute name="Class-Path" value="${manifest.classpath}" /> + </manifest> + </jar> + + <jar jarfile="${jarfile-nodict}"> + <fileset dir="${build.dir}"> + <exclude name="morfologik/dictionaries/**" /> + </fileset> + <zipfileset file="LICENSE" fullpath="META-INF/Morfologik.LICENSE" /> + <manifest> + <attribute name="Main-Class" value="${main.class}" /> + <attribute name="Class-Path" value="${manifest.classpath}" /> + </manifest> + </jar> + </target> + + + + <target name="build" depends="jar"> + <copy todir="${tmp.dir}/bin"> + <fileset refid="runtime.dependencies" /> + <fileset dir="."> + <include name="LICENSE*.txt" /> + <include name="README.txt" /> + <include name="version.txt" /> + </fileset> + </copy> + </target> + + + + <target name="dist" depends="clean,test,build,javadoc"> + <!-- Package source distribution --> + <fileset dir="." id="srcdistfiles"> + <exclude name="tmp/**" /> + <exclude name="dist/**" /> + <exclude name=".settings/**" /> + <exclude name="${srczip}" /> + </fileset> + + <zip destfile="${srczip}"> + <fileset refid="srcdistfiles" /> + <zipfileset prefix="doc/api" dir="${tmp.dir}/javadoc" /> + </zip> + <zip destfile="${binzip}"> + <fileset dir="${tmp.dir}/bin" /> + <zipfileset prefix="api" dir="${tmp.dir}/javadoc" /> + </zip> + </target> +</project> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mil...@us...> - 2009-08-07 17:41:59
|
Revision: 165 http://morfologik.svn.sourceforge.net/morfologik/?rev=165&view=rev Author: milek_pl Date: 2009-08-07 17:41:51 +0000 (Fri, 07 Aug 2009) Log Message: ----------- Added Paths: ----------- morfologik-stemming/tags/ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mil...@us...> - 2009-08-07 17:40:15
|
Revision: 164 http://morfologik.svn.sourceforge.net/morfologik/?rev=164&view=rev Author: milek_pl Date: 2009-08-07 17:40:03 +0000 (Fri, 07 Aug 2009) Log Message: ----------- prepare 1.2 Modified Paths: -------------- morfologik-stemming/trunk/build.xml Added Paths: ----------- morfologik-stemming/trunk/.settings/org.eclipse.core.resources.prefs Added: morfologik-stemming/trunk/.settings/org.eclipse.core.resources.prefs =================================================================== --- morfologik-stemming/trunk/.settings/org.eclipse.core.resources.prefs (rev 0) +++ morfologik-stemming/trunk/.settings/org.eclipse.core.resources.prefs 2009-08-07 17:40:03 UTC (rev 164) @@ -0,0 +1,3 @@ +#Tue Mar 17 15:23:20 CET 2009 +eclipse.preferences.version=1 +encoding/<project>=UTF-8 Property changes on: morfologik-stemming/trunk/.settings/org.eclipse.core.resources.prefs ___________________________________________________________________ Added: svn:mime-type + text/plain Modified: morfologik-stemming/trunk/build.xml =================================================================== --- morfologik-stemming/trunk/build.xml 2009-08-07 12:25:31 UTC (rev 163) +++ morfologik-stemming/trunk/build.xml 2009-08-07 17:40:03 UTC (rev 164) @@ -1,6 +1,6 @@ <project name="Stempelator" default="build"> <property name="build.name" value="morfologik-stemming" /> - <property name="build.ver" value="1.2-dev" /> + <property name="build.ver" value="1.2" /> <property name="tmp.dir" value="tmp" /> <property name="build.dir" value="${tmp.dir}/build" /> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <daw...@us...> - 2009-08-07 13:50:54
|
Revision: 163 http://morfologik.svn.sourceforge.net/morfologik/?rev=163&view=rev Author: dawidweiss Date: 2009-08-07 12:25:31 +0000 (Fri, 07 Aug 2009) Log Message: ----------- WordData is now cloneable. Make sure you do clone() WordData objects before storing their references in arrays or tables. Modified Paths: -------------- morfologik-stemming/trunk/src/morfologik/stemming/WordData.java morfologik-stemming/trunk/src-test/morfologik/stemming/DictionaryLookupTest.java Modified: morfologik-stemming/trunk/src/morfologik/stemming/WordData.java =================================================================== --- morfologik-stemming/trunk/src/morfologik/stemming/WordData.java 2009-08-04 13:13:50 UTC (rev 162) +++ morfologik-stemming/trunk/src/morfologik/stemming/WordData.java 2009-08-07 12:25:31 UTC (rev 163) @@ -16,7 +16,7 @@ * <li>Objects of this class are <i>volatile</i> (their content changes on * subsequent calls to {@link DictionaryLookup} class. If you need a copy of the * stem or tag data for a given word, you have to create a custom buffer - * yourself and copy the associated data. Alternatively, create Strings (they + * yourself and copy the associated data, perform {@link #clone()} or create strings (they * are immutable) using {@link #getStem()} and then * {@link CharSequence#toString()}.</li> * <li>Objects of this class must not be used in any Java collections. In fact @@ -24,7 +24,7 @@ * prevent accidental damage.</li> * </ul> */ -public final class WordData { +public final class WordData implements Cloneable { /** * Error information if somebody puts us in a Java collection. */ @@ -191,6 +191,28 @@ } /** + * Declare a covariant of {@link Object#clone()} that returns a deep copy + * of this object. The content of all internal buffers is copied. + */ + @Override + protected WordData clone() { + final WordData clone = new WordData(this.decoder); + clone.wordCharSequence = cloneCharSequence(wordCharSequence); + clone.wordBuffer = getWordBytes(null); + clone.stemBuffer = getStemBytes(null); + clone.tagBuffer = getTagBytes(null); + return clone; + } + + /** + * Clone char sequences only if not immutable. + */ + private CharSequence cloneCharSequence(CharSequence chs) { + if (chs instanceof String) return chs; + return chs.toString(); + } + + /** * Reset internal structures for storing another word's data. */ void reset() { Modified: morfologik-stemming/trunk/src-test/morfologik/stemming/DictionaryLookupTest.java =================================================================== --- morfologik-stemming/trunk/src-test/morfologik/stemming/DictionaryLookupTest.java 2009-08-04 13:13:50 UTC (rev 162) +++ morfologik-stemming/trunk/src-test/morfologik/stemming/DictionaryLookupTest.java 2009-08-07 12:25:31 UTC (rev 163) @@ -67,6 +67,46 @@ /* */ @Test + public void testWordDataCloning() throws IOException { + final URL url = this.getClass().getResource("test-infix.dict"); + final DictionaryLookup s = new DictionaryLookup(Dictionary.read(url)); + + ArrayList<WordData> words = new ArrayList<WordData>(); + for (WordData wd : s) { + WordData clone = wd.clone(); + words.add(clone); + } + + // Reiterate and verify that we have the same entries. + final DictionaryLookup s2 = new DictionaryLookup(Dictionary.read(url)); + int i = 0; + for (WordData wd : s2) { + WordData clone = words.get(i++); + assertEqualSequences(clone.getStem(), wd.getStem()); + assertEqualSequences(clone.getTag(), wd.getTag()); + assertEqualSequences(clone.getWord(), wd.getWord()); + assertEqualSequences(clone.wordCharSequence, wd.wordCharSequence); + } + + // Check collections contract. + final HashSet<WordData> entries = new HashSet<WordData>(); + try + { + entries.add(words.get(0)); + fail(); + } + catch (RuntimeException e) + { + // Expected. + } + } + + private void assertEqualSequences(CharSequence s1, CharSequence s2) { + assertEquals(s1.toString(), s2.toString()); + } + + /* */ + @Test public void testWordDataFields() throws IOException { final IStemmer s = new PolishStemmer(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <mil...@us...> - 2009-08-04 13:13:57
|
Revision: 162 http://morfologik.svn.sourceforge.net/morfologik/?rev=162&view=rev Author: milek_pl Date: 2009-08-04 13:13:50 +0000 (Tue, 04 Aug 2009) Log Message: ----------- this will be 1.3, I guess Modified Paths: -------------- morfologik-stemming/trunk/TODO Modified: morfologik-stemming/trunk/TODO =================================================================== --- morfologik-stemming/trunk/TODO 2009-06-15 22:16:42 UTC (rev 161) +++ morfologik-stemming/trunk/TODO 2009-08-04 13:13:50 UTC (rev 162) @@ -1,5 +1,5 @@ -PLANS FOR VERSION 1.2 +PLANS FOR VERSION 1.3 - Add a set of utility classes for parsing morphological tags. This could be similar (or even compatible?) with Morfeusz-Java. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |