1. Iterator<Entry<String,Boolean>> iter = set.iterator();  
  2.         while(iter.hasNext()){  
  3.             Entry<String,Boolean> entry = iter.next();  
  4.             String key = entry.getKey();  
  5.               
  6.         }  


这里的next会抛出Java.util.ConcurrentModificationException。
在网上很多人都说,用了romove办法,这里,我没调用过remove。原因没明。

相关文章:

  • 2022-12-23
  • 2021-05-20
  • 2021-06-22
  • 2021-09-19
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-11
猜你喜欢
  • 2021-07-29
  • 2022-12-23
  • 2021-11-04
  • 2021-11-20
  • 2021-11-14
相关资源
相似解决方案