亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

spring mvc 接收數據 數組+pojo

spring mvc 接收數據 數組+pojo

JVM
汪汪一只貓 2018-10-24 19:27:20
Controller@RequestMapping("ask")@ResponseBodypublic RobotResponse get(RobotRequest robotRequest){RobotRequest.javapublic class RobotRequest implements java.io.Serializable {private cn.eastrobot.www.ws.RobotServiceEx.UserAttribute[] attributes;UserAttribute.javapublic class UserAttribute implements java.io.Serializable {private java.lang.String name;private java.lang.String value;問:前臺如何傳值可以封裝到 robotRequest中需要前臺傳值,經數據封裝到 robotRequest的attributes中筆者沒有辦法
查看完整描述

1 回答

?
智慧大石

TA貢獻1946條經驗 獲得超3個贊

筆者已經找辦法
localhost:8080/ask?question=你好&userId=litong&attributes[0].name=platform&attributes[0].value=weixin
不需要使用雙引號將 值 引起來

查看完整回答
反對 回復 2018-10-24
  • 1 回答
  • 0 關注
  • 1009 瀏覽

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號