因为实体类用的是Integer包装类,所以是对象,不能直接比较大小,

一、一个Integer一个Int可以直接比较大小

二、两个Integer需要用.intValue()方法比较大小:

例如:cw.getCwId().intValue()==list.get(i).getCwId().intValue()

相关文章:

  • 2022-12-23
  • 2021-10-21
  • 2022-12-23
  • 2021-07-16
  • 2021-06-23
  • 2021-06-17
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-04-24
  • 2022-12-23
  • 2022-03-06
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案