错误:(4, 15) java: 包 org.omg.CORBA 不可见 (包 org.omg.CORBA 在模块 java.corba 中声明,该模块不在模块图中)
在 java 8 中运行良好
最佳答案
看这里https://blog.codefx.org/java/java-9-migration-guide/ “Java EE 模块的依赖关系”部分 引用自那里:
There’s a lot of code in Java SE that’s actually Java EE related. It ended up in these six modules: java.corba with javax.activity, javax.rmi, javax.rmi.CORBA, and org.omg.* packages For various compatibility reasons (one of them being split packages, which we will look at next), code on the class path does not see these modules by default, which leads to compile or run time errors...
error: XXX is not visible (package XXX is declared in module XXX, which is not in the module graph)
那里也描述了解决方案。看来是你的问题。
关于java - 当我在 selenium 中运行该程序时,我收到以下消息。使用的Java版本是9.0.1,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47435001/