/************************************ * Umass Amherst * CS377 Operating System * Lab2: * Author: Andrew Fagg * Date: 9/22/2002 * * Class in this file: Goal * Compile: javac Goal.java * Run: n/a * Description: DataStructure for Goals. Must * be initialized and maintained by parent class: * * - Once the goal has been eaten, isEaten must be set to true. * ***********************************/ import java.util.*; import java.lang.*; class Goal { private int X; //the goal's X Position private int Y; //the goal's Y Position char cColor; //the goal's color boolean isEaten; //true if the goal has been eaten and is // no longer edible by a robot final int GetPosX() { return(X); }; final int GetPosY() { return(Y); }; final void SetPosX(int newx) { X = newx; }; final void SetPosY(int newy) { Y = newy; }; }