【Spring Boot 2.0学习之旅-07】SpringBoot常用starter介绍和整合模板Freemaker、Thymeleaf

2023-05-16

第七章 SpringBoot常用starter介绍和整合模板Freemaker、thymeleaf

07-1 SpringBoot Starter讲解

1.Spring starter是什么

starter是SpringBoot中的一个新发明,它有效的降低了项目开发过程的复杂程度,对于简化开发操作有着非常好的效果。

Starter starter是一组方便的依赖项描述符,您可以将其包含在您的应用程序中。您可以获得所需的所有 Spring 和相关技术的一站式服务,而无需搜索示例代码和复制粘贴加载的依赖项描述符。例如,如果您想开始使用 Spring 和 JPA 进行数据库访问,只需在您的项目中包含 spring-boot-starter-data-jpa 依赖项,就可以了。

2.Spring starter作用是什么

传统的做法:

在没有starter之前,假如我想要在Spring中使用jpa,那我可能需要做以下操作:

  • 在Maven中引入使用的数据库的依赖(即JDBC的jar);
  • 引入jpa的依赖;
  • 在xxx.xml中配置一些属性信息
  • 反复的调试直到可以正常运行

​ 需要注意的是,这里操作在我们*每次新建一个需要用到jpa的项目的时候都需要重复的做一次*。也许你在第一次自己建立项目的时候是在Google上自己搜索了一番,花了半天时间解决掉了各种奇怪的问题之后,jpa终于能正常运行了。有些有经验的人会在OneNote上面把这次建立项目的过程给记录下来,包括操作的步骤以及需要用到的配置文件的内容,在下一次再创建jpa项目的时候,就不需要再次去Google了,只需要照着笔记来,之后再把所有的配置文件copy&paste就可以了。

像上面这样的操作也不算不行,事实上我们在没有starter之前都是这么干的,但是这样做有几个问题:

  • 如果过程比较繁琐,这样一步步操作会增加出错的可能性
  • 不停地copy&paste不符合Don’t repeat yourself精神
  • 在第一次配置的时候(尤其如果开发者比较小白),需要花费掉大量的时间

使用Spring Boot Starter提升效率

​ starter的主要目的就是为了解决上面的这些问题。

​ starter的理念:starter会把所有用到的依赖都给包含进来,避免了开发者自己去引入依赖所带来的麻烦。需要注意的是不同的starter是为了解决不同的依赖,所以它们内部的实现可能会有很大的差异,例如jpa的starter和Redis的starter可能实现就不一样,这是因为starter的本质在于synthesize,这是一层在逻辑层面的抽象,也许这种理念有点类似于Docker,因为它们都是在做一个“包装”的操作,如果你知道Docker是为了解决什么问题的,也许你可以用Docker和starter做一个类比。

starter的实现:虽然不同的starter实现起来各有差异,但是他们基本上都会使用到两个相同的内容:ConfigurationProperties和AutoConfiguration。因为Spring Boot坚信“约定大于配置”这一理念,所以我们使用ConfigurationProperties来保存我们的配置,并且这些配置都可以有一个默认值,即在我们没有主动覆写原始配置的情况下,默认值就会生效,这在很多情况下是非常有用的。除此之外,starter的ConfigurationProperties还使得所有的配置属性被聚集到一个文件中(一般在resources目录下的application.properties),这样我们就告别了Spring项目中XML地狱。

starter的整体逻辑:

在这里插入图片描述

3.常用的starter

  1. spring-boot-starter
    这是Spring Boot的核心启动器,包含了自动配置、日志和YAML。

  2. spring-boot-starter-amqp
    通过spring-rabbit来支持AMQP协议(Advanced Message Queuing Protocol. 。

  3. spring-boot-starter-aop
    支持面向方面的编程即AOP,包括spring-aop和AspectJ。

  4. spring-boot-starter-artemis
    通过Apache Artemis支持JMS的API(Java Message Service API. 。

  5. spring-boot-starter-batch
    支持Spring Batch,包括HSQLDB数据库。

  6. spring-boot-starter-cache
    支持Spring的Cache抽象。

  7. spring-boot-starter-cloud-connectors
    支持Spring Cloud Connectors,简化了在像Cloud Foundry或Heroku这样的云平台上连接服务。

  8. spring-boot-starter-data-elasticsearch
    支持ElasticSearch搜索和分析引擎,包括spring-data-elasticsearch。

  9. spring-boot-starter-data-gemfire
    支持GemFire分布式数据存储,包括spring-data-gemfire。

  10. spring-boot-starter-data-jpa
    支持JPA(Java Persistence API. ,包括spring-data-jpa、spring-orm、Hibernate。

  11. spring-boot-starter-data-mongodb
    支持MongoDB数据,包括spring-data-mongodb。

  12. spring-boot-starter-data-rest
    通过spring-data-rest-webmvc,支持通过REST暴露Spring Data数据仓库。

  13. spring-boot-starter-data-solr
    支持Apache Solr搜索平台,包括spring-data-solr。

  14. spring-boot-starter-freemarker
    支持FreeMarker模板引擎。

  15. spring-boot-starter-groovy-templates
    支持Groovy模板引擎。

  16. spring-boot-starter-hateoas
    通过spring-hateoas支持基于HATEOAS的RESTful Web服务。

  17. spring-boot-starter-hornetq
    通过HornetQ支持JMS。

  18. spring-boot-starter-integration
    支持通用的spring-integration模块。

  19. spring-boot-starter-jdbc
    支持JDBC数据库。

  20. spring-boot-starter-jersey
    支持Jersey RESTful Web服务框架。

  21. spring-boot-starter-jta-atomikos
    通过Atomikos支持JTA分布式事务处理。

  22. spring-boot-starter-jta-bitronix
    通过Bitronix支持JTA分布式事务处理。

  23. spring-boot-starter-mail
    支持javax.mail模块。

  24. spring-boot-starter-mobile
    支持spring-mobile。

  25. spring-boot-starter-mustache
    支持Mustache模板引擎。

  26. spring-boot-starter-redis
    支持Redis键值存储数据库,包括spring-redis。

  27. spring-boot-starter-security
    支持spring-security。

  28. spring-boot-starter-social-facebook
    支持spring-social-facebook

  29. spring-boot-starter-social-linkedin
    支持pring-social-linkedin

  30. spring-boot-starter-social-twitter
    支持pring-social-twitter

  31. spring-boot-starter-test
    支持常规的测试依赖,包括JUnit、Hamcrest、Mockito以及spring-test模块。

  32. spring-boot-starter-thymeleaf
    支持Thymeleaf模板引擎,包括与Spring的集成。

  33. spring-boot-starter-velocity
    支持Velocity模板引擎。

  34. spring-boot-starter-web
    S支持全栈式Web开发,包括Tomcat和spring-webmvc。

  35. spring-boot-starter-websocket
    支持WebSocket开发。

  36. spring-boot-starter-ws
    支持Spring Web Services。
    Spring Boot应用启动器面向生产环境的还有2种,具体如下:

  37. spring-boot-starter-actuator
    增加了面向产品上线相关的功能,比如测量和监控。

  38. spring-boot-starter-remote-shell
    增加了远程ssh shell的支持。
    最后,Spring Boot应用启动器还有一些替换技术的启动器,具体如下:

  39. spring-boot-starter-jetty
    引入了Jetty HTTP引擎(用于替换Tomcat. 。

  40. spring-boot-starter-log4j
    支持Log4J日志框架。

  41. spring-boot-starter-logging
    引入了Spring Boot默认的日志框架Logback。

  42. spring-boot-starter-tomcat
    引入了Spring Boot默认的HTTP引擎Tomcat。

  43. spring-boot-starter-undertow

    引入了Undertow HTTP引擎(用于替换Tomcat. 。

07-2 SpringBoot2.x常见模板引擎讲解和官方推荐使用

  • JSP(后端渲染,消耗性能)
    • Java Server Pages 动态网页技术,由应用服务器中的JSP引擎来编译和执行,再将生成的整个页面返回给客户端;
    • 可以写java代码
    • 持表达式语言(el、jstl)
    • 内建函数
    • JSP->Servlet(占用JVM内存)permSize
    • javaweb官方推荐
    • springboot不推荐
  • Freemarker
    • FreeMarker Template Language(FTL) 文件一般保存为 xxx.ftl
    • 严格依赖MVC模式,不依赖Servlet容器(不占用JVM内存)
    • 内建函数
  • Thymeleaf (主推)
    • 轻量级的模板引擎(负责逻辑业务的不推荐,解析DOM或者XML会占用多的内存)
    • 可以直接在浏览器中打开且正确显示模板页面

07-3 SpringBoot2.x整合模板引擎freemarker实战

1.Freemarker相关依赖

<dependencies>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-freemarker</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-test</artifactId>
            <scope>test</scope>
        </dependency>
    </dependencies>

2.application.properties的配置

spring.resources.static-locations=classpath:/META-INF/resources/,classpath:/resources/,classpath:/static/,\
  classpath:/public/,classpath:/templates/,

# 属性
server.name = "lcz"
server.domain = "lcz.com"

# 是否开启thymeleaf缓存,本地为false,生产建议为true
spring.freemarker.cache=false

spring.freemarker.charset=UTF-8
spring.freemarker.allow-request-override=false
spring.freemarker.check-template-location=true

#类型
spring.freemarker.content-type=text/html

spring.freemarker.expose-request-attributes=true
spring.freemarker.expose-session-attributes=true

#文件后缀
spring.freemarker.suffix=.ftl
#路径
spring.freemarker.template-loader-path=classpath:/templates/

3.后端逻辑代码

domain/ServerSettings

package com.lcz.spring_demo13.domain;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * @author : codingchao
 * @date : 2021-11-23 21:00
 * @Description:
 **/
@Component
@PropertySource({"classpath:application.properties"})
@ConfigurationProperties(prefix = "server")
public class ServerSettings {
    private String name;
    private String domain;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDomain() {
        return domain;
    }

    public void setDomain(String domain) {
        this.domain = domain;
    }
}

controller/FreemakerController

package com.lcz.spring_demo13.controller;

import com.lcz.spring_demo13.domain.ServerSettings;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @author : codingchao
 * @date : 2021-11-23 21:05
 * @Description:
 **/
@Controller
@RequestMapping("/freemaker")
public class FreemakerController {
    @Autowired
    private ServerSettings serverSettings;

    @GetMapping("/api")
    public String index(ModelMap modelMap){
        modelMap.addAttribute("setting",serverSettings);
        return "fm/index"; //不用加后缀,在配置文件里面指定了后缀
    }
}

4.前端逻辑代码

resources/templates/fm/index.ftl

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
<h1>freemaker整合</h1>

<h1> ${setting.name} </h1>
<h1> ${setting.domain} </h1>

</body>
</html>

5.展示效果

在这里插入图片描述

07-4 SpringBoot2.x整合模板引擎thymeleaf

1.Thymeleaf相关依赖

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-thymeleaf</artifactId>
</dependency>

2.application.properties

spring.resources.static-locations=classpath:/META-INF/resources/,classpath:/resources/,classpath:/static/,\
  classpath:/public/,classpath:/templates/,

# 属性
server.name = "lcz"
server.domain = "lcz.com"

## 是否开启thymeleaf缓存,本地为false,生产建议为true
#spring.freemarker.cache=false
#
#spring.freemarker.charset=UTF-8
#spring.freemarker.allow-request-override=false
#spring.freemarker.check-template-location=true
#
##类型
#spring.freemarker.content-type=text/html
#
#spring.freemarker.expose-request-attributes=true
#spring.freemarker.expose-session-attributes=true
#
##文件后缀
#spring.freemarker.suffix=.ftl
##路径
#spring.freemarker.template-loader-path=classpath:/templates/


#开发时关闭缓存,不然没法看到实时页面
spring.thymeleaf.cache=false
spring.thymeleaf.mode=HTML5
#前缀
spring.thymeleaf.prefix=classpath:/templates/
#编码
spring.thymeleaf.encoding=UTF-8
#类型
spring.thymeleaf.content-type=text/html
#名称的后缀
spring.thymeleaf.suffix=.html

3.后端逻辑代码

controller/ThymleafController.java

package com.lcz.spring_demo13.controller;

import com.lcz.spring_demo13.domain.ServerSettings;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;


@Controller
@RequestMapping("/thymeleaf")
public class ThymeleafController {

	@Autowired
	private ServerSettings setting;

	@GetMapping("hello")
	public String index(){
		return "index";  //不用加后缀,在配置文件里面已经指定了后缀
	}

	@GetMapping("info")
	public String admin(ModelMap modelMap){
		modelMap.addAttribute("setting", setting);
		return "admin/info";  //不用加后缀,在配置文件里面已经指定了后缀
	}
}

4.前端代码

resources/templates/tl/index.html

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
模板引擎整合thymeleaf
<h5>直接访问</h5>
</body>
</html>

resources/templates/tl/admin/info.html

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
模板引擎整合thymeleaf  admin/info.html
<h1 th:text="${setting.name}">测试内容</h1>
</body>
</html>

5.展示效果

在这里插入图片描述

在这里插入图片描述

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

【Spring Boot 2.0学习之旅-07】SpringBoot常用starter介绍和整合模板Freemaker、Thymeleaf 的相关文章

  • 【history】如何丝滑地记录Linxu命令行操作历史?

    对于运维来讲 xff0c history命令应该说是用到最多的了 xff0c 尤其是一些老旧的系统 xff0c 一些历史命令更多时候 xff0c 相当于是运维手册 xff0c 但是history命令有时候也有很多不方便的地方 今天介绍一种方
  • 【CPU】如何正确理解 CPU 使用率和平均负载的关系?

    什么是 CPU 使用率 xff1f CPU 使用率就是 CPU 非空闲态运行的时间占比 xff0c 它反映了 CPU 的繁忙程度 比如 xff0c 单核 CPU 1s 内非空闲态运行时间为 0 8s xff0c 那么它的 CPU 使用率就是
  • 【分布式】日志技术

    日志技术是宕机恢复的主要技术之一 日志技术最初使用在数据库系统中 严格来说日志技术不是一种分布式系统的技术 xff0c 但在分布式系统的实践中 xff0c 却广泛使用了日志技术做宕机恢复 xff0c 甚 至如BigTable 等系统将日志保
  • 【故障诊断】【git】git只能下载一个分支,怎么办?

    很多朋友可能都会遇到一个问题 xff0c 就是远程的git明明有两个分支 xff0c 但是却只能下载一个 xff0c 这样该怎么处理呢 xff1f 首先要澄清 xff0c git clone确实只能下载一个分支 xff0c 我们只能先把ma
  • 23种设计模式

    目录 创建型 1 Factory Method xff08 工厂方法 xff09 2 Abstract Factory xff08 抽象工厂 xff09 3 Builder xff08 建造者 xff09 4 Prototype xff08
  • Docker的asp.net core应用部署系列目录(完结)

    第一章 实验基础环境 本系列将用VirtualBox虚拟机安装ubuntu desktop 18 版本进行演示 xff0c 安装方式自行探索 xff0c 亦可购买各种云的linux服务器 章节间多少有依赖 xff0c 请根据自身情况跳过熟悉
  • Docker的asp.net core应用部署系列—— docker运行asp.net core应用镜像

    本系列目录请看这里 https blog csdn net michel4liu article details 80819510 我们接着上篇 xff0c 已经编译好镜像 xff0c 本篇将介绍两种启动方式 xff0c 交互模式启动和后台
  • Docker的asp.net core应用部署系列——进入正在运行的docker容器里面

    本系列目录请看这里 https blog csdn net michel4liu article details 80819510 我们之前已经可以通过交互或后台方式启动一个容器 xff0c 有时我们需要进入docker里面看一些log或者
  • DATAX:MongoDB增量数据写入到mysql中

    项目场景 xff1a 简述 xff1a 使用DATAX进行Mongo的数据抽取 xff0c 然后写入到mysql中 xff0c 其中会牵涉到全量数据的写入和增量数据的写入 全量 数据的写入我们只需要正常写JSON模板即可 xff0c 使用c
  • 无人机自动驾驶软件系列 E04

    无人机自动驾驶软件系列 E04 xff1a 深度估计 xff0c 八叉树地图以及路径规划 详细配置https gaas gitbook io guide software realization build your own autonom
  • Window11安装如何跳过TPM2.0这一步

    最近想体验一把window11 xff0c 怎奈自己的电脑太老了 xff0c 显示不能安装 xff0c 网上大佬们都说是tpm2 0的问题 xff0c 顺着这个角度 xff0c 找到了一个国外大神的解决办法 1 在出现 Win11 会提示
  • 修改已运行Docker容器的端口映射

    方法一 删除容器 xff0c 重新新建容器多加一个 p端口映射即可 方法二 修改容器配置文件 重启docker服务 模拟创建运行中的容器 span class token punctuation span root 64 redmine t
  • e指数函数

    使用win自带的计算器 xff0c 进行以e为底的指数函数进行运算时 xff0c 发现计算器上的EXP键只能用做表示10的多少次方 xff0c 如5e3 xff0c 指的是5乘以10的3次方 xff0c 及5000 查了一下 xff0c 也
  • xsens惯导在ROS下输出汇总

    rostopic list 分别记录下每个对应的信息 xff1a 1 rostopic echo diagnostics header seq 454 stamp secs 1572609754 nsecs 307622909 frame
  • c 编程中extern关键字 使用跨文件全局变量

    我们知道 xff0c 程序的编译单位是源程序文件 xff0c 一个源文件可以包含一个或若干个函数 在函数内定义的变量是局部变量 xff0c 而在函数之外定义的变量则称为外部变量 xff0c 外部变量也就是我们所讲的全局变量 它的存储方式为静
  • 年度回忆录(?——2011.01)

    这是在CSDN 上的第一篇总结 xff08 或者说是回忆录 xff09 xff0c 个人认为 xff1a 总结 xff0c 尤其是年度总结是十分必要的 她可以很好的映射出自己以往的不足 xff0c 并为自己下一步的学习指明方向 以前在网易上
  • 使用JMF实现java写自己的视频播放器

    JMF这个多媒体开发框架太牛了 xff0c 简单的几句代码就能实现一个视频播放器的开发 xff0c 厉害 xff0c 就是支持的格式少了一些 xff0c 没关系 xff0c 这个视频播放器可以播放mpg xff0c avi fvl等等 xf
  • 相机标定:关键点法 vs 直接法

    相机标定中最常见的方法是关键点法 xff0c 比如 OpenCV 和 MatLab 中使用棋盘格 圆阵列等二维图案进行标定 xff0c 这上面的棋盘格角点和圆心就是所谓的关键点 虽然关键点法有很多优点 xff0c 但在某些情况下容易遇到标定
  • 8本推荐游戏开发书籍

    很多刚刚接触游戏开发的朋友经常问我 xff1a 如何开始学习游戏开发 xff1f 我从事游戏开发行业很多年了 xff0c 坦率地讲 xff0c 开发游戏充满挑战性 xff0c 需要开发人员具备大量的技能与积极的创新精神 希望这篇小文能帮助朋
  • Maxwell启动停止脚本

    Maxwell启动停止脚本 进入 maxwell bin nbsp 直接运行下面的内容 生成脚本 bin bash description maxwell File maxwell Description Starts and stops

随机推荐

  • Epoll 的time_out参数引发的cpu占用问题

    转自 xff1a https www cnblogs com Jimmy104 p 5258205 html 针对自己写的一个服务器网络引擎Engine 文章后面附上源码 使用epoll 刚刚开始时候发现占用CPU 特别高 xff0c 但是
  • 【周志华机器学习】集成学习

    第八章 集成学习 个体与集成BoostingBagging 与随机森林Bagging随机森林 结合策略平均法投票法学习法 多样性 个体与集成 集成学习通过构建并结合多个学习器来完成学习任务 xff0c 也被称为多分类器系统 集成学习的一般结
  • 用户句柄表的遍历

    私有句柄表 HANDLE TABLE ENTRY的Object直接指向 OBJECT HEADER不用减 span class token macro property span class token directive hash spa
  • 树莓派安装后--安装必要软件(个人版)

    树莓派安装后 安装必要软件 xff08 个人版 xff09 查看是哪个版本 lsb release a 查看raspbian是哪个版本 getconf LONG BIT 查看系统位数 uname a kernel 版本 opt vc bin
  • 固定翼姿态控制流程

    固定翼控制流程 主文件夹 子文件 fw att control位于src moudle文件夹下 fw att control main c 主文件 fw att control params c 主文件参数 CMakeList attitu
  • 固定翼位置控制_Tecs

    Tecs在位置控制中主要控制纵向的高度 xff0c 因为升降舵可以控制飞机的高度 xff0c 油门可以控制飞机的速度 xff0c 但是单单通过升降舵改变高度会使速度下降或者上升 xff0c 单单通过油门改变速度会使高度改变 xff0c 所以
  • 固定翼位置控制_L1

    L1算法控制航向 飞机从现在位置到设定位置 xff0c 需要进行转弯 转弯需要一个横向的加速度来改变速度的方向 这里横向加速度的计算公式 a 61 V2R 又因为R 61 2 sin L1 可得 a 61 2 V2L1 sin L1是现在位
  • 存储过程懂不懂

    存储过程的官方定义是这么说的 xff1a 存储过程 xff08 Stored Procedure xff09 是一组为了完成特定功能的 SQL 语句集 xff0c 经编译后存储在数据库中 用户通过指定存储过程的名字并给出参数 xff08 如
  • PX4多旋翼位置控制

    多悬翼的位置控制由内外环控制 xff0c 外环P控制作用于位置差 xff0c 产生期望速度 xff0c 内环PID作用于速度差 xff0c 产生期望油门 xff0c 然后将油门解算成期望姿态 外环位置控制的三种控制源 1 Manual 手动
  • PX4混控器定义

    PX4混控 把输入指令 分配给电机以及舵机的执行器 信号传递 Actuators id 61 ORB ID actuator controls 0 0号控制组 Orb publish actuators id actuators 0 pub
  • Linux--Ubuntu18.04交叉编译链;多窗口终端;彻底删除不用的虚拟机镜像

    文章目录 建立共享文件夹交叉编译查看是否安装了交叉编译工具安装交叉编译工具链退出root模式 多窗口终端 Terminator彻底删除不用的虚拟机镜像 建立共享文件夹 实现windows系统与虚拟机中的ubuntu之间的文件共享 PC机新建
  • 准确率,召回率,mAP(mean average precision)解释

    准确率Precision 召回率Recall 其实这个翻译相当蛋疼 recall最合理的翻译应该是 查全率 而Precision的最合理的翻译应该是查准率 这样就很容易理解了 xff0c 假设一个班级有10个学生 xff0c 5男5女 你用
  • Android 开发使用 Java 8 中Lambda 表达式功能

    简介 Android开发支持所有 Java 7 语言功能 xff0c 以及一部分 Java 8 语言功能 xff08 具体因平台版本而异 xff09 注意 xff1a 在开发应用时 xff0c 可以选择使用 Java 8 语言功能 您可以将
  • 浅谈 for循环

    浅谈for循环 xff0c for循环习题讲解 文章多看几遍吧 相信你一定会收获不少哇 什么是循环 xff1f 我认为循环就是把一个步骤一直重复执行的操作 如果没有终止条件 xff0c 那么这一步骤就会一直执行下去 xff0c 直到地老天昏
  • 给Jetson Nano更换eMMC闪存(扩容)

    7月4日更新 xff1a 添加了有关问题的解释与探讨 xff08 文末 xff0c 下一篇文章 xff09 7月5日更新 xff1a 添加了效果图 xff08 文末 xff09 7月8日更新 xff1a 添加了视频 b站 xff1a BV1
  • Linux下安装Anaconda3,这个教程一定要看!

    前言 大家好 xff0c 我是爱写Bug的麦洛 由于工作需要 xff0c 要为客户搭建Python开发环境 作为从来没有接触过Python的小白 xff0c 为了完成任务 xff0c 也是破费周折 xff0c 请教了身边做Python的朋友
  • Stm32F303进入bootloader重新烧录程序

    STM32F3飞控或开发板无法进入bootloader重新进行烧录固件程序的解决方案 F3系列的MCU无法进入bootloader 前提准备开始F4和F3的不同 F3系列的MCU无法进入bootloader 前几日找了一块F3的飞控板 刷入
  • 存储过程进阶(vb.net+SQL Server2008环境)

    写过一篇 存储过程入门 的博客 xff0c 那仅仅是入门 xff0c 下面和大家一起深入学习存储过程 xff08 也许以后还会有更深入 xff09 以经典的注册为例子 xff0c 篇幅有限只写了核心部分 xff0c 其他略过 无参数无返回值
  • 【Spring Boot 2.0学习之旅-06-4】Servlet3.0注解的自定义原生Listener监听器实战

    第六章 SpringBoot拦截器实战和Servlet3 0自定义Filter和Listener 06 4 SpringBoot2 x自定义拦截器实战以及新旧配置对比 1 过滤器与拦截器的区别 过滤器与拦截器触发时机不一样 xff0c 过滤
  • 【Spring Boot 2.0学习之旅-07】SpringBoot常用starter介绍和整合模板Freemaker、Thymeleaf

    第七章 SpringBoot常用starter介绍和整合模板Freemaker thymeleaf 07 1 SpringBoot Starter讲解 1 Spring starter是什么 starter是SpringBoot中的一个新发