ssm整合 阳光穿透心脏的1/2处 2024-04-01 12:11 9阅读 0赞 ## ssm整合 ## ## 一 先添加spring框架 ## ##### 1.创建一个maven项目 ##### ##### 2.在pom.xml中添加spring jar包 ##### <!-- Spring --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-context</artifactId> <version>4.3.18.RELEASE</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-core</artifactId> <version>4.3.18.RELEASE</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-beans</artifactId> <version>4.3.18.RELEASE</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-context-support</artifactId> <version>4.3.18.RELEASE</version> </dependency> ##### 3.创建基本mvc结构 ##### pojo层: Items类 package com.test.pojo; import java.util.Date; public class Items { private int id; private String name; private float price; private String detail; private String pic; private Date createtime; public int getId() { return id; } public void setId(int id) { this.id = id; } public String getName() { return name; } public void setName(String name) { this.name = name; } public float getPrice() { return price; } public void setPrice(float price) { this.price = price; } public String getDetail() { return detail; } public void setDetail(String detail) { this.detail = detail; } public String getPic() { return pic; } public void setPic(String pic) { this.pic = pic; } public Date getCreatetime() { return createtime; } public void setCreatetime(Date createtime) { this.createtime = createtime; } @Override public String toString() { return "Items{" + "id=" + id + ", name='" + name + '\'' + ", price=" + price + ", detail='" + detail + '\'' + ", pic='" + pic + '\'' + ", createtime=" + createtime + '}'; } } dao层 接口 IItemsDao package com.test.dao; import com.test.pojo.Items; import java.util.List; public interface IItemsDao { public List<Items> selectItems(); } 实现类 ItemsDao package com.test.dao.impl; import com.test.dao.IItemsDao; import com.test.mapper.ItemsMapper; import com.test.pojo.Items; import org.springframework.stereotype.Component; import java.io.InputStream; import java.util.List; public class ItemsDao implements IItemsDao { public ItemsDao() { } public List<Items> selectItems() { return null; } } service层 接口:IItemsService package com.test.service; import com.test.pojo.Items; import java.util.List; public interface IItemsService { public List<Items> selectItems(); } 实现类:ItemsService package com.test.service.impl; import com.test.dao.IItemsDao; import com.test.mapper.ItemsMapper; import com.test.pojo.Items; import com.test.service.IItemsService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import java.util.List; public class ItemsService implements IItemsService { private IItemsDao itemsDao; public List<Items> selectItems() { return itemsDao.selectItems(); } } ##### 4.创建spring的配置文件 ##### applicationContext-ioc.xml <?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:context="http://www.springframework.org/schema/context" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd"> </beans> 5.在配置文件中添加注解扫描包 <?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:context="http://www.springframework.org/schema/context" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd"> <!-- 设置注解 扫描 的包 --> <context:component-scan base-package="com.test" /> </beans> 1. 在mvc各层中添加注解 package com.test.dao.impl; import com.test.dao.IItemsDao; import com.test.mapper.ItemsMapper; import com.test.pojo.Items; import org.springframework.stereotype.Component; import java.io.InputStream; import java.util.List; @Component public class ItemsDao implements IItemsDao { public ItemsDao() { } public List<Items> selectItems() { return null; } } @Service public class ItemsService implements IItemsService { @Autowired private IItemsDao itemsDao; public List<Items> selectItems() { return itemsDao.selectItems(); } } ## 二.在spring中引入mybatis ## ##### 1.导入mybatis jar包 ##### <!-- 导入mybatis需要的jar包 --> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>5.1.37</version> </dependency> <dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis</artifactId> <version>3.4.6</version> </dependency> <dependency> <groupId>com.mchange</groupId> <artifactId>c3p0</artifactId> <version>0.9.5.2</version> </dependency> <!-- 配置日志信息--> <dependency> <groupId>log4j</groupId> <artifactId>log4j</artifactId> <version>1.2.17</version> </dependency> ##### 2.导入spring整合mybatis架包 ##### <!-- spring 整合 mybatis--> <dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis-spring</artifactId> <version>1.3.0</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-jdbc</artifactId> <version>4.3.18.RELEASE</version> </dependency> ##### 3.创建mapper文件 ##### <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <mapper namespace="com.test.mapper.ItemsMapper"> <select id="selectItems" resultType="Items"> select * from items; </select> </mapper> ##### 4.创建mapper文件的代理接口 ##### package com.test.mapper; import com.test.pojo.Items; import java.util.List; public interface ItemsMapper { public List<Items> selectItems(); } ##### 5.创建mybatis配置文件 ##### mybatis.xml文件 <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN" "http://mybatis.org/dtd/mybatis-3-config.dtd"> <configuration> <!-- 设置日志的输出方法 --> <settings> <setting name="logImpl" value="STDOUT_LOGGING" /> </settings> <!-- 给pojo下面的类设置别名--> <typeAliases> <package name="com.test.pojo"/> </typeAliases> <mappers> <mapper resource="com/test/mapper/ItemsMapper.xml"/> </mappers> </configuration> ##### 6. 创建db.properties文件 ##### jdbc.driver=com.mysql.jdbc.Driver jdbc.url=jdbc:mysql://localhost:3306/ssm?characterEncoding=utf-8 jdbc.username=root jdbc.password=123 ##### 7. 修改applicationContext-ioc.xml文件 ##### 将之前在mybatis文件中配置的数据源 交给spring来管理,并创建sqlSessionFactory对象 <?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:context="http://www.springframework.org/schema/context" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd"> <!-- 设置注解 扫描 的包 --> <context:component-scan base-package="com.test" /> <!-- 导入db.properties文件 --> <context:property-placeholder location="classpath:db.properties"></context:property-placeholder> <!-- 创建一个连接池对象 --> <bean id="comboPooledDataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource"> <property name="driverClass" value="${jdbc.driver}" /> <property name="jdbcUrl" value="${jdbc.url}"/> <property name="user" value="${jdbc.username}" /> <property name="password" value="${jdbc.password}" /> </bean> <!-- 创建sqlSessionfactory对象--> <bean id="sqlSessionfactory" class="org.mybatis.spring.SqlSessionFactoryBean"> <property name="dataSource" ref="comboPooledDataSource"/> <property name="configLocation" value="classpath:mybatis.xml"/> </bean> </beans> ##### 8.修改dao层 ##### package com.test.dao.impl; import com.test.dao.IItemsDao; import com.test.mapper.ItemsMapper; import com.test.pojo.Items; import org.apache.ibatis.session.SqlSession; import org.apache.ibatis.session.SqlSessionFactory; import org.apache.ibatis.session.SqlSessionFactoryBuilder; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import java.io.InputStream; import java.util.List; @Component public class ItemsDao implements IItemsDao { @Autowired private SqlSessionFactory sqlSessionFactory; public ItemsDao() { } public List<Items> selectItems() { SqlSession sqlSession= sqlSessionFactory.openSession(); ItemsMapper itemsMapper= sqlSession.getMapper(ItemsMapper.class); List<Items> itemsList= itemsMapper.selectItems(); return itemsList; } } ##### 9.在pom.xml文件中添加mapper.xml文件的路径 ##### 在build标签中添加 <resources> <resource> <!-- 将Mapper的映射文件拷贝出来 --> <directory>src/main/java</directory> <includes> <include>**/*.xml</include> </includes> <filtering>true</filtering> </resource> </resources> ##### 10.测试 ##### @Test public void fun() { ClassPathXmlApplicationContext classPathXmlApplicationContext=new ClassPathXmlApplicationContext("/applicationContext-ioc.xml"); IItemsService itemsService= classPathXmlApplicationContext.getBean("itemsService",IItemsService.class); System.out.println(itemsService.selectItems()); } ## 三 给mapper接口创建代理,替代原dao层的功能 ## 1.在applicationContext-ioc.xml文件中 添加 <!-- 配置映射文件的扫描器 --> <bean class="org.mybatis.spring.mapper.MapperScannerConfigurer"> <property name="basePackage" value="com.test.mapper"/> </bean> 1. 修改service代码 将之前的 @Autowired private IItemsDao itemsDao; 修改为 @Autowired private ItemsMapper itemsMapper; 完整代码如下 package com.test.service.impl; import com.test.dao.IItemsDao; import com.test.mapper.ItemsMapper; import com.test.pojo.Items; import com.test.service.IItemsService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import org.springframework.stereotype.Service; import java.util.List; @Service public class ItemsService implements IItemsService { @Autowired private ItemsMapper itemsMapper; public List<Items> selectItems() { return itemsMapper.selectItems(); } } 1. 原来的dao层可以删除 2. 测试代码不变 ## 四.在spring中引入springmvc ## #### 1.导入jar包 #### <!-- 导入SpringMvc 需要的jar包 --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-webmvc</artifactId> <version>4.3.18.RELEASE</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-web</artifactId> <version>4.3.18.RELEASE</version> </dependency> #### 2.创建springmvc.xml的配置文件 #### <?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:p="http://www.springframework.org/schema/p" xmlns:context="http://www.springframework.org/schema/context" xmlns:mvc="http://www.springframework.org/schema/mvc" 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.xsd http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc.xsd"> <!-- 1. 扫描包 控制层 --> <context:component-scan base-package="com.test.action" /> <!-- 2. 配置视图解析器 --> <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver"> <property name="prefix" value="/WEB-INF/" /> <property name="suffix" value=".jsp" /> </bean> <!-- 3 开启注解--> <mvc:annotation-driven></mvc:annotation-driven> </beans> #### 3. 在web.xml 添加 DispatcherServlet #### <!-- 配置 DispatcherServlet --> <servlet> <servlet-name>dispatcherServlet</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <init-param> <param-name>contextConfigLocation</param-name> <param-value>classpath:springmvc.xml</param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>dispatcherServlet</servlet-name> <url-pattern>/</url-pattern> </servlet-mapping> #### 4.在web.xml 添加 spring容器的加载监听器 #### 让springmvc中的DispatcherServlet帮我们启动spring的相关配置文件 配置在DispatcherServlet的前面 <!-- 配置spring...xml文件的路径 --> <context-param> <param-name>contextConfigLocation</param-name> <param-value>classpath:applicationContext-ioc.xml</param-value> </context-param> <!-- 配置context 加载的监听器 --> <!-- 加载spring 的容器 --> <listener> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> #### 5.创建控制层的类和方法 并加入注解 #### package com.test.action; import com.test.pojo.Items; import com.test.service.IItemsService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.servlet.ModelAndView; import java.util.List; @Controller @RequestMapping("/items") public class ItemsAction { @Autowired private IItemsService itemsService; public IItemsService getItemsService() { return itemsService; } public void setItemsService(IItemsService itemsService) { this.itemsService = itemsService; } @RequestMapping("/selectItemsList") public ModelAndView selectItemsList() { //调用service的查询方法 返回一个list List<Items> itemsList= itemsService.selectItems(); //组装ModelAndView 对象 ModelAndView modelAndView=new ModelAndView(); modelAndView.addObject("itemsList",itemsList); modelAndView.setViewName("showItems"); //将数据存入 request,并转发到 WEB-INF/showItems.jsp页面 return modelAndView; } } #### 6.创建视图页面 #### 根据之前配置的试图解析器中的前缀,需要将jsp文件创建在 WEB-INF文件夹下 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> <%-- Created by IntelliJ IDEA. User: Administrator Date: 2019\6\26 0026 Time: 10:36 To change this template use File | Settings | File Templates. --%> <%@ page contentType="text/html;charset=UTF-8" language="java" %> <html> <head> <title>Title</title> </head> <body> <c:forEach var="items" items="${itemsList}" > ${items.name}<br/> </c:forEach> </body> </html> #### 7.执行 #### http://localhost:8080/testssm/items/selectItemsList ## 五.相关配置文件附录: ## #### 1.pom.xml #### <?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>com.test</groupId> <artifactId>TestSSM</artifactId> <version>1.0-SNAPSHOT</version> <packaging>war</packaging> <name>TestSSM Maven Webapp</name> <!-- FIXME change it to the project's website --> <url>http://www.example.com</url> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <maven.compiler.source>1.7</maven.compiler.source> <maven.compiler.target>1.7</maven.compiler.target> </properties> <dependencies> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.11</version> <scope>test</scope> </dependency> <!-- Spring --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-context</artifactId> <version>4.3.18.Release</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-core</artifactId> <version>4.3.18.Release</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-beans</artifactId> <version>4.3.18.Release</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-context-support</artifactId> <version>4.3.18.Release</version> </dependency> <!-- 配置servlet--> <dependency> <groupId>javax.servlet</groupId> <artifactId>javax.servlet-api</artifactId> <version>3.1.0</version> <scope>provided</scope> </dependency> <!--配置jsp的依赖 --> <dependency> <groupId>javax.servlet.jsp</groupId> <artifactId>jsp-api</artifactId> <version>2.2</version> <scope>provided</scope> </dependency> <!-- 配置jstl --> <dependency> <groupId>javax.servlet</groupId> <artifactId>jstl</artifactId> <version>1.2</version> </dependency> <dependency> <groupId>taglibs</groupId> <artifactId>standard</artifactId> <version>1.1.2</version> </dependency> <!-- 导入mybatis需要的jar包 --> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>5.1.37</version> </dependency> <dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis</artifactId> <version>3.4.6</version> </dependency> <dependency> <groupId>com.mchange</groupId> <artifactId>c3p0</artifactId> <version>0.9.5.2</version> </dependency> <!-- spring 整合 mybatis--> <dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis-spring</artifactId> <version>1.3.0</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-jdbc</artifactId> <version>4.3.18.RELEASE</version> </dependency> <!-- 配置日志信息--> <dependency> <groupId>log4j</groupId> <artifactId>log4j</artifactId> <version>1.2.17</version> </dependency> <!-- 导入SpringMvc 需要的jar包 --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-webmvc</artifactId> <version>4.3.18.RELEASE</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-web</artifactId> <version>4.3.18.RELEASE</version> </dependency> </dependencies> <build> <resources> <resource> <directory>src/main/java</directory> <includes> <include>**/*.xml</include> </includes> </resource> </resources> <finalName>TestSSM</finalName> <pluginManagement><!-- lock down plugins versions to avoid using Maven defaults (may be moved to parent pom) --> <plugins> <plugin> <artifactId>maven-clean-plugin</artifactId> <version>3.1.0</version> </plugin> <!-- see http://maven.apache.org/ref/current/maven-core/default-bindings.html#Plugin_bindings_for_war_packaging --> <plugin> <artifactId>maven-resources-plugin</artifactId> <version>3.0.2</version> </plugin> <plugin> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.0</version> </plugin> <plugin> <artifactId>maven-surefire-plugin</artifactId> <version>2.22.1</version> </plugin> <plugin> <artifactId>maven-war-plugin</artifactId> <version>3.2.2</version> </plugin> <plugin> <artifactId>maven-install-plugin</artifactId> <version>2.5.2</version> </plugin> <plugin> <artifactId>maven-deploy-plugin</artifactId> <version>2.8.2</version> </plugin> </plugins> </pluginManagement> </build> </project> #### 2.web.xml #### <?xml version="1.0" encoding="UTF-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://xmlns.jcp.org/xml/ns/javaee" xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd" id="WebApp_ID" version="3.1"> <display-name>Archetype Created Web Application</display-name> <!-- 配置spring...xml文件的路径 --> <context-param> <param-name>contextConfigLocation</param-name> <param-value>classpath:applicationContext-ioc.xml</param-value> </context-param> <!-- 配置context 加载的监听器 --> <!-- 加载spring 的容器 --> <listener> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> <!-- 配置 DispatcherServlet --> <servlet> <servlet-name>dispatcherServlet</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <init-param> <param-name>contextConfigLocation</param-name> <param-value>classpath:springmvc.xml</param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>dispatcherServlet</servlet-name> <url-pattern>/</url-pattern> </servlet-mapping> </web-app> #### 3.db.properties #### db.driverClass=com.mysql.jdbc.Driver db.url=jdbc:mysql://localhost:3306/ssm?characterEncoding=utf-8 db.user=root db.password=123 #### 4.applicationContext-ioc.xml #### <?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:context="http://www.springframework.org/schema/context" xmlns:aop="http://www.springframework.org/schema/aop" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-4.0.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd"> <!-- 1. 配置扫描的包--> <context:component-scan base-package="com.test" /> <!-- 2. 导入db.properties --> <context:property-placeholder location="classpath:db.properties" /> <!-- 3 创建数据源 --> <bean id="dataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource"> <property name="driverClass" value="${db.driverClass}" /> <property name="jdbcUrl" value="${db.url}" /> <property name="user" value="${db.user}" /> <property name="password" value="${db.password}" /> </bean> <!-- 4.创建sqlSessionFactory对象 --> <bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean"> <property name="dataSource" ref="dataSource" /> <property name="configLocation" value="classpath:mybatis.xml" /> </bean> <!-- 5.配置mapper接口的代理 需要扫描的包 --> <!-- mapper.xml文件和ItemsMapper接口需要放在一个包中 --> <bean class="org.mybatis.spring.mapper.MapperScannerConfigurer"> <property name="basePackage" value="com.test.mapper" /> </bean> </beans> #### 5.springmvc.xml #### <?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:p="http://www.springframework.org/schema/p" xmlns:context="http://www.springframework.org/schema/context" xmlns:mvc="http://www.springframework.org/schema/mvc" 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.xsd http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc.xsd"> <!-- 1. 扫描b包 控制层 --> <context:component-scan base-package="com.test.action" /> <!-- 2. 配置视图解析器 --> <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver"> <property name="prefix" value="/WEB-INF/" /> <property name="suffix" value=".jsp" /> </bean> <!-- 3 开启注解--> <mvc:annotation-driven></mvc:annotation-driven> </beans>
相关 整合 SSM 1.1 相关依赖 <dependency> <groupId>org.springframework</groupId> <art 不念不忘少年蓝@/ 2022年12月05日 05:21/ 0 赞/ 63 阅读
相关 ssm整合 整合:spring4.2.5+mybatis3.2.8+springMVC+maven 环境:Myeclipse2014+mysql5.5.20+tomcat8+jdk1. 柔光的暖阳◎/ 2022年07月13日 11:19/ 0 赞/ 176 阅读
相关 ssm整合 手把手教你整合最优雅SSM框架:SpringMVC + Spring + MyBatis -------------------- > 我们看招聘信息的时候,经常 古城微笑少年丶/ 2022年07月12日 06:27/ 0 赞/ 70 阅读
相关 ssm整合 手把手教你整合最优雅SSM框架:SpringMVC + Spring + MyBatis -------------------- > 我们看招聘信息的时候,经常 墨蓝/ 2022年07月12日 06:27/ 0 赞/ 97 阅读
相关 ssm整合 在mybatis和spring整合后 , 在把springmvc整合进来 在maven里创建web工程 然后进行mybatis和spring的整合步骤(写在其他博客里) 超、凢脫俗/ 2022年02月12日 10:10/ 0 赞/ 476 阅读
相关 ssm整合 一、注入依赖 <?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://mav 快来打我*/ 2022年01月23日 12:57/ 0 赞/ 484 阅读
相关 SSM--SSM整合 一、项目层级结构以及所需JAR包: ![watermark_type_ZmFuZ3poZW5naGVpdGk_shadow_10_text_aHR0cHM6Ly9ibG9 傷城~/ 2022年01月21日 23:37/ 0 赞/ 519 阅读
相关 ssm整合 ssm整合 项目目录 ![1560559-20190805161522126-1893405258.png][] jar ![1560559-2019080 桃扇骨/ 2021年10月24日 02:56/ 0 赞/ 526 阅读
相关 SSM整合 前提:jdk,maven,tomcat,STS都已经安装配置好了 spring-4.3.7 + mybatis-3.3.0 + maven3.5+jdk8(这个组合会减少很多 悠悠/ 2021年09月28日 07:58/ 0 赞/ 493 阅读
相关 SSM整合 SSM:Spring+SpringMVC+MyBatis 1、导包 1)、Spring 【aop核心】 com.springsource.net.sf. 男娘i/ 2021年09月23日 16:18/ 0 赞/ 539 阅读
还没有评论,来说两句吧...