1E) Spring MVC Framework ①JAR Package Structure: Docs+libs+schema. Version difference: Core package, source package.
SPRINGMVC document Learning, learning three steps:
1) What is it? Open Source Framework
2) What do you do? IOC: Dependency Injection. is a design mode set () mode injectionAOP:3) What do you do?
② Create a simple Spring framework code directory structure as follows:
Step: 1) Create JavaBean2) create DAO, and service Class 3) write the configuration file applicationcontext.xml Basic configuration code is as follows:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.0.xsd">
<bean id="userBean" class="Spring_Bean.UserBean">
<property name="username" value="kam"></property>
<property name="password" value="123456"></property>
</bean>
<bean id="userDao" class="Spring_Dao.UserDaoImpl"></bean>
<bean id="userService" class="Spring_Service.UserServiceImpl">
<property name="daoInf" ref="userDao"></property>
</bean>
</beans>
Today's content is basically the case.
From for notes (Wiz)
SPRINGMVC Study Record