@RequestBody

https://blog.csdn.net/justry_deng/article/details/80972817

https://www.cnblogs.com/jimmy-c/p/4142441.html

https://blog.csdn.net/micro_hz/article/details/53157738

@RequestParam 

https://www.cnblogs.com/zeroingToOne/p/8992746.html

@PathVariable

https://www.cnblogs.com/fangpengchengbupter/p/7823493.html

 

 mvn clean install -Dmaven.test.skip=true -U

https://blog.csdn.net/javahighness/article/details/84666587

https://blog.csdn.net/keith_walker/article/details/78853811

 

 

@RequestBody、@RequestParam 、@PathVariable、mvn

 

 

string的json格式

https://www.cnblogs.com/rgever/p/9126444.html

@RequestMapping(value = ParamScriptApis.PARAM_SCRIPT_VERSION_LAST_VERSIONS, method = RequestMethod.POST)
    @ResponseBody
    public Map<String, Integer> getParamScriptLastVersionByResourceIds(
            final HttpServletRequest request,
            final HttpServletResponse response,
            @RequestBody String resourceIdsStr) {
        List<String> resourceIds = JsonUtils.readValueFromJsonStr(resourceIdsStr, List.class, String.class);
        Map<String,Integer> versions = mParamScriptDb.getParamScriptLastVersionByResourceIds(resourceIds);
        return versions;

@RequestBody、@RequestParam 、@PathVariable、mvn

 

SpringMVC中的RequestBody自动注入List!!!

  @RequestMapping(value = ParamScriptApis.PARAM_SCRIPT_VERSION_LAST_VERSIONS, method = RequestMethod.POST)
    @ResponseBody
    public Map<String, Integer> getParamScriptLastVersionByResourceIds(
            final HttpServletRequest request,
            final HttpServletResponse response,
            @RequestBody List<String> resourceIds) {
        Map<String,Integer> versions = mParamScriptDb.getParamScriptLastVersionByResourceIds(resourceIds);
        return versions;
    }

@RequestBody、@RequestParam 、@PathVariable、mvn

 

 

 

 

 

 

 

 

相关文章: