]>
git.zerfleddert.de Git - FreeShisen/blob - src/de/cwde/freeshisen/Point.java
1 package de
.cwde
.freeshisen
;
4 public Point(int i
, int j
) {
9 public Point(Point p
) {
14 public boolean equals(Point p
) {
15 return (i
== p
.i
&& j
== p
.j
);
18 public boolean equals(int myi
, int myj
) {
19 return (i
== myi
&& j
== myj
);
22 public String
toString() {
23 return "(" + i
+ "," + j
+ ")";
26 public void set(int i
, int j
) {
31 public static Point
fromString(String s
) {
32 String
[] ij
= s
.split(",", 2);
33 int i
= Integer
.parseInt(ij
[0]);
34 int j
= Integer
.parseInt(ij
[1]);
35 return new Point(i
, j
);
42 return new Point(this.i
, this.j
);