T
- the type of points that can be clusteredpublic class Cluster<T extends Clusterable<T>>
extends java.lang.Object
implements java.io.Serializable
Clusterable
points.Constructor and Description |
---|
Cluster(T center)
Build a cluster centered at a specified point.
|
Modifier and Type | Method and Description |
---|---|
void |
addPoint(T point)
Add a point to this cluster.
|
T |
getCenter()
Get the point chosen to be the center of this cluster.
|
java.util.List<T> |
getPoints()
Get the points contained in the cluster.
|
public Cluster(T center)
center
- the point which is to be the center of this clusterpublic void addPoint(T point)
point
- point to addpublic java.util.List<T> getPoints()
public T getCenter()
"Copyright © 2010 - 2020 Adobe Systems Incorporated. All Rights Reserved"