How to use Sets as keys in Java Maps

前端 未结 4 820
借酒劲吻你
借酒劲吻你 2020-12-06 04:58

I have a Map that uses a Set for the key type, like this:

Map, Val> map;

When I query map.containsKey(myBunchOfThing

4条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-12-06 05:30

    Are you passing the exact set (the set you want to find) when comparing for the key?

提交回复
热议问题