当前位置:网站首页>SM integration is as simple as before, and the steps are clear (detailed)
SM integration is as simple as before, and the steps are clear (detailed)
2022-07-29 05:15:00 【It's a quack】
Catalog
2) New projects , choice quickstart Templates
4) modify pom.xml file , Add related dependencies
Add visualization of the database
5) add to MyBatis Corresponding template (SqlMapConfig.xml and XXXMapper.xml file )
7) add to applicationContext_mapper.xml
8) add to applicationContext_service.xml
9) add to Users Entity class ,Accounts Entity class
10) add to mapper package , add to UsersMapper Interface and UsersMapper.xml Document and develop
11) add to service package , add to UsersService Interface and UsersServiceImpl Implementation class
12) Add test classes for functional testing
SSM Integrate
at present Spring+SpringMVC+Mybatis It is a very popular supporting development framework .
spring The core ioc、aop technology ,ioc decoupling , Reuse code , Greatly improved maintainability ,aop Provides section programming , The same increases productivity . Provides integration support for other excellent open source frameworks spring mvc It's the contrast struts2 etc. mvc Framework , Don't say struts2 So many security vulnerabilities , And it's class interception , all Action Variable sharing , At the same time filter Entrance , and spring mvc Is the way to intercept ,controller exclusive request response data , Adopted serlvet entrance , And spring Seamless docking . In terms of development ,spring mvc Lighter and lower entry .mybatis Lightweight semi automated framework ,sql Written by the developer, the statement can be tuned , also mybatis Use XML The way JAVA Code and the SQL It can be decoupled and supports dynamic SQL sentence , The cost of learning is low .
The following is database creation table

SM Integration steps
1) Build table

2) New projects , choice quickstart Templates



3) Modify the catalog

4) modify pom.xml file , Add related dependencies




Add visualization of the database


5) add to MyBatis Corresponding template (SqlMapConfig.xml and XXXMapper.xml file )
6) add to SqlMapConfig.xml file (MyBatis Core profile ), And copy jdbc.propertiest Properties file to resources Under the table of contents

7) add to applicationContext_mapper.xml








8) add to applicationContext_service.xml

9) add to Users Entity class ,Accounts Entity class



10) add to mapper package , add to UsersMapper Interface and UsersMapper.xml Document and develop

11) add to service package , add to UsersService Interface and UsersServiceImpl Implementation class







12) Add test classes for functional testing
Users add a complete set

to account increase 






That's all setting getting and tostring
Keep going On map Interface 












边栏推荐
- Apache POI实现Excel导入读取数据和写入数据并导出
- A little knowledge about management
- Use annotation test in idea
- How to solve the problem of configuring the progress every time Office2010 is opened?
- The song of the virtual idol was originally generated in this way!
- Button for QT custom switch effect
- MySQL sorts the queried result set according to the specified sequence
- 【微信小程序--解决display:flex最后一行对齐问题。(不连续排列会分到两边)】
- 网安学习-内网安全1
- Deadlock to be resolved
猜你喜欢

Solve the warning prompt of MySQL mapping file

时间序列分析的表示学习时代来了?

三层项目的架构分析及构造方法的参数名称注入

那个准时上下班,从不愿意加班加点的人,在我前面升职了...

Excel卡住了没保存怎么办?Excel还没保存但是卡住了的解决方法

浅谈AspectJ框架

How to install Office2010 installation package? How to install Office2010 installation package on computer

js(forEach)出现return无法结束函数的解决方法

Diagram of odoo development tutorial

Deep learning brush a bunch of tricks of SOTA
随机推荐
About realizing page Jump of website in Servlet
P2181 diagonal
开区网站打开自动播放音乐的添加跟修改教程
【文件下载】Easyexcel快速上手
【微信小程序--解决display:flex最后一行对齐问题。(不连续排列会分到两边)】
如何让照片中的人物笑起来?HMS Core视频编辑服务一键微笑功能,让人物笑容更自然
Unity Metaverse(三)、Protobuf & Socket 实现多人在线
What if the computer cannot open excel? The solution of Excel not opening
ARFoundation从零开始3-创建ARFoundation项目
ARFoundation入门教程7-url动态加载图像跟踪库
【2022新生学习】第三周要点
Mysql多对多关系,分组拼接把多个数据查询到一条数据上
The representation of time series analysis: is the era of learning coming?
TMUX essays
tmux随笔
How does word view document modification traces? How word views document modification traces
JS (foreach) return cannot end the function solution
"Invisible Bridge" built in the free trade economy: domestic products and Chinese AI power
Mysql的自连接和联合查询
Deadlock analysis using jstack, jconsole, and jvisualvm
















