Class query.WeightedRanking
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class query.WeightedRanking

java.lang.Object
   |
   +----query.ExpNode
           |
           +----query.WeightedRanking

public class WeightedRanking
extends ExpNode
implements STARTSnode, RankingNode
An ExpNode that represents a weighted ranking operator in a STARTS ranking expressin. Weighted Ranking nodes have one child and one property: ranking value - a float value that is the weight.

Constructor Index

 o WeightedRanking(Query, float)
Construct a new WeightedRanking node

Method Index

 o Check()
Return a new sub-tree that is the result of checking (for both semantic sanity and source support) the sub-tree that descends from this WeightedRanking node.
 o ExtractTerms(Vector)
Recurse from this sub-tree to extract the terms in the sub-tree
 o GetRankingValue()
Return the ranking value of this node
 o TranslateToRanking()
Return the sub-tree that represents the source-specific translation of this weighted ranking sub-tree
 o Unparse()
Return the string representation of the sub-tree descending from the WeightedRanking node

Constructors

 o WeightedRanking
  public WeightedRanking(Query query,
                         float rankingValue)
Construct a new WeightedRanking node
Parameters:
query - The query context of this node
rankingValue - The weight of the node

Methods

 o GetRankingValue
  public float GetRankingValue()
Return the ranking value of this node
Returns:
the ranking value of this node.
 o Unparse
  public String Unparse()
Return the string representation of the sub-tree descending from the WeightedRanking node
Returns:
String the string equivalent of this WeightedRanking subtree.
Overrides:
Unparse in class ExpNode
 o Check
  public ExpNode Check() throws UnsupportedQueryException
Return a new sub-tree that is the result of checking (for both semantic sanity and source support) the sub-tree that descends from this WeightedRanking node.
Returns:
the transformed Weighted Ranking sub-tree as a result of the check process.
Throws: UnsupporteQueryException
if an error is found in the subtree during the checking process.
 o TranslateToRanking
  public ExpNode TranslateToRanking() throws SourceQueryException
Return the sub-tree that represents the source-specific translation of this weighted ranking sub-tree
Returns:
the source equivalent ranking sub-tree of this Weighted ranking sub-tree
Throws: SourceQueryException
if an error occurs in the translation process.
 o ExtractTerms
  public void ExtractTerms(Vector termVector)
Recurse from this sub-tree to extract the terms in the sub-tree
Parameters:
rankingTerms - The vector of terms.

All Packages  Class Hierarchy  This Package  Previous  Next  Index