net.sf.zekr.engine.search.lucene
Class LuceneAnalyzerFactory

java.lang.Object
  extended by net.sf.zekr.engine.search.lucene.LuceneAnalyzerFactory

public class LuceneAnalyzerFactory
extends java.lang.Object

Author:
Mohsen Saboorian

Constructor Summary
LuceneAnalyzerFactory()
           
 
Method Summary
static org.apache.lucene.analysis.Analyzer getAnalyzer(IQuranText quranText)
          This method decides to return based on the type of quranText parameter, whether a language-specific translation analyzer or a Quran analyzer.
static org.apache.lucene.analysis.Analyzer getAnalyzer(java.lang.String langCode)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LuceneAnalyzerFactory

public LuceneAnalyzerFactory()
Method Detail

getAnalyzer

public static org.apache.lucene.analysis.Analyzer getAnalyzer(java.lang.String langCode)
Parameters:
langCode - can be either two-char language ISO code, ZekrLuceneAnalyzer.QURAN_LANG_CODE, or either of the available snowball analyzers such as Lovins, Porter or Kp.
Returns:
a new instance of ZekrLuceneAnalyzer

getAnalyzer

public static org.apache.lucene.analysis.Analyzer getAnalyzer(IQuranText quranText)
This method decides to return based on the type of quranText parameter, whether a language-specific translation analyzer or a Quran analyzer.

Parameters:
quranText - the abstract Quran text
Returns: