问题描述
如何将以下 json 解组为 golang 结构
{
"VM": {
"0": {
"component": "A","name": "hostname1","hostname": "hostname1","role": "NODE","this": true,"type": "t1"
},"1": {
"component": "B","name": "hostname2","hostname": "hostname2","role": "role2","type": "t2"
},"2": {
"component": "C","name": "hostname3","hostname": "hostname3","role": "role3","type": "t3"
},"n": { //this can go upto n levels
"component": "N","name": "hostnamen","hostname": "hostnamen","role": "rolen","type": "tn"
}
}
}
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)