Revision: 7045
http://languagetool.svn.sourceforge.net/languagetool/?rev=7045&view=rev
Author: dnaber
Date: 2012-05-23 22:50:17 +0000 (Wed, 23 May 2012)
Log Message:
-----------
initial support for Greek, by Panagiotis Minos - add missing files
Added Paths:
-----------
trunk/JLanguageTool/src/java/org/languagetool/synthesis/el/
trunk/JLanguageTool/src/java/org/languagetool/synthesis/el/GreekSynthesizer.java
trunk/JLanguageTool/src/java/org/languagetool/tagging/disambiguation/rules/el/
trunk/JLanguageTool/src/java/org/languagetool/tagging/disambiguation/rules/el/GreekRuleDisambiguator.java
Added:
trunk/JLanguageTool/src/java/org/languagetool/synthesis/el/GreekSynthesizer.java
===================================================================
---
trunk/JLanguageTool/src/java/org/languagetool/synthesis/el/GreekSynthesizer.java
(rev 0)
+++
trunk/JLanguageTool/src/java/org/languagetool/synthesis/el/GreekSynthesizer.java
2012-05-23 22:50:17 UTC (rev 7045)
@@ -0,0 +1,59 @@
+/* LanguageTool, a natural language style checker
+ * Copyright (C) 2012 Daniel Naber (http://www.danielnaber.de)
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
+ * USA
+ */
+package org.languagetool.synthesis.el;
+
+import org.languagetool.AnalyzedToken;
+import org.languagetool.JLanguageTool;
+import org.languagetool.synthesis.BaseSynthesizer;
+
+import java.io.IOException;
+
+/**
+ *
+ * @author Panagiotis Minos <[email protected]>
+ */
+public class GreekSynthesizer extends BaseSynthesizer {
+
+ private static final String RESOURCE_FILENAME = "/el/el_synth.dict";
+ private static final String TAGS_FILE_NAME = "/el/el_tags.txt";
+
+ public GreekSynthesizer() {
+ super(JLanguageTool.getDataBroker().getResourceDir() +
RESOURCE_FILENAME,
+ JLanguageTool.getDataBroker().getResourceDir() +
TAGS_FILE_NAME);
+ }
+
+ @Override
+ public String[] synthesize(final AnalyzedToken token, final String posTag)
throws IOException {
+ //System.out.println(token + "\t" + posTag);
+ for (String s : super.synthesize(token, posTag)) {
+ //System.out.println(s);
+ }
+ return super.synthesize(token, posTag);
+ }
+
+ @Override
+ public String[] synthesize(final AnalyzedToken token, final String posTag,
+ final boolean posTagRegExp) throws IOException {
+ //System.out.println(token + "\t" + posTag + "\t" + posTagRegExp);
+ for (String s : super.synthesize(token, posTag, posTagRegExp)) {
+ //System.out.println(s);
+ }
+ return super.synthesize(token, posTag, posTagRegExp);
+ }
+}
Added:
trunk/JLanguageTool/src/java/org/languagetool/tagging/disambiguation/rules/el/GreekRuleDisambiguator.java
===================================================================
---
trunk/JLanguageTool/src/java/org/languagetool/tagging/disambiguation/rules/el/GreekRuleDisambiguator.java
(rev 0)
+++
trunk/JLanguageTool/src/java/org/languagetool/tagging/disambiguation/rules/el/GreekRuleDisambiguator.java
2012-05-23 22:50:17 UTC (rev 7045)
@@ -0,0 +1,34 @@
+/* LanguageTool, a natural language style checker
+ * Copyright (C) 2012 Daniel Naber (http://www.danielnaber.de)
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
+ * USA
+ */
+package org.languagetool.tagging.disambiguation.rules.el;
+
+import org.languagetool.Language;
+import org.languagetool.tagging.disambiguation.rules.AbstractRuleDisambiguator;
+
+/**
+ *
+ * @author Panagiotis Minos <[email protected]>
+ */
+public class GreekRuleDisambiguator extends AbstractRuleDisambiguator {
+
+ @Override
+ protected Language getLanguage() {
+ return Language.GREEK;
+ }
+}
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Languagetool-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/languagetool-cvs