본문 바로가기
개발/Spring

Annotation(어노테이션) 을 쓰기위한 xml설정

by 안알랴줌. 2020. 4. 1.

1. XML 파일에서 xml네임스페이스를 추가

   -> xmlns:context="http://www.springframework.org/schema/context"

 

2. xsi:schemaLocation 추가 

   Default

   xsi:schemaLocation="http://www.springframework.org/schema/beans
     http://www.springframework.org/schema/beans/spring-beans.xsd">

 

   추가

   xsi:schemaLocation="http://www.springframework.org/schema/beans
     http://www.springframework.org/schema/beans/spring-beans.xsd
     http://www.springframework.org/schema/context
     http://www.springframework.org/schema/context/spring-context-3.2.xsd">

 

3. <context:annotation-config> 추가

댓글