Class Cluster<T>


  • public class Cluster<T>
    extends Object
    A cluster is a named group of somehow related entities.
    • Constructor Detail

      • Cluster

        public Cluster()
    • Method Detail

      • getLabels

        public List<String> getLabels()
        Returns:
        Returns a list of labels describing this cluster.
      • addLabel

        public Cluster<T> addLabel​(String label)
        Add a single label to this cluster.
      • getDocuments

        public List<T> getDocuments()
        Returns all documents that belong directly to this cluster.
      • addDocument

        public Cluster<T> addDocument​(T document)
        Add a single document to this cluster.
      • getClusters

        public List<Cluster<T>> getClusters()
        Returns all child clusters belonging to this cluster.
      • addCluster

        public Cluster<T> addCluster​(Cluster<T> cluster)
        Adds a child cluster to this cluster.
      • getScore

        public Double getScore()
        Returns this cluster's score or null, if not available.
      • setScore

        public Cluster<T> setScore​(Double score)
        Sets this cluster's score.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object