- 用实体类接收
测试实体类
public class TestEntity {
private String name;
private Integer age;
// getter setter toString
}
Controller代码
@PostMapping("/testSend")
public void testSend(TestEntity testEntity) {
System.out.println(testEntity);
}
标签:实体类,RequestParam,Spring,private,testEntity,Controller,TestEntity
From: https://www.cnblogs.com/yorkey/p/16739565.html