| | |
| | | .build(), |
| | | 2); |
| | | |
| | | while (true) { |
| | | reply = (Map<String, Object>) reply.get(value.getKey()); |
| | | if (value.getValue() instanceof JsonNode) { |
| | | break; |
| | | } |
| | | value = (Map.Entry) value.getValue(); |
| | | } |
| | | |
| | | SetReply setReply = objectMapper.convertValue(reply, SetReply.class); |
| | | if (SetReplyStatusResultEnum.SUCCESS.getVal() != setReply.getResult()) { |
| | | throw new RuntimeException("Failed to set " + value.getKey() + "; Error Code: " + setReply.getResult()); |
| | | } |
| | | // 接收返回信息在serviceReply中,订阅thing/product/7CTDLCE00A1UPE/property/set_reply上报的信息,此处不处理 |
| | | // while (true) { |
| | | // reply = (Map<String, Object>) reply.get(value.getKey()); |
| | | // if (value.getValue() instanceof JsonNode) { |
| | | // break; |
| | | // } |
| | | // value = (Map.Entry) value.getValue(); |
| | | // } |
| | | // SetReply setReply = objectMapper.convertValue(reply, SetReply.class); |
| | | // if (SetReplyStatusResultEnum.SUCCESS.getVal() != setReply.getResult()) { |
| | | // throw new RuntimeException("Failed to set " + value.getKey() + "; Error Code: " + setReply.getResult()); |
| | | // } |
| | | |
| | | } |
| | | |