I have a class Cell:
public class Cell { public enum cellState { WATER, SCAN, SHIPUNIT, SHOT, HIT }
You are getting the exception because you are not assigning an instance of Cell to any of the slots of your matrices.