风格

springmvc/springboot开发restful API, 使用MockMVC 编写测试用例

  非rest的url写法: 查询 GET /user/query?name=tom 详情 GET /user/getinfo?id=1 创建 POST /user/create?name=tom 修改 POST /user/update?id=1&name=tom 删除 GET /user/delete?id=1   rest风格的写法...

SpringMVC注解式开发之接收请求参数

逐个接收(涉及注解@RequestParam) index.jsp的name必须和后端的名字一致,第一种才可以实现。   以对象形式整合接收   域属性参数的接收   数组或集合参数的接收 restfull风格传参(涉及注解@PathVariable) 接收json字符串(涉及注解@RequestBody,注册mvc注解驱...