8000 Server: 打包apijson-server2.6.0.jar; DemoFunction. getIdList兼容JDK 7 · coder-caicai/APIJSON@c2fa7d9 · GitHub
[go: up one dir, main page]

Skip to content

Commit c2fa7d9

Browse files
committed
Server: 打包apijson-server2.6.0.jar; DemoFunction. getIdList兼容JDK 7
1 parent 705fd94 commit c2fa7d9

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

APIJSON-Java-Server/APIJSONDemo/src/main/java/apijson/demo/server/DemoFunction.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414

1515
package apijson.demo.server;
1616

17+
import java.util.ArrayList;
1718
import java.util.Arrays;
1819
import java.util.List;
1920

@@ -92,11 +93,11 @@ public static Object invoke(JSONObject request, String function) throws Exceptio
9293

9394
/**TODO 仅用来测试 "key-()":"getIdList()" 和 "key()":"getIdList()"
9495
* @param request
95-
* @return
96+
* @return JSONArray 只能用JSONArray,用long[]会在SQLConfig解析崩溃
9697
* @throws Exception
9798
*/
9899
public JSONArray getIdList(@NotNull JSONObject request) throws Exception {
99-
return new JSONArray(Arrays.asList(12, 15, 301, 82001, 82002, 38710)); //只能用JSONArray,用long[]会在SQLConfig解析崩溃
100+
return new JSONArray(new ArrayList<Object>(Arrays.asList(12, 15, 301, 82001, 82002, 38710)));
100101
}
101102

102103
/**TODO 仅用来测试 "key-()":"verifyAccess()"

0 commit comments

Comments
 (0)
0