/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package pointtest; /** * * @author jcmtiernan */ public class PlainRobot { private Point robotLocation = new Point(0,10); // initial robot location private int robotIDNumber; public PlainRobot(int robotIDNumber) { this.robotIDNumber = robotIDNumber; } public PlainRobot() { } public PlainRobot(int robotIDNumber, Point loc) { this.robotIDNumber = robotIDNumber; this.robotLocation = loc; } public Point getRobotLocation() { return robotLocation; } public void setRobotLocation(Point robotLocation) { this.robotLocation = robotLocation; } public int getRobotIDNumber() { return robotIDNumber; } public void setRobotIDNumber(int robotIDNumber) { this.robotIDNumber = robotIDNumber; } @Override public String toString() { return String.format("Robot ID: "+robotIDNumber+"\nLocation: "+robotLocation); } }