if (nameOfPlanet.equals(Planet.EARTH)) {thePlanet = Earth.getInstance();}
На создание остальных объектов не ругается.