KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > contineo > core > text > analyze > Analyzer


1 /*
2  * Analyzer.java
3  *
4  * Created on 23. Juli 2003, 19:12
5  */

6
7 package org.contineo.core.text.analyze;
8
9 import java.util.Collection JavaDoc;
10 /**
11  *
12  * @author Michael Scholz
13  */

14 public interface Analyzer {
15     
16     /**
17      * This method analyzes a given text and fills a hitlist.
18      * @param text - Text which should analyzed.
19      */

20     public void analyze(String JavaDoc text);
21     
22     /**
23      * Returns the top words of an analyzed document.
24      * @param hits - Number of top words to be returned.
25      * @return
26      */

27     public Collection JavaDoc getTopWords(int hits);
28     
29     /**
30      * @return Number of entries in the hitlist containing the topwords.
31      */

32     public int relevantWords();
33     
34     /**
35      * @return Number of words in the analyzed document.
36      */

37     public long getWordCount();
38 }
39
Popular Tags