Updated readability of the code.
[sixth-3d.git] / src / main / java / eu / svjatoslav / sixth / e3d / geometry / Point3D.java
index 8d72345..6bf2dd3 100755 (executable)
@@ -58,6 +58,20 @@ public class Point3D implements Cloneable {
         return this;
     }
 
+    /**
+     * Add coordinates of current point to other point. Value of current point will not be changed.
+     * @return current point.
+     */
+    public Point3D addTo(final Point3D ... otherPoints) {
+        for (final Point3D otherPoint : otherPoints) otherPoint.add(this);
+        return this;
+    }
+
+    /**
+     * Create new point by cloning position of current point.
+     *
+     * @return newly created clone.
+     */
     public Point3D clone() {
         return new Point3D(this);
     }