标签:default value str stp dao层 xxx variable lse efault
//@PathVariable可以用来映射URL中的占位符到目标方法的参数中 @RequestMapping("/testPathVariable/{id}") public String testPathVariable(@PathVariable("id") Integer id){ System.out.println("testPathVariable:"+id); return SUCCESS; }
@RequestMapping("/user") @ResponseBody public String getUserBlog(@RequestParam("id") int blogId) { return "blogId = " + blogId; }
@RequestMapping("/user") @ResponseBody public String getUserBlog(@RequestParam(value="id",require=false,default=‘0‘) int blogId) { return "blogId = " + blogId; }
标签:default value str stp dao层 xxx variable lse efault
原文地址:https://www.cnblogs.com/linhuanjie/p/9608951.html