请问是否可以在一个方法上使用两个post和get注释? @RequestMapping(value = "/testonly", method = RequestMethod.GET, RequestMethod.POST) public String getSomething(){ }
method 字段是一个数组,所以我期望这个可以工作:@RequestMapping(value = "/testonly", method = { RequestMethod.GET, RequestMethod.POST })