Parses one or more tree rules @return A list of one or more rules @throws JSONException if parsing failed @throws BadRequestException if the content was missing or parsing failed
()
| 425 | * @throws BadRequestException if the content was missing or parsing failed |
| 426 | */ |
| 427 | public List<TreeRule> parseTreeRulesV1() { |
| 428 | final String json = query.getContent(); |
| 429 | if (json == null || json.isEmpty()) { |
| 430 | throw new BadRequestException(HttpResponseStatus.BAD_REQUEST, |
| 431 | "Missing message content", |
| 432 | "Supply valid JSON formatted data in the body of your request"); |
| 433 | } |
| 434 | |
| 435 | return JSON.parseToObject(json, TR_TREE_RULES); |
| 436 | } |
| 437 | |
| 438 | /** |
| 439 | * Parses a tree ID and optional list of TSUIDs to search for collisions or |
nothing calls this directly
no test coverage detected