com.raritantechnologies.concept.clustering.temis
Class TemisClusterer

java.lang.Object
  extended bycom.raritantechnologies.concept.clustering.temis.TemisClusterer
All Implemented Interfaces:
IClusterer, IConfigurable

public class TemisClusterer
extends java.lang.Object
implements IClusterer

IClusterer implementation that uses the Temis ClusteringServer.

XML Configuration Template:
   <Clusterer class="com.raritantechnologies.concept.clustering.temis.TemisClusterer"
                 temisServerURL="[ URL of Temis Clustering Server ]"
                 clusterFields="[ comma separated list of field names to use for clustering ]" />
 


Constructor Summary
TemisClusterer()
           
 
Method Summary
 void dataComplete()
          called by cluster input source when all results to be clustered have been added to the clustering engine.
 QueryResultBean getCluster(java.lang.String clusterName)
          returns the set of clustered result set keys.
 IResultSet getCluster(java.lang.String clusterName, int pageSize, int startRec)
          returns a set of clustered results for a given key.
 java.util.Set getClusterNames()
          returns the names of the clusters created.
 QueryResultBeanSet getClusterSet()
          returns the set of clusters as a QueryResultBeanSet.
 int getClusterSize(java.lang.String clusterName)
          returns the number of results for a given key.
 java.util.List getMatchingClusters(IResult result)
          Returns the list of clusters that match this IResult.
 QueryResultBeanSet getSubCluster(java.lang.String clusterName)
           
 java.util.Iterator getSubClusterNames()
          if clusterer supports hierarchical clustering.
 void initialize(org.w3c.dom.Element elem)
          Initializes the object from an XML tag or element.
 void processResultSet(IResultSet resultSet)
          called by cluster input to add results to the clustering engine.
 void setClusterField(java.lang.String clusterField)
           
 void setClusterFields(java.lang.String[] clusterFields)
           
 void setLabelField(java.lang.String labelField)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TemisClusterer

public TemisClusterer()
Method Detail

setClusterFields

public void setClusterFields(java.lang.String[] clusterFields)

setClusterField

public void setClusterField(java.lang.String clusterField)

setLabelField

public void setLabelField(java.lang.String labelField)

processResultSet

public void processResultSet(IResultSet resultSet)
Description copied from interface: IClusterer
called by cluster input to add results to the clustering engine.

Specified by:
processResultSet in interface IClusterer

dataComplete

public void dataComplete()
called by cluster input source when all results to be clustered have been added to the clustering engine.

Specified by:
dataComplete in interface IClusterer

getClusterNames

public java.util.Set getClusterNames()
returns the names of the clusters created.

Specified by:
getClusterNames in interface IClusterer

getClusterSize

public int getClusterSize(java.lang.String clusterName)
returns the number of results for a given key.

Specified by:
getClusterSize in interface IClusterer

getClusterSet

public QueryResultBeanSet getClusterSet()
returns the set of clusters as a QueryResultBeanSet.

Specified by:
getClusterSet in interface IClusterer

getCluster

public QueryResultBean getCluster(java.lang.String clusterName)
returns the set of clustered result set keys.

Specified by:
getCluster in interface IClusterer

getCluster

public IResultSet getCluster(java.lang.String clusterName,
                             int pageSize,
                             int startRec)
returns a set of clustered results for a given key.

Specified by:
getCluster in interface IClusterer

getSubClusterNames

public java.util.Iterator getSubClusterNames()
Description copied from interface: IClusterer
if clusterer supports hierarchical clustering. Returns names of child cluster sets.

Specified by:
getSubClusterNames in interface IClusterer

getSubCluster

public QueryResultBeanSet getSubCluster(java.lang.String clusterName)
Specified by:
getSubCluster in interface IClusterer

getMatchingClusters

public java.util.List getMatchingClusters(IResult result)
Returns the list of clusters that match this IResult.

Specified by:
getMatchingClusters in interface IClusterer

initialize

public void initialize(org.w3c.dom.Element elem)
Description copied from interface: IConfigurable
Initializes the object from an XML tag or element. This method is called by the Framework as part of the application initializtion. see ConfigurationManager, XMLConfigurationManager, XMLSearchFieldMapFactory, XMLSearchSourceFactory. Configurable objects that are owned or contained by other configurable objects will be initialized in by the parent object.

Specified by:
initialize in interface IConfigurable