ranking
Class RankingResult

java.lang.Object
  extended by ranking.RankingResult
All Implemented Interfaces:
java.lang.Comparable

public class RankingResult
extends java.lang.Object
implements java.lang.Comparable

Stores a search result as a Page and that Page's final score


Constructor Summary
RankingResult(Page page, int score)
           
 
Method Summary
 int compareTo(java.lang.Object o)
          Compares this RankingResult to another object.
 Page getPage()
           
 int getScore()
           
 void setPage(Page page)
           
 void setScore(int score)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RankingResult

public RankingResult(Page page,
                     int score)
Method Detail

getPage

public Page getPage()

setPage

public void setPage(Page page)

getScore

public int getScore()

setScore

public void setScore(int score)

compareTo

public int compareTo(java.lang.Object o)
Compares this RankingResult to another object.

Specified by:
compareTo in interface java.lang.Comparable
Parameters:
o - Object to compare
Returns:
Difference in RankingResult scores. Negative if other RankingResult has a smaller score than this RankingResult, Positive if reversed, Zero if equal

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object
Returns:
The String value of this RankingResult