Generate.java updated