java.lang.Object
org.apache.lucene.analysis.el.GreekStemmer

class GreekStemmer extends Object
A stemmer for Greek words, according to: Development of a Stemmer for the Greek Language. Georgios Ntais

NOTE: Input is expected to be casefolded for Greek (including folding of final sigma to sigma), and with diacritics removed. This can be achieved with either GreekLowerCaseFilter or ICUFoldingFilter.

  • Field Details

  • Constructor Details

    • GreekStemmer

      GreekStemmer()
  • Method Details

    • stem

      int stem(char[] s, int len)
      Stems a word contained in a leading portion of a char[] array. The word is passed through a number of rules that modify its length.
      Parameters:
      s - A char[] array that contains the word to be stemmed.
      len - The length of the char[] array.
      Returns:
      The new length of the stemmed word.
    • rule0

      private int rule0(char[] s, int len)
    • rule1

      private int rule1(char[] s, int len)
    • rule2

      private int rule2(char[] s, int len)
    • rule3

      private int rule3(char[] s, int len)
    • rule4

      private int rule4(char[] s, int len)
    • rule5

      private int rule5(char[] s, int len)
    • rule6

      private int rule6(char[] s, int len)
    • rule7

      private int rule7(char[] s, int len)
    • rule8

      private int rule8(char[] s, int len)
    • rule9

      private int rule9(char[] s, int len)
    • rule10

      private int rule10(char[] s, int len)
    • rule11

      private int rule11(char[] s, int len)
    • rule12

      private int rule12(char[] s, int len)
    • rule13

      private int rule13(char[] s, int len)
    • rule14

      private int rule14(char[] s, int len)
    • rule15

      private int rule15(char[] s, int len)
    • rule16

      private int rule16(char[] s, int len)
    • rule17

      private int rule17(char[] s, int len)
    • rule18

      private int rule18(char[] s, int len)
    • rule19

      private int rule19(char[] s, int len)
    • rule20

      private int rule20(char[] s, int len)
    • rule21

      private int rule21(char[] s, int len)
    • rule22

      private int rule22(char[] s, int len)
    • endsWith

      private boolean endsWith(char[] s, int len, String suffix)
      Checks if the word contained in the leading portion of char[] array , ends with the suffix given as parameter.
      Parameters:
      s - A char[] array that represents a word.
      len - The length of the char[] array.
      suffix - A String object to check if the word given ends with these characters.
      Returns:
      True if the word ends with the suffix given , false otherwise.
    • endsWithVowel

      private boolean endsWithVowel(char[] s, int len)
      Checks if the word contained in the leading portion of char[] array , ends with a Greek vowel.
      Parameters:
      s - A char[] array that represents a word.
      len - The length of the char[] array.
      Returns:
      True if the word contained in the leading portion of char[] array , ends with a vowel , false otherwise.
    • endsWithVowelNoY

      private boolean endsWithVowelNoY(char[] s, int len)
      Checks if the word contained in the leading portion of char[] array , ends with a Greek vowel.
      Parameters:
      s - A char[] array that represents a word.
      len - The length of the char[] array.
      Returns:
      True if the word contained in the leading portion of char[] array , ends with a vowel , false otherwise.