You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by rm...@apache.org on 2014/03/17 12:43:19 UTC

svn commit: r1578315 - in /lucene/dev/trunk/lucene: CHANGES.txt analysis/common/src/java/org/apache/lucene/analysis/el/GreekStemmer.java

Author: rmuir
Date: Mon Mar 17 11:43:18 2014
New Revision: 1578315

URL: http://svn.apache.org/r1578315
Log:
LUCENE-5534: add javadocs to GreekStemmer (closes #43)

Modified:
    lucene/dev/trunk/lucene/CHANGES.txt
    lucene/dev/trunk/lucene/analysis/common/src/java/org/apache/lucene/analysis/el/GreekStemmer.java

Modified: lucene/dev/trunk/lucene/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/lucene/CHANGES.txt?rev=1578315&r1=1578314&r2=1578315&view=diff
==============================================================================
--- lucene/dev/trunk/lucene/CHANGES.txt (original)
+++ lucene/dev/trunk/lucene/CHANGES.txt Mon Mar 17 11:43:18 2014
@@ -216,6 +216,11 @@ Build
 * LUCENE-5512: Remove redundant typing (use diamond operator) throughout
   the codebase.  (Furkan KAMACI via Robert Muir)
 
+Documentation:
+
+* LUCENE-5534: Add javadocs to GreekStemmer methods. 
+  (Stamatis Pitsios via Robert Muir)
+
 ======================= Lucene 4.7.0 =======================
 
 New Features

Modified: lucene/dev/trunk/lucene/analysis/common/src/java/org/apache/lucene/analysis/el/GreekStemmer.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/lucene/analysis/common/src/java/org/apache/lucene/analysis/el/GreekStemmer.java?rev=1578315&r1=1578314&r2=1578315&view=diff
==============================================================================
--- lucene/dev/trunk/lucene/analysis/common/src/java/org/apache/lucene/analysis/el/GreekStemmer.java (original)
+++ lucene/dev/trunk/lucene/analysis/common/src/java/org/apache/lucene/analysis/el/GreekStemmer.java Mon Mar 17 11:43:18 2014
@@ -32,6 +32,15 @@ import java.util.Arrays;
  * @lucene.experimental
  */
 public class GreekStemmer {
+  
+ /**
+   * Stems a word contained in a leading portion of a char[] array.
+   * The word is passed through a number of rules that modify it's length.
+   * 
+   * @param s A char[] array that contains the word to be stemmed.
+   * @param len The length of the char[] array.
+   * @return The new length of the stemmed word.
+   */
   public int stem(char s[], int len) {
     if (len < 4) // too short
       return len;
@@ -773,6 +782,15 @@ public class GreekStemmer {
     return len;
   }
 
+ /**
+   * Checks if the word contained in the leading portion of char[] array , 
+   * ends with the suffix given as parameter.
+   * 
+   * @param s A char[] array that represents a word.
+   * @param len The length of the char[] array.
+   * @param suffix A {@link String} object to check if the word given ends with these characters.
+   * @return True if the word ends with the suffix given , false otherwise.
+   */
   private boolean endsWith(char s[], int len, String suffix) {
     final int suffixLen = suffix.length();
     if (suffixLen > len)
@@ -784,6 +802,15 @@ public class GreekStemmer {
     return true;
   }
   
+ /**
+   * Checks if the word contained in the leading portion of char[] array , 
+   * ends with a Greek vowel.
+   * 
+   * @param s A char[] array that represents a word.
+   * @param len The length of the char[] array.
+   * @return True if the word contained in the leading portion of char[] array , 
+   * ends with a vowel , false otherwise.
+   */
   private boolean endsWithVowel(char s[], int len) {
     if (len == 0)
       return false;
@@ -801,6 +828,15 @@ public class GreekStemmer {
     }
   }
   
+ /**
+   * Checks if the word contained in the leading portion of char[] array , 
+   * ends with a Greek vowel.
+   * 
+   * @param s A char[] array that represents a word.
+   * @param len The length of the char[] array.
+   * @return True if the word contained in the leading portion of char[] array , 
+   * ends with a vowel , false otherwise.
+   */
   private boolean endsWithVowelNoY(char s[], int len) {
     if (len == 0)
       return false;