package test;public class EnumTest {/**枚举* */public static void main(String[] args) {// TODO Auto-generated method stubStudent stu = new Student();stu.setName("李华");stu.setSex(Genders.MALE);stu.setAge(24);System.out.println(stu.getSex());}}
package test;public enum Genders {MALE,FAMALE }