0
例如我的JSON數據是這樣的:如何在提取之前將JValue變平?
[{ "name": "Foo", "verified": {"email": true, "mobile": false} }, { "name": "Bar", "verified": {"email": false, "mobile": false} }]
隨着json4s我可以得到一個JArray,提取到用戶(案例類)的列表,我要處理的JArray前 - 我要弄平verified
場因此用戶會像:
case class (name: String, emailVerified: Boolean, mobileVerified: Boolean)
我怎樣才能做到這一點?