X-Git-Url: https://code.wpia.club/?p=gigi.git;a=blobdiff_plain;f=lib%2Fjson%2Forg%2Fjson%2FJSONArray.java;h=afe78e672db7541cd31b537084c79d4456ec63dc;hp=776a2bd05c685647da9d1ef9eb29d62ebe53c7fa;hb=5bc356d76024b91d1b86d3cd84f205636a22eed2;hpb=d4c3fe1597460bfe87b9014a85cea596fdac1987 diff --git a/lib/json/org/json/JSONArray.java b/lib/json/org/json/JSONArray.java index 776a2bd0..afe78e67 100644 --- a/lib/json/org/json/JSONArray.java +++ b/lib/json/org/json/JSONArray.java @@ -959,46 +959,6 @@ public class JSONArray implements Iterable { } return this; } - - /** - * Creates a JSONPointer using an intialization string and tries to - * match it to an item within this JSONArray. For example, given a - * JSONArray initialized with this document: - *
-     * [
-     *     {"b":"c"}
-     * ]
-     * 
- * and this JSONPointer string: - *
-     * "/0/b"
-     * 
- * Then this method will return the String "c" - * A JSONPointerException may be thrown from code called by this method. - * - * @param jsonPointer string that can be used to create a JSONPointer - * @return the item matched by the JSONPointer, otherwise null - */ - public Object query(String jsonPointer) { - return new JSONPointer(jsonPointer).queryFrom(this); - } - - /** - * Queries and returns a value from this object using {@code jsonPointer}, or - * returns null if the query fails due to a missing key. - * - * @param jsonPointer the string representation of the JSON pointer - * @return the queried value or {@code null} - * @throws IllegalArgumentException if {@code jsonPointer} has invalid syntax - */ - public Object optQuery(String jsonPointer) { - JSONPointer pointer = new JSONPointer(jsonPointer); - try { - return pointer.queryFrom(this); - } catch (JSONPointerException e) { - return null; - } - } /** * Remove an index and close the hole.