10、JSR303校验
首先需要在Bean类体上加上注解@Validated
然后在Bean的一些属性上面家=加上合适的注解,比如:
@Email
@NotNull
…
正则表达式:@Pattern
这个正则表达式是万能的。
springboot的多环境配置:active
推崇使用yml写配置文件。
Springboot2狂神的学习第2天(2021-12-14)
阅读 83
2022-11-17
首先需要在Bean类体上加上注解@Validated
然后在Bean的一些属性上面家=加上合适的注解,比如:
@Email
@NotNull
…
正则表达式:@Pattern
这个正则表达式是万能的。
springboot的多环境配置:active
推崇使用yml写配置文件。
相关推荐
精彩评论(0)