Class PointCloud


  • @Equality
    public class PointCloud
    extends java.lang.Object
    Represents an unordered set of data positions forming part of a plot. An iterator over the points is provided. Instances of this class may also be compared for equality: if instances compare equal, the iterators will dispense the same positions, though not necessarily in the same order.

    The unordered semantics of this class is imposed by the equality requirement. Most of the ordering could be restored by rewording the contract a bit differently if that becomes useful, but at time of writing it's not needed.

    Since:
    13 Feb 2013
    Author:
    Mark Taylor
    • Constructor Summary

      Constructors 
      Constructor Description
      PointCloud​(SubCloud subCloud)
      Constructs a point cloud from a single subcloud.
      PointCloud​(SubCloud[] subClouds)
      Constructs a point cloud from an array of subclouds.
    • Constructor Detail

      • PointCloud

        public PointCloud​(SubCloud[] subClouds)
        Constructs a point cloud from an array of subclouds. The order of the items in the array may determine the sequence of point iteration, but does not affect equality with respect to other instances.
        Parameters:
        subClouds - array of cloud components
      • PointCloud

        public PointCloud​(SubCloud subCloud)
        Constructs a point cloud from a single subcloud.
        Parameters:
        subCloud - cloud component
    • Method Detail

      • createDataPosIterable

        public java.lang.Iterable<double[]> createDataPosIterable​(DataStore dataStore)
        Returns an iterable over data positions. Iteration is over dataDimCount-element arrays giving position in data space. The same double[] array object is returned each time with different contents, so beware of storing it between iterations.
        Parameters:
        dataStore - data storage object
        Returns:
        iterable over data positions
      • getSubClouds

        public SubCloud[] getSubClouds()
        Returns an array of the subclouds in this point cloud.
        Returns:
        subcloud array
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object