
Goods goods = restTemplate.getForObject(url, Goods.class);
但是获取一个list 或者map集合怎么弄呢?
直接漏旁取就OK.
List返仿橡goodsList = restTemplate.getForObject(url, List.class);
参大中考: http : / / thekspace.com/home/component/content/article/57-restful-clients-in-spring-3.html
List list = service.getList();
service中的list方法是你自己写,在dao层宏贺也要自己写闷绝没个放回list的方蚂纳法的啊