adding a test case
[IRC.git] / Robust / src / Benchmarks / SSJava / EyeTracking / EyePosition.java
1 /*
2  * Copyright 2009 (c) Florian Frankenberger (darkblue.de)
3  * 
4  * This file is part of LEA.
5  * 
6  * LEA is free software: you can redistribute it and/or modify it under the
7  * terms of the GNU Lesser General Public License as published by the Free
8  * Software Foundation, either version 3 of the License, or (at your option) any
9  * later version.
10  * 
11  * LEA is distributed in the hope that it will be useful, but WITHOUT ANY
12  * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
13  * A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
14  * details.
15  * 
16  * You should have received a copy of the GNU Lesser General Public License
17  * along with LEA. If not, see <http://www.gnu.org/licenses/>.
18  */
19
20 /**
21  * No description given.
22  * 
23  * @author Florian Frankenberger
24  */
25 @LATTICE("POS")
26 @METHODDEFAULT("OUT<THIS,THISLOC=THIS,RETURNLOC=OUT")
27 public class EyePosition {
28   @LOC("POS")
29   private int x;
30   @LOC("POS")
31   private int y;
32
33   public EyePosition(int x, int y) {
34     this.x = x;
35     this.y = y;
36   }
37
38   public int getX() {
39     return this.x;
40   }
41
42   public int getY() {
43     return this.y;
44   }
45
46   public String toString() {
47     return "(" + x + "," + y + ")";
48   }
49
50   private static int sgn(int i) {
51     if (i > 0)
52       return 1;
53     if (i < 0)
54       return -1;
55     return 0;
56   }
57 }