|
Jive Forums API (5.5.20.2-oracle) Core Javadocs | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jivesoftware.forum.QueryResult
public class QueryResult
Encapsulates a search result resulting from a search using the Query class. Relevance is only stored to 3 significant decimal places (xx.x%)
Constructor Summary | |
---|---|
QueryResult(ForumMessage message,
float relevance)
Creates a new QueryResult object. |
|
QueryResult(long messageID,
long threadID,
long forumID,
java.lang.String subject,
java.util.Date creationDate,
java.util.Date modificationDate,
float relevance)
Creates a new QueryResult object. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj)
|
int |
getCachedSize()
|
java.util.Date |
getCreationDate()
Get the creation date of the message this query result pertains to. |
long |
getForumID()
Get the ID of the forum the message belongs to |
ForumMessage |
getMessage()
Get the message this query result pertains to. |
long |
getMessageID()
Get the id of the message this query result pertains to. |
java.util.Date |
getModificationDate()
Returns the message modification date. |
float |
getRelevance()
Get the relevance of this query result as determined by the search engine. |
java.lang.String |
getRelevanceAsPercentage(java.util.Locale locale)
Returns the relevance as a percentage (no decimal places) formatted according to the locale passed in. |
java.lang.String |
getSubject()
Returns the message's subject. |
long |
getThreadID()
Get the ID of the thread the message belongs to |
int |
hashCode()
|
void |
readExternal(java.io.DataInput in)
|
void |
setMessage(ForumMessage message)
Set the entry this query result pertains to. |
protected void |
setRelevance(float relevance)
Get the relevance of this query result as determined by the search engine. |
void |
writeExternal(java.io.DataOutput out)
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public QueryResult(ForumMessage message, float relevance)
message
- the ForumMessage corresponding to the query resultrelevance
- the relevance of the search result as determined by the search engine.public QueryResult(long messageID, long threadID, long forumID, java.lang.String subject, java.util.Date creationDate, java.util.Date modificationDate, float relevance)
messageID
- the messageID of the ForumMessage corresponding to the query resultrelevance
- the relevance of the search result as determined by the search engine.threadID
- the ID of the message's parent threadforumID
- the ID of the message's parent forummodificationDate
- the date the message was last modifiedsubject
- the subject of the messageMethod Detail |
---|
public long getMessageID()
public long getThreadID()
public long getForumID()
public java.util.Date getCreationDate()
public java.util.Date getModificationDate()
public java.lang.String getSubject()
public ForumMessage getMessage() throws ForumMessageNotFoundException
ForumMessageNotFoundException
public float getRelevance()
public void setMessage(ForumMessage message)
message
- the ForumMessage this query result pertains to.protected void setRelevance(float relevance)
relevance
- the relevance of this query result as determined by the search engine.public java.lang.String getRelevanceAsPercentage(java.util.Locale locale)
locale
- the locale to use to format the percentage.
public int getCachedSize()
getCachedSize
in interface com.jivesoftware.util.Cacheable
public void readExternal(java.io.DataInput in) throws java.io.IOException
readExternal
in interface com.tangosol.io.ExternalizableLite
java.io.IOException
public void writeExternal(java.io.DataOutput out) throws java.io.IOException
writeExternal
in interface com.tangosol.io.ExternalizableLite
java.io.IOException
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
|
Jive Forums Project Page | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |