Class AbstractJavaPointCloud<T extends AbstractJavaPoint<T>>

  • Type Parameters:
    T - The type of the point
    Direct Known Subclasses:
    JavaPointCloud2D, JavaPointCloud3D

    public abstract class AbstractJavaPointCloud<T extends AbstractJavaPoint<T>>
    extends Object

    Wrapping class for an unordered amount of points

    Since:
    1.0
    Author:
    Christoph Praschl
    • Constructor Detail

      • AbstractJavaPointCloud

        public AbstractJavaPointCloud()
    • Method Detail

      • calculateCenterPoint

        protected abstract T calculateCenterPoint()
      • transformParallel

        protected <L extends AbstractJavaPointCloud<T>> L transformParallel​(UnaryOperator<T> function)
        Help method for applying a unary operator to all points of the point cloud
        Type Parameters:
        L - the type of the line
        Parameters:
        function - unary operator which is applied to every point in the point cloud
        Returns:
        a new instance holding the transformed point cloud
      • sub

        public abstract AbstractJavaPointCloud<T> sub​(T vector)
        Subtracts the given JavaPoint from the point cloud.
        Parameters:
        vector - The JavaPoint to be subtracted from the point cloud
        Returns:
        A new instance holding the result of the subtraction
      • add

        public abstract AbstractJavaPointCloud<T> add​(T vector)
        Adds the given JavaPoint to the point cloud.
        Parameters:
        vector - The JavaPoint to be added to the point cloud
        Returns:
        A new instance holding the result of the addition
      • mult

        public abstract AbstractJavaPointCloud<T> mult​(T vector)
        Multiplies the point cloud with the given scalar.
        Parameters:
        vector - The multiplied vector
        Returns:
        A new instance holding the result of the multiplication
      • div

        public abstract AbstractJavaPointCloud<T> div​(double scalar)
        Divides the point cloud by the given scalar.
        Parameters:
        scalar - The scalar used for the division of the point cloud
        Returns:
        A new instance holding the result of the division
      • scale

        public abstract AbstractJavaPointCloud<T> scale​(T scaleFactors)
        Scales the given JavaPointCloud around the center point
        Parameters:
        scaleFactors - vector containing the scale values
        Returns:
        new scaled instance
      • scale

        public abstract AbstractJavaPointCloud<T> scale​(T scaleFactors,
                                                        T scaleCenter)
        Scales the given JavaPointCloud around the given scale center point
        Parameters:
        scaleFactors - vector containing the scale values
        scaleCenter - the scaleCenter
        Returns:
        new scaled instance
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object