Java <-> Scala interop: transparent List and Map conversion
问题 I am learning Scala and I have a Java project to migrate to Scala. I want to migrate it by rewriting classes one-by-one and checking that new class didn't break the project. This Java project uses lots of java.util.List and java.util.Map . In new Scala classes I would like to use Scala’s List and Map to have good-looking Scala code. The problem is that new classes (those are wtitten in Scala) do not integrate seamelessly with existing Java code: Java needs java.util.List , Scala needs its own