2016年12月12日星期一

spring boot使用@PostConstruct初始化static变量

在类中定义private static变量,然后使用@PostConstruct:
@PostConstruct
public void init() {
}
init()中给static变量赋值

没有评论:

发表评论