/** * Creates a new {@code SudoRetrieveThingsResponse} from a JSON string. * * @param jsonString the JSON string of which a new SudoRetrieveThingsResponse instance is to be created. * @param dittoHeaders the optional command headers of the request. * @return the {@code SudoRetrieveThingsResponse} which was created from the given JSON string. * @throws NullPointerException if {@code dittoHeaders} is {@code null}. * @throws DittoJsonException if the passed in {@code jsonString} was {@code null}, empty or not in the expected * 'SudoRetrieveThingsResponse' format. */ public static SudoRetrieveThingsResponse fromJson(final String jsonString, final DittoHeaders dittoHeaders) { final JsonObject jsonObject = DittoJsonException.wrapJsonRuntimeException(() -> JsonFactory.newObject(jsonString)); return fromJson(jsonObject, dittoHeaders); }
/** * Creates a new {@code SudoRetrieveThingsResponse} from a JSON string. * * @param jsonString the JSON string of which a new SudoRetrieveThingsResponse instance is to be created. * @param dittoHeaders the optional command headers of the request. * @return the {@code SudoRetrieveThingsResponse} which was created from the given JSON string. * @throws NullPointerException if {@code dittoHeaders} is {@code null}. * @throws DittoJsonException if the passed in {@code jsonString} was {@code null}, empty or not in the expected * 'SudoRetrieveThingsResponse' format. */ public static SudoRetrieveThingsResponse fromJson(final String jsonString, final DittoHeaders dittoHeaders) { final JsonObject jsonObject = DittoJsonException.wrapJsonRuntimeException(() -> JsonFactory.newObject(jsonString)); return fromJson(jsonObject, dittoHeaders); }