Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想知道为什么scala.util.parsing.combinator.testing.RegexTest有一个 main 方法。
库类不是打算从程序中调用而不是作为独立的可执行文件单独运行吗?
这不是唯一的一个。我特别喜欢的一个是scala.swing.test.UIDemo。我真的,真的不认为它们应该与图书馆捆绑在一起,但它们确实如此。基本上,它们是您可以直接运行的示例:
scala.swing.test.UIDemo
scala scala.swing.test.UIDemo