今日知识

1. Spring整合MyBatis
2. SSM普通整合
3. SSM整合(Spring和SpringMVC分离)
4. 纯JavaConfig的SSM

Spring整合MyBatis

1. 导包
<properties>
<spring.version>5.1.8.RELEASE</spring.version>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>3.2.6</version>
</dependency>
<!--mybatis的spring支持包-->
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis-spring</artifactId>
<version>1.2.2</version>
</dependency>
<!--连接数据库的四个包-->
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>8.0.16</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>commons-dbcp</groupId>
<artifactId>commons-dbcp</artifactId>
<version>1.2.2</version>
</dependency>
<!--test-->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
<version>${spring.version}</version>
</dependency>
</dependencies>
2. 创建UserMapper接口
public interface UserMapper {
public User selectByPrimaryKey(int id);
}
3. 创建UserService接口
public interface UserService {
public User selectByPrimaryKey(int id);
}
4. 创建UserMapperImpl实现类
@Component
public class UserServiceImpl implements UserService {
@Autowired
UserMapper userMapper;
public User selectByPrimaryKey(int id) {
return userMapper.selectByPrimaryKey(id);
}
}
5. UserMapper.xml创建
<mapper namespace="com.rqy.mapper.UserMapper">
<resultMap id="BaseResultMap" type="com.rqy.domain.User">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="username" jdbcType="VARCHAR" property="username" />
<result column="birthday" jdbcType="DATE" property="birthday" />
<result column="sex" jdbcType="CHAR" property="sex" />
<result column="address" jdbcType="VARCHAR" property="address" />
/resultMap>
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
*
from user
where id = #{id,jdbcType=INTEGER}
</select>
</mapper>
6. application.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:aop="http://www.springframework.org/schema/aop"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xsi:schemaLocation="
http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/mvc https://www.springframework.org/schema/mvc/spring-mvc.xsd
http://www.springframework.org/schema/context https://www.springframework.org/schema/context/spring-context.xsd
http://www.springframework.org/schema/aop https://www.springframework.org/schema/aop/spring-aop.xsd"> <context:component-scan base-package="com.rqy"/>
<!--<mvc:annotation-driven/>-->
<!--数据源-->
<bean id="datasource" class="org.apache.commons.dbcp.BasicDataSource">
<property name="driverClassName" value="com.mysql.jdbc.Driver"/>
<property name="url" value="jdbc:mysql://localhost:3306/mybatisday01?serverTimezone=UTC"/>
<property name="username" value="root"/>
<property name="password" value="123456"/>
</bean>
<!--1.1.2 配置sqlSessionFactory-->
<bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean">
<property name="dataSource" ref="datasource"/>
<!--<property name="configLocation" value="classpath:SqlMapConfig.xml"/>-->
</bean>
<!--MapperFactoryBean,缺点每个mapper接口都要注册进来--> <!--<bean id="userMapper" class="org.mybatis.spring.mapper.MapperFactoryBean">
<property name="mapperInterface" value="com.rqy.mapper.UserMapper"/>
&lt;!&ndash;sqlSessionFactory注入到mapper中,代替mapper实现类&ndash;&gt;
<property name="sqlSessionFactory" ref="sqlSessionFactory"/>
</bean>--> <!--把整个mapper接口所在的包都注册进来-->
<bean class="org.mybatis.spring.mapper.MapperScannerConfigurer">
<!--扫描包,取代了SqlMapConfig.xml mapper映射文件-->
<property name="basePackage" value="com.rqy.mapper"/>
<!--与上面不太一样-->
<property name="sqlSessionFactoryBeanName" value="sqlSessionFactory"/>
</bean>
</beans>
7. 测试
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration("classpath:application.xml")
public class MyTest {
@Autowired
UserService userService;
@Test
public void test(){
User user = userService.selectByPrimaryKey(35);
System.out.println(user);
}
}

SSM普通整合

1. 导包(数据源的包采用的druid的,你也可以采用其他的额)
<properties>
<spring.version>5.1.8.RELEASE</spring.version>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>3.0-alpha-1</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>3.2.6</version>
</dependency>
<!--mybatis的spring支持包-->
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis-spring</artifactId>
<version>1.2.2</version>
</dependency>
<!--连接数据库-->
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>8.0.16</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>druid</artifactId>
<version>1.1.11</version>
</dependency>
<!--test-->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
<version>${spring.version}</version>
</dependency>
<!--jackson-->
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.9.7</version>
</dependency>
</dependencies>
2. 创建UserMapper接口
public interface UserMapper {
public User selectByPrimaryKey(int id);
}
3. 创建UserService接口
public interface UserService {
public User selectByPrimaryKey(int id);
}
4. 创建UserMapperImpl实现类
@Component
public class UserServiceImpl implements UserService {
@Autowired
UserMapper userMapper;
public User selectByPrimaryKey(int id) {
return userMapper.selectByPrimaryKey(id);
}
}
5. UserMapper.xml创建
<mapper namespace="com.rqy.mapper.UserMapper">
<resultMap id="BaseResultMap" type="com.rqy.domain.User">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="username" jdbcType="VARCHAR" property="username" />
<result column="birthday" jdbcType="DATE" property="birthday" />
<result column="sex" jdbcType="CHAR" property="sex" />
<result column="address" jdbcType="VARCHAR" property="address" />
/resultMap>
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
*
from user
where id = #{id,jdbcType=INTEGER}
</select>
</mapper>
6. application.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:mvc="http://www.springframework.org/schema/mvc"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.2.xsd
http://www.springframework.org/schema/mvc
http://www.springframework.org/schema/mvc/spring-mvc-3.2.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-3.2.xsd
http://www.springframework.org/schema/aop
http://www.springframework.org/schema/aop/spring-aop-3.2.xsd
http://www.springframework.org/schema/tx
http://www.springframework.org/schema/tx/spring-tx-3.2.xsd"> <context:component-scan base-package="com.rqy"/>
<mvc:annotation-driven/>
<!--数据源-->
<bean id="datasource" class="com.alibaba.druid.pool.DruidDataSource">
<property name="driverClassName" value="com.mysql.jdbc.Driver"/>
<property name="url" value="jdbc:mysql://localhost:3306/mybatisday01?serverTimezone=UTC"/>
<property name="username" value="root"/>
<property name="password" value="123456"/>
</bean>
<!--1.1.2 配置sqlSessionFactory-->
<bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean">
<property name="dataSource" ref="datasource"/>
</bean>
<!--把整个mapper接口所在的包都注册进来-->
<bean class="org.mybatis.spring.mapper.MapperScannerConfigurer">
<!--扫描包,取代了SqlMapConfig.xml mapper映射文件-->
<property name="basePackage" value="com.rqy.mapper"/>
<!--与上面不太一样-->
<property name="sqlSessionFactoryBeanName" value="sqlSessionFactory"/>
</bean> <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
<property name="prefix" value="/WEB-INF/views/"/>
<property name="suffix" value=".jsp"/>
</bean>
</beans>
7. Web.xml
<servlet>
<servlet-name>dispatcher</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<init-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath:application.xml</param-value>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>dispatcher</servlet-name>
<url-pattern>/</url-pattern>
</servlet-mapping>
8. UserController.java
@Controller
public class UserController {
@Autowired
UserService userService;
@RequestMapping("user")
public @ResponseBody User query(int id){
User user = userService.selectByPrimaryKey(id);
System.out.println(user);
return user;
}
}

SSM整合(Spring和SpringMVC分离)

1. 导包(和上面一样)
2. 创建UserMapper接口(和上面一样)
3. 创建UserService接口(和上面一样)
4. 创建UserMapperImpl实现类(和上面一样)
5. UserMapper.xml创建(和上面一样)
6. application.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:mvc="http://www.springframework.org/schema/mvc"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.2.xsd
http://www.springframework.org/schema/mvc
http://www.springframework.org/schema/mvc/spring-mvc-3.2.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-3.2.xsd
http://www.springframework.org/schema/aop
http://www.springframework.org/schema/aop/spring-aop-3.2.xsd
http://www.springframework.org/schema/tx
http://www.springframework.org/schema/tx/spring-tx-3.2.xsd"> <context:component-scan base-package="com.rqy">
<context:exclude-filter type="annotation" expression="org.springframework.stereotype.Controller"/>
</context:component-scan>
<!--数据源-->
<bean id="datasource" class="com.alibaba.druid.pool.DruidDataSource">
<property name="driverClassName" value="com.mysql.jdbc.Driver"/>
<property name="url" value="jdbc:mysql://localhost:3306/mybatisday01?serverTimezone=UTC"/>
<property name="username" value="root"/>
<property name="password" value="123456"/>
</bean>
<!--1.1.2 配置sqlSessionFactory-->
<bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean">
<property name="dataSource" ref="datasource"/>
</bean> <!--把整个mapper接口所在的包都注册进来-->
<bean class="org.mybatis.spring.mapper.MapperScannerConfigurer">
<!--扫描包,取代了SqlMapConfig.xml mapper映射文件-->
<property name="basePackage" value="com.rqy.mapper"/>
<!--与上面不太一样-->
<property name="sqlSessionFactoryBeanName" value="sqlSessionFactory"/>
</bean>
<!--测试的bean,项目初始化的时候就会执行-->
<bean class="com.rqy.domain.SpringBean"/>
</beans>
7. application-mvc.xml
<!--扫描包这个配置在springmvc的容器中不能去掉-->
<context:component-scan base-package="com.rqy.controller">
<context:include-filter type="annotation" expression="org.springframework.stereotype.Controller"/>
</context:component-scan>
<mvc:annotation-driven/>
<!--测试的bean,当有url请求的时候才会执行-->
<bean class="com.rqy.domain.MvcBean"/> <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
<property name="prefix" value="/WEB-INF/views/"/>
<property name="suffix" value=".jsp"/>
</bean>
8. Web.xml(分别把application.xml和application-mvc.xml配置进去)
<!--通过listner注册spring容器,父容器-->
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath:application.xml</param-value>
</context-param> <servlet>
<servlet-name>dispatcher</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<init-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath:application-mvc.xml</param-value>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>dispatcher</servlet-name>
<url-pattern>/</url-pattern>
</servlet-mapping>
9. UserController.java
@Controller
public class UserController {
@Autowired
UserService userService;
@RequestMapping("user")
public @ResponseBody User query(int id){
User user = userService.selectByPrimaryKey(id);
System.out.println(user);
return user;
}
}

纯JavaConfig的SSM整合

思想:

1. 取消了application.xml和application-MVC.xml以及web.xml,
2. 用了一个继承AbstractAnnotationConfigDispatcherServletInitializer的类来实现具体文件配置
1. AppInitialize继承AACDSi类的书写
public class AppInitialize extends AbstractAnnotationConfigDispatcherServletInitializer {
//SpringConfig指的是spring配置文件
@Override
protected Class<?>[] getRootConfigClasses() {
return new Class[]{SpringConfig.class};
}
//SpringMvcConfig指的是springMvc配置文件
@Override
protected Class<?>[] getServletConfigClasses() {
return new Class[]{SpringMvcConfig.class};
}
//配置sevlet请求路径/就OK了
@Override
protected String[] getServletMappings() {
return new String[]{"/"};
}
//配置编码过滤器
@Override
protected Filter[] getServletFilters() {
CharacterEncodingFilter characterEncodingFilter = new CharacterEncodingFilter();
characterEncodingFilter.setEncoding("utf-8"); return new Filter[]{characterEncodingFilter};
}
}
2. SpringConfig类的书写
@Configuration
@ComponentScan(value = "com.rqy",
excludeFilters = @ComponentScan.Filter(type = FilterType.ANNOTATION,classes = {Controller.class}))
@EnableTransactionManagement
@EnableAspectJAutoProxy
public class SpringConfig { //dataSource,必要
@Bean
public DataSource druidDatasource(){
DruidDataSource druidDataSource = new DruidDataSource();
druidDataSource.setDriverClassName("com.mysql.jdbc.Driver");
druidDataSource.setUrl("jdbc:mysql://localhost:3306/mybatisday01");
druidDataSource.setUsername("root");
druidDataSource.setPassword("123456");
return druidDataSource;
} //SqlSessionFactoryBean 必要
@Bean
public SqlSessionFactoryBean sqlSessionFactoryBean(DataSource dataSource){
SqlSessionFactoryBean sqlSessionFactoryBean = new SqlSessionFactoryBean();
sqlSessionFactoryBean.setDataSource(dataSource);
return sqlSessionFactoryBean;
}
//MapperScannerConfigurer 必要
@Bean
public MapperScannerConfigurer mapperScannerConfigurer(){
MapperScannerConfigurer mapperScannerConfigurer =new MapperScannerConfigurer();
mapperScannerConfigurer.setSqlSessionFactoryBeanName("sqlSessionFactoryBean");
mapperScannerConfigurer.setBasePackage("com.rqy.mapper");
return mapperScannerConfigurer;
}
//文件的上传的配置,有需要才配置
@Bean
public CommonsMultipartResolver multipartResolver(){
CommonsMultipartResolver commonsMultipartResolver = new CommonsMultipartResolver();
commonsMultipartResolver.setMaxInMemorySize(5240000);
return commonsMultipartResolver;
}
//配置事务管理器,同时要开启注解
@Bean
public DataSourceTransactionManager transactionManager(DataSource dataSource){
DataSourceTransactionManager dataSourceTransactionManager = new DataSourceTransactionManager();
dataSourceTransactionManager.setDataSource(dataSource);
return dataSourceTransactionManager;
}
}
3. SpringMvcConfig配置需要实现WebMvcConfigurer接口
@EnableWebMvc
@ComponentScan(value = "com.rqy.controller",
includeFilters =@ComponentScan.Filter(type = FilterType.ANNOTATION,classes = Controller.class) )
public class SpringMvcConfig implements WebMvcConfigurer{
<!--实现date的转换开始-->
//注入本身已有的接口
@Autowired
ConfigurableConversionService conversionService;
//把自定义的conversionService重新注册到bean中
@Bean
//保证conversionService的唯一性
@Primary
public ConfigurableConversionService conversionService(){
return conversionService;
}
//指定执行顺序
@PostConstruct
public void addConverters(){
String2DateConverter string2DateConverter = new String2DateConverter();
conversionService.addConverter(string2DateConverter);
}
<!--实现date的转换结束-->
<!--实现过滤器的配置-->
@Override
public void addInterceptors(InterceptorRegistry registry) {
registry.addInterceptor(new MyFirstInterceptor());
//registry.addInterceptor().addPathPatterns("/abc/**");
}
<!--实现静态资源的配置-->
@Override
public void addResourceHandlers(ResourceHandlerRegistry registry) {
registry.addResourceHandler("/pic/**").addResourceLocations("file:D:/pic/");
registry.addResourceHandler("/pic/**").addResourceLocations("classpath:/pic/");
registry.addResourceHandler("/pic/**").addResourceLocations("/WEB-INF/pic");
}
//配置视图解析器
@Bean
public InternalResourceViewResolver internalResourceViewResolver(){
InternalResourceViewResolver internalResourceViewResolver = new InternalResourceViewResolver();
internalResourceViewResolver.setPrefix("/WEB-INF/views/");
internalResourceViewResolver.setSuffix(".jsp");
return internalResourceViewResolver;
}
}
4. 导包
<dependencies>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
<version>5.1.8.RELEASE</version>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>3.0-alpha-1</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>3.5.2</version>
</dependency>
<!--aspectj-->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-aspects</artifactId>
<version>5.0.2.RELEASE</version>
</dependency>
<!--mybatis对spring的支持包-->
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis-spring</artifactId>
<version>1.3.2</version>
</dependency>
<!--数据源和mysql驱动-->
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>druid</artifactId>
<version>1.1.11</version>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.47</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<version>5.1.8.RELEASE</version>
</dependency>
<!--test-->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
<version>5.1.8.RELEASE</version>
</dependency>
<!--jackson-->
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.9.7</version>
</dependency>
<!--文件上传的包-->
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.6</version>
</dependency>
<dependency>
<groupId>commons-fileupload</groupId>
<artifactId>commons-fileupload</artifactId>
<version>1.3.3</version>
</dependency>
</dependencies>
5. 日期格式的转换
public class String2DateConverter implements Converter<String,Date> {
@Override
public Date convert(String s) {
SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd");
try {
Date date=sdf.parse(s);
return date;
} catch (ParseException e) {
e.printStackTrace();
}
return null;
}
}
6. 过滤器的实现
public class MyFirstInterceptor  implements HandlerInterceptor{
@Override
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception {
System.out.println("preHandle");
return true;
}
@Override
public void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler, ModelAndView modelAndView) throws Exception {
System.out.println("postHandle");
}
@Override
public void afterCompletion(HttpServletRequest request, HttpServletResponse response, Object handler, Exception ex) throws Exception { }
}
7. 创建UserMapper接口(和上面一样)
8. 创建UserService接口(和上面一样)
9. 创建UserMapperImpl实现类(和上面一样)
10. UserMapper.xml创建(和上面一样)一般通过你工程来完成
11. UserController测试类
@Controller
public class UserController {
@Autowired
UserService userService;
@RequestMapping("user")
@ResponseBody
public User query(int id, Model model){
User user = userService.selectByPrimaryKey(id);
model.addAttribute("user",user.toString());
return user;
}
}

14-SSM整合的更多相关文章

  1. SSM整合框架实现ajax校验

    SSM整合框架实现ajax校验   刚学习了ssm框架,ajax校验成功,分享下 1.导入jar包

  2. SSM整合activiti框架

    一:WorkFlow简介 1:什么是工作流工作流(Workflow),指“业务过程的部分或整体在计算机应用环境下的自动化”.是对工作流程及其各操作步骤之间业务规则的抽象.概括描述.在计算机中,工作流属 ...

  3. java web开发入门八(ssm整合)基于intellig idea

    ssm整合 一.导入相关包 二.开发流程 1.写entity package com.eggtwo.euq.entity; import java.io.Serializable; import ja ...

  4. 08 SSM整合案例(企业权限管理系统):06.产品操作

    04.AdminLTE的基本介绍 05.SSM整合案例的基本介绍 06.产品操作 07.订单操作 08.用户操作 09.权限控制 10.权限关联与控制 11.AOP日志 06.产品操作 SSM 环境搭 ...

  5. Day01_企业权限管理(SSM整合)

    学于黑马程序员和传智播客联合做的教学项目 感谢 黑马程序员官网 传智播客官网 个人根据教程的每天的工作进度的代码和资料 密码:cti5 b站在线视频 微信搜索"艺术行者",关注并回 ...

  6. 五天一体_企业权限管理(SSM整合)

    学于黑马程序员和传智播客联合做的教学项目 感谢 黑马程序员官网 传智播客官网 个人根据教程的每天的工作进度的代码和资料 密码:cti5 b站在线视频 微信搜索"艺术行者",关注并回 ...

  7. 【环境搭建】SSM 整合使用

    SSM 整合使用 文章源码 搭建整合环境 整合说明 SSM 整合可以使用多种方式,但是选择 XML + 注解 的方式最为合适. 整合思路 搭建整合环境 Spring 环境搭建并测试 Spring 整合 ...

  8. Maven + 最新SSM整合

    . 1. 开发环境搭建 参考博文:Eclipse4.6(Neon) + Tomcat8 + MAVEN3.3.9 + SVN项目完整环境搭建 2. Maven Web项目创建 2.1. 2.2. 2. ...

  9. SSM整合配置

    SSM三大框架整合详细教程(Spring+SpringMVC+MyBatis) 使用SSM(Spring.SpringMVC和Mybatis)已经有三个多月了,项目在技术上已经没有什么难点了,基于现有 ...

  10. SSM整合中遇到的不能扫描注解的bug

    我的开发环境为: ubuntu14.04LTS 64bit; Spring Tool Suite  3.5.0.RELEASE Maven 3.2.3 SSM整合中遇到的不能扫描注解的bug 最终解决 ...

随机推荐

  1. NOIP2004普及组第3题 FBI树

    /* 1106: NOIP2004普及组第3题 FBI树 时间限制: 1 Sec 内存限制: 128 MB 提交: 10 解决: 9 [提交] [状态] [讨论版] [命题人:外部导入] 题目描述 我 ...

  2. dfs 序 欧拉序

    推荐博客 :https://www.cnblogs.com/stxy-ferryman/p/7741970.html DFS序其实就是一棵树顺次访问的结点的顺序,例如下面这棵树 它的 dfs 序就是 ...

  3. 【强化学习RL】model-free的prediction和control —— MC,TD(λ),SARSA,Q-learning等

    本系列强化学习内容来源自对David Silver课程的学习 课程链接http://www0.cs.ucl.ac.uk/staff/D.Silver/web/Teaching.html 本文介绍了在m ...

  4. THUWC2020 自闭记

    DAY 1 报道 领胸牌和-围巾-! 发现我和 \(ssf\) 小姐姐一个考场. 合影+开幕式 宾馆睡了一觉-睡上午觉真的舒服. 合影时在c位! 开幕式.比上次夏令营不知道好到哪里去了,讲话都挺有意思 ...

  5. [bzoj2004] [洛谷P3204] [Hnoi2010] Bus 公交线路

    Description 小Z所在的城市有N个公交车站,排列在一条长(N-1)km的直线上,从左到右依次编号为1到N,相邻公交车站间的距 离均为1km. 作为公交车线路的规划者,小Z调查了市民的需求,决 ...

  6. dotnet restore 初次运行 这个 指令 会安装 特别多的 4.0.0 或者 4.1 的 rc2-24027的 东东 这些东西。

  7. LeetCode 11 水池蓄水问题

    今天给大家分享的是一道LeetCode中等难度的题,难度不大,但是解法蛮有意思.我们一起来看题目: Link Container With Most Water Difficulty Medium 题 ...

  8. WEB Node-JS 服务器搭建

    一.创建express 1.创建一个单独文件 2.打开命令面板,进入该文件 3.npm config set registry = https://registry.npm.taobao.org(设置 ...

  9. 用ES7解决异步回调地狱问题

    用了 Promise 其实并没有真正解决回调地狱问题,并且还新增了很多 .then(data => { .... }) 这些很没有意义的 “模板代码”.所以先人们又搞出了generator 和 ...

  10. 关于远程办公,微软MVP 15年研发团队的经验分享

    今天是2月5日,春节假期结束后的第三天了.为了能够应对来势汹汹的疫情,众多互联网企业纷纷开启了远程办公模式.不知道各团队前两天的远程办公效果如何,我们 Worktile 管理层在大年初四就开始讨论远程 ...