Convert Java Map to Scala Map
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I have a java map: java.util.Map > and I would like to convert it to the scala map: Map[SomeObject, Set[OtherObject]] I have used mapAsScalaMap but the result is not quite what I want, the result is: Map[SomeObject, java.util.Collection[OtherObject]] . How can I fix it to also convert the collection to a set? NOTE: actually my original problem was to convert google's ArrayListMultimap to a MultiMap[SomeObject, OtherObject] but since this was not possible I've split the problem. If you have a solution for the original problem, I'll also