src/main/java/pt/it/av/tnav/ml/clustering/cluster/ClusterUtils.java
public static <D extends Distance<D>> boolean singleElementClusters(List<Cluster<D>> clusters) {
    boolean rv = true;
    for(Cluster<D> cluster : clusters) {
      if(cluster != null && cluster.size() > 1) {
        rv = false;
        break;
      }
    }
    return rv;
  }
/**
   * Returns true if all the clusters only have a single element, otherwise false.
   *
   * @param clusters the list of clusters.
   * @param <D> Any Class that implements {@link Distance} interface.
   * @return true if all the clusters only have a single element, otherwise false
   */
Returns true if all the clusters only have a single element, otherwise false.
@param clusters the list of clusters.
@param  Any Class that implements  Distance interface.
@return true if all the clusters only have a single element, otherwise false
Returns true if all the clusters only have a single element otherwise false . @param clusters the list of clusters . @param Any Class that implements Distance interface . @return true if all the clusters only have a single element otherwise false
public static <D extends Distance<D>> boolean singleElementClusters(List<Cluster<D>> clusters) {
    boolean rv = true;
    for(Cluster<D> cluster : clusters) {
      if(cluster != null && cluster.size() > 1) {
        rv = false;
        break;
      }
    }
    return rv;
  }
public static < D extends Distance < D > > boolean singleElementClusters ( List < Cluster < D > > clusters ) { boolean rv = true ; for ( Cluster < D > cluster : clusters ) { if ( cluster != null && cluster . size ( ) > 1 ) { rv = false ; break ; } } return rv ; }
Returns true if all the clusters only have a single element, otherwise false.
Returns true if all the clusters only have a single element otherwise false .