作业帮 > 综合 > 作业

Spring mvc 中model.addAttribute("student",student)请问这句是什么意思

来源:学生作业帮 编辑:百度作业网作业帮 分类:综合作业 时间:2024/05/16 18:48:40
Spring mvc 中model.addAttribute("student",student)请问这句是什么意思
Spring mvc 中model.addAttribute(
按照spring一般的编码习惯,model 应该是contrller里面的Map结构吧.Map里面添加key=“student”,value=“student对象”的意思,最后把这个model返回一个jsp,在jsp页面上就能得到这个student对象了!