Code cleanup.
[TP_POO.git] / TP2 / Point.java
index e949acc413fbe8f4947a04bd1fc3fdc3dc75df9b..89382d521e57f9bc6479bc0006a69d9c10eaf961 100644 (file)
@@ -1,9 +1,16 @@
 
+@ClassPreamble (
+    author = "Jérôme Benoit",
+    date = "11/02/2012"
+)
 class Point {
     private double x;
     private double y;
 
     Point() {
+        /*
+         * FIXME?: init to (0,0)
+         */
     }
 
     Point (double x, double y) {
@@ -27,8 +34,9 @@ class Point {
         return y;
     }
 
-    public Point additionner(Point p1) {
-        return new Point(p1.getX() + getX(), p1.getY() + getX());
+    public Point additionner(Point p) {
+        Point pNew = new Point(p.getX() + getX(), p.getY() + getY());
+        return pNew;
     }
 
     public String toString() {