public void extract(JSONPath path, DefaultJSONParser parser, Context context) {
            if (context.eval) {
                Object object = parser.parse();
                if (deep) {
                    List<Object> values = new ArrayList<Object>();
                    if (objectOnly) {
                        path.deepGetObjects(object, values);
                    } else {
                        path.deepGetPropertyValues(object, values);
                    }
                    context.object = values;
                    return;
                }

                if (object instanceof JSONObject) {
                    Collection<Object> values = ((JSONObject) object).values();
                    JSONArray array = new JSONArray(values.size());
                    array.addAll(values);
                    context.object = array;
                    return;
                } else if (object instanceof JSONArray) {
                    context.object = object;
                    return;
                }
            }

            throw new JSONException("TODO");
        }
@since 1.2.51
@param json
@param path
@return
src/main/java/com/alibaba/fastjson/JSONPath.java