Spring Boot 中 Controller 使用

1.属性配置

2.Controller使用

2.@PathVariable 与 @RequestParam 的区别

(1)@PathVariable

(2)@RequestParam

扫描二维码关注公众号,回复: 4735890 查看本文章

3.@GetMapping 和 @PostMapping 简写

@RequestMapping(value="/say", method=RequestMethod.GET)
// 等同于
@GetMapping(value="/say")

猜你喜欢

转载自www.cnblogs.com/crazycode2/p/10204780.html
今日推荐