public void ParsePosition(string initialPositionInput) { string[] initialPositionCommandParts = initialPositionInput.Split(' '); _robotPosition = new RobotPosition { X = Int32.Parse(initialPositionCommandParts[0]), Y = Int32.Parse(initialPositionCommandParts[1]) }; _heading = Convert.ToChar(initialPositionCommandParts[2]); }
public bool Equals(RobotPosition other) { return X == other.X && Y == other.Y; }
public Robot(RobotRotator robotRotator, RobotMover robotMover) { _robotRotator = robotRotator; _robotPosition = new RobotPosition(); _robotMover = robotMover; }