Moved the method for cheking position validity <previously in grid class> into the position class