diff options
author | Jannis Harder <harder@informatik.uni-luebeck.de> | 2011-05-02 04:46:00 +0200 |
---|---|---|
committer | Jannis Harder <harder@informatik.uni-luebeck.de> | 2011-05-02 04:46:00 +0200 |
commit | 1e7cdb33f5bfce2d3fb174abd778788108557078 (patch) | |
tree | 7ef56ce60b813402eabff2bc1aee77ba6142cbd8 /src/jrummikub/model/Position.java | |
parent | 91b921248f4a74bddd8434bcad65c45fd8486549 (diff) | |
download | JRummikub-1e7cdb33f5bfce2d3fb174abd778788108557078.tar JRummikub-1e7cdb33f5bfce2d3fb174abd778788108557078.zip |
More javadocs for the model
git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@64 72836036-5685-4462-b002-a69064685172
Diffstat (limited to 'src/jrummikub/model/Position.java')
-rw-r--r-- | src/jrummikub/model/Position.java | 30 |
1 files changed, 24 insertions, 6 deletions
diff --git a/src/jrummikub/model/Position.java b/src/jrummikub/model/Position.java index f7e53e6..35cf45e 100644 --- a/src/jrummikub/model/Position.java +++ b/src/jrummikub/model/Position.java @@ -9,22 +9,40 @@ public class Position { private float x; private float y; + /** + * Create a new position by specifying the coordinates + * + * @param x + * x coordinate + * @param y + * y coordinate + */ public Position(float x, float y) { - this.x = x; + this.x = x; this.y = y; } + /** + * Get the x coordinate of the position + * + * @return x coordinate + */ public float getX() { - return x; - } + return x; + } + /** + * Get the y coordinate of the position + * + * @return y coordinate + */ public float getY() { return y; } - + @Override - public String toString(){ - return "Position[x="+x+",y="+y+"]"; + public String toString() { + return "Position[x=" + x + ",y=" + y + "]"; } } |