From c3df34ebb63acebdd59d049d2103f7d5fcac4dae Mon Sep 17 00:00:00 2001 From: sinodzh <”DUZHIHAO@kingsoft.com“> Date: Fri, 12 May 2023 17:44:42 +0800 Subject: [PATCH] improve scala compile support #1470 --- .../main/java/com/alibaba/fastjson2/JSONObject.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/core/src/main/java/com/alibaba/fastjson2/JSONObject.java b/core/src/main/java/com/alibaba/fastjson2/JSONObject.java index a0c3d810a7..b8063112e2 100644 --- a/core/src/main/java/com/alibaba/fastjson2/JSONObject.java +++ b/core/src/main/java/com/alibaba/fastjson2/JSONObject.java @@ -1093,6 +1093,18 @@ public Instant getInstant(String key) { return TypeUtils.toInstant(value); } + /** + * Returns the Object of the associated keys in this {@link JSONObject}. + * + * @param key the key whose associated value is to be returned + * @param value value to be associated with the specified key + * @return {@link Object} + * @since 2.0.32 + */ + public Object put(String key, Object value) { + return super.put(key, value); + } + /** * Serialize to JSON {@link String} *