Remove duplicates from List using Guava

后端 未结 6 1057
清歌不尽
清歌不尽 2020-12-08 06:45

How can we remove duplicates from List with the help of Guava api?

Currently I am following this:

private List removeDuplic         


        
6条回答
  •  独厮守ぢ
    2020-12-08 07:31

    You can try Guava's MultiSet API to remove duplicates.Just add your list do the set and use the count method.

    MultiSet

提交回复
热议问题