|
Terrier IR Platform 1.1.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectuk.ac.gla.terrier.structures.trees.TreeNode
public class TreeNode
This class represents a node in the binary tree representing either the lexicon, or a document. In the case we are refering to a tree node in the lexicon, then frequency is the document frequency of the term (number of documents that contain the term), while if we refer to the binary tree that represents a document, then frequency refers to the number of occurrences of the term in the document.
Field Summary | |
---|---|
int |
frequency
Deprecated. The frequency of the term. |
TreeNode |
left
Deprecated. The left child of the node. |
TreeNode |
right
Deprecated. The right child of the node. |
java.lang.String |
term
Deprecated. The term. |
int |
termCode
Deprecated. The term's code. |
Constructor Summary | |
---|---|
TreeNode(java.lang.String newTerm)
Deprecated. A constructor for a new node. |
|
TreeNode(java.lang.String newTerm,
int givenTermCode)
Deprecated. Constructor for when the the termcode is already known by the calling code |
Method Summary | |
---|---|
int |
compareTo(TreeNode TN1)
Deprecated. Compares the term code of a given tree node with the term code of itself. |
boolean |
equals(java.lang.Object o)
Deprecated. Compares the term code of the given tree node with the term code of this node. |
Methods inherited from class java.lang.Object |
---|
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public TreeNode left
public TreeNode right
public int frequency
public java.lang.String term
public int termCode
Constructor Detail |
---|
public TreeNode(java.lang.String newTerm)
newTerm
- The term that this node is representing.public TreeNode(java.lang.String newTerm, int givenTermCode)
newTerm
- the String term for this term.givenTermCode
- the term code for this string if already known.Method Detail |
---|
public int compareTo(TreeNode TN1)
compareTo
in interface java.lang.Comparable<TreeNode>
TN1
- Object the tree node to compare to.
java.lang.ClassCastException
- if the given argument is
not an instance of the class TreeNode.public boolean equals(java.lang.Object o) throws java.lang.ClassCastException
equals
in class java.lang.Object
o
- Object the tree node to compare to.
java.lang.ClassCastException
- if the object o is not
an instance of the class TreeNode.
|
Terrier IR Platform 1.1.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |