摘要:
@Override public void refresh() throws BeansException, IllegalStateException { synchronized (this.startupShutdownMonitor) { // Prepare this context fo 阅读全文
摘要:
bean: @Data public class Food { private String color; } @Data public class Cat { private String catName; private Food food; // 构造方法1 public Cat(String 阅读全文
摘要:
bean: @Data public class Food { private String color; } import lombok.Data; @Data public class Mouse { private String mouseName; private List<String> 阅读全文
摘要:
更方便属性注入:用法:1. bean加入工作空间 (不需要加schemaLocation) xmlns:p="http://www.springframework.org/schema/p" 2. @Data public class Food { private String color; } < 阅读全文
摘要:
使用lombok自动生成get/set方法,简洁代码: 1. 安装插件 2 导入依赖 <dependency> <groupId>org.projectlombok</groupId> <artifactId>lombok</artifactId> <version>1.18.4</version> 阅读全文
摘要:
web.xml 中spring的配置: <listener> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> <context-param> <par 阅读全文