point.java
来自「一款修改过的手机贪食蛇游戏」· Java 代码 · 共 53 行
JAVA
53 行
/* * Point.java * * Created on June 19, 2007, 3:04 AM * * To change this template, choose Tools | Template Manager * and open the template in the editor. */package hello;/** * * @author jiabei */public class Point { private int x; private int y; /** Creates a new instance of Point */ public Point(int x, int y) { this.x = x; this.y = y; } public Point(Point p) { this.x = p.getX(); this.y = p.getY(); } public int getX() { return x; } public int getY() { return y; } public void setX(int x) { this.x = x; } public void setY(int y) { this.y = y; } public boolean isSame(Point t) { return ((t.getX() == x) && (t.getY() == y)); } }
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?