![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
SpringBoot
文章平均质量分 76
路人寅z
一个95后程序媛的学习之路......
展开
-
初识SpringBoot之配置文件(二)——配置文件值注入
目录 1、注入配置文件值-@ConfigurationProperties 2、properties配置文件的编码问题 3、注入配置文件值-@Value方法 4、@Value获取值和@ConfigurationProperties获取值比较 1、注入配置文件值-@ConfigurationProperties yml配置文件: person: lastName: lurenyin age: 20 student: true birth: 1999/06/28 map.原创 2021-03-12 17:19:26 · 301 阅读 · 0 评论 -
初识SpringBoot之配置文件(一)——yaml
对于刚接触SpringBoot的小伙伴们,应该都知道SpringBoot使用一个全局的配置文件,配置文件名是固定的; ●application.properties ●application.yml 配置文件的作用:修改SpringBoot自动配置的默认值。 本篇文章先主要介绍yaml。 一 YAML简介 YAML 是 "YAML Ain't a Markup Language"的递归缩写。以前的配置文件大多都使用的是 xxx.xml文件,而yaml是以数据为中心,比json、xml等更适合做配原创 2021-03-12 16:51:04 · 132 阅读 · 0 评论