|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.kit.furia.Document<O>
O - The type of OB object that will be stored in this document.public class Document<O extends org.ajmm.obsearch.OB>
This class is a multi-set of OB objects. If we were to store natural language, a document is just a multi-set of natural language words. Relationships of the words within the document are not stored.
| Nested Class Summary | |
|---|---|
class |
Document.DocumentElement<T>
This class is used by the iterator of the Document class. |
| Constructor Summary | |
|---|---|
Document(java.lang.String id)
Creates a document with an initial estimate of 2000 elements. |
|
Document(java.lang.String id,
int initialCapacity)
Creates a document. |
|
| Method Summary | |
|---|---|
void |
addWord(O word)
Adds a word to the document. |
java.lang.String |
getName()
|
java.util.Iterator<Document.DocumentElement<O>> |
iterator()
|
int |
multiSetSize()
|
void |
setWord(O word,
int multiplicity)
Sets the multiplicity for the given word. |
int |
size()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Document(java.lang.String id)
id - The id of the document.
public Document(java.lang.String id,
int initialCapacity)
initialCapacity - The number of elements that we are expecting to hold. This
is for efficiency reasons, as the Document will grow
automatically if the number of elements exceeds this
initial estimate.id - The id of the document.| Method Detail |
|---|
public java.lang.String getName()
public int size()
public int multiSetSize()
public void addWord(O word)
word - The word that will be added.
public void setWord(O word,
int multiplicity)
word - multiplicity - public java.util.Iterator<Document.DocumentElement<O>> iterator()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||