
[Java / Spring] 스프링 컨테이너
·
Framework & Library/Spring
- 스프링 컨테이너와 스프링 빈 / 스프링 컨테이너 생성 정리 스프링 컨테이너 생성 AnnotationConfigApplicationContext ac = new AnnotationConfigApplicationContext(AppConfig.class); ApplicationContext : 스프링 컨테이너(인터페이스) 스프링 컨테이너는 XML, 애노테이션 기반의 자바 설정 클래스로 만들 수 있음 AnnotationConfigApplicationContext(AppConfig.class) -> ApplicationContext 인터페이스의 구현체 애노테이션 기반 자바 설정 클래스 AppConfig package hello.core; import hello.core.discount.DiscountPoli..