LinkedHashMap for循环遍历_linkedhashmap 循环_keep12moving的博客-CSDN博客

Map<String, Future<String[]>> futures = new LinkedHashMap<String, Future<String[]>>();

futures.put(Line_Num, executorService.submit(api));

for (Map.Entry<String, Future<String[]>> entry : futures.entrySet()) {
                                String futuresKey = entry.getKey();
                                Future<String[]> futuresValue = entry.getValue();
                                try {
                                    String[] resStr = futuresValue.get();
                                    if (null != resStr) {
                                        String strKey = resStr[0];
                                        String strResult = resStr[1];

                                     }

                                     }

}


原网址: 访问
创建于: 2023-07-25 17:31:37
目录: default
标签: 无

请先后发表评论
  • 最新评论
  • 总共0条评论