nz.ac.waikato.mcennis.rat.graph.page
Interface Page

All Superinterfaces:
java.lang.Comparable, java.io.Serializable
All Known Implementing Classes:
BasicCartesianPage

public interface Page
extends java.io.Serializable, java.lang.Comparable

Class for describing a text document. Pending application of generic properties on graphs and actors, this represents text-based documents.


Method Summary
 double compare(Page p)
          Compute a similarity between 2 pages.
 java.util.HashMap<java.lang.String,java.lang.Double> getHistogram()
          Retrieve the histogram describing this document.
 java.lang.String getID()
          get the unique id identifying this page
 void load(java.util.HashMap<java.lang.String,java.lang.Double> histogram)
          Create a page given the bag-of-words description.
 void load(java.lang.String content)
          Create a page document fromthe given string.
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Method Detail

compare

double compare(Page p)
Compute a similarity between 2 pages.

Parameters:
p - page to compare to
Returns:
similarity

load

void load(java.lang.String content)
Create a page document fromthe given string.

Parameters:
content - contents of the text document

load

void load(java.util.HashMap<java.lang.String,java.lang.Double> histogram)
Create a page given the bag-of-words description.

Parameters:
histogram - bag-of-words description of a text document

getHistogram

java.util.HashMap<java.lang.String,java.lang.Double> getHistogram()
Retrieve the histogram describing this document.

Returns:

getID

java.lang.String getID()
get the unique id identifying this page

Returns:
unique id