You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
异常如下:
java.lang.IllegalArgumentException: argument type mismatch
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.alibaba.fastjson.parser.deserializer.FieldDeserializer.setValue(FieldDeserializer.java:90)
at com.alibaba.fastjson.JSONPath.setPropertyValue(JSONPath.java:2254)
at com.alibaba.fastjson.JSONPath$PropertySegement.setValue(JSONPath.java:1298)
at com.alibaba.fastjson.JSONPath.set(JSONPath.java:284)
at com.alibaba.fastjson.JSONPath.set(JSONPath.java:349)
测试代码如下:
public void test() {
Person per = new Person();
System.out.println("原生Person:" + per.toString());
String path = "$.nose.name";
String value = "noseName";
Object obj = value;
JSONPath.set(per, path, obj);
}
The text was updated successfully, but these errors were encountered:
版本1.2.16、1.2.23均有该问题
异常如下:
java.lang.IllegalArgumentException: argument type mismatch
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.alibaba.fastjson.parser.deserializer.FieldDeserializer.setValue(FieldDeserializer.java:90)
at com.alibaba.fastjson.JSONPath.setPropertyValue(JSONPath.java:2254)
at com.alibaba.fastjson.JSONPath$PropertySegement.setValue(JSONPath.java:1298)
at com.alibaba.fastjson.JSONPath.set(JSONPath.java:284)
at com.alibaba.fastjson.JSONPath.set(JSONPath.java:349)
测试代码如下:
public void test() {
Person per = new Person();
System.out.println("原生Person:" + per.toString());
String path = "$.nose.name";
String value = "noseName";
Object obj = value;
JSONPath.set(per, path, obj);
}
The text was updated successfully, but these errors were encountered: