今天学习hibernate . 创建User类: package com.hibernate; import java.util.Date; public class User { private Integer id; private String name; private Date birth; public User(){} public User(Integer id, String name, Date birth) { super(); this.id = id; this.nam
第一步:定义顶级枚举接口 public interface BaseEnum<E extends Enum<?>, T> { public T getCode(); public String getValue(); } 第二步:实现枚举接口 public enum AccountTypeEnum implements BaseEnum<AccountTypeEnum,Integer>{ PERSONAL(1,"PERSONAL"), ORGANIZ