Fork me on GitHub

随笔分类 -  RestTemplate

摘要:嗷嗷待哺的controller(被调用provider的controller方法) //测试get少量参数 @RequestMapping(value = "detailsGetD",method = RequestMethod.GET) public String test05(Integer i 阅读全文
posted @ 2020-02-19 22:28 威威超酷 阅读(7835) 评论(0) 推荐(0) 编辑
摘要:废话少说,给你们看代码: //provide的controller @ResponseBody @RequestMapping(value = "details",method = RequestMethod.GET) public PageInfo<Detail> queryByTitle(@Re 阅读全文
posted @ 2020-02-18 22:53 威威超酷 阅读(1304) 评论(0) 推荐(0) 编辑
摘要:最近使用Spring 的 RestTemplate 工具类请求接口的时候发现参数传递的一个坑,也就是当我们把参数封装在Map里面的时候,Map 的类型选择。 使用RestTemplate post请求的时候主要可以通过三种方式实现 1、调用postForObject方法 2、使用postForEnt 阅读全文
posted @ 2020-02-18 14:55 威威超酷 阅读(22502) 评论(4) 推荐(7) 编辑

点击右上角即可分享
微信分享提示