是否有可能在Fiware中创建一个实体,其中特定属性将作为数组发送?那样的东西?在房间内有多个压力传感器,我希望在一次更新中收到它们?!
所以这基本上是创建实体
{
"id": "Room1",
"type": "Room",
"temperature": {
"value": 23,
"type": "Float"
},
"pressure": {
"value": 720,
"type": "Integer"
}
}
我希望收到一条更新消息的更新,其中包含此“实体”中的所有压力信息
{
"id": "Room1",
"type": "Room",
"temperature": {
"value": 23,
"type": "Float"
},
"pressure": [{
"value": 720,
"type": "Integer"
},
{
"value": 500,
"type": "Integer"
},
]
}
提前致谢!
-pd
1 回答
您建议的不完全相同,但您可以在数组中包含所有值 . 像这样的东西:
或者,如果您需要每个类型的类型信息,您可以尝试: