getResource方法的使用注意事项
this.getClass().getResource("/").getPath(),
如果以main方法运行,获得位置为:E:/模块目录/target/classes/或者E:/模块目录/target/test-classes/
如果是在test注解下运行,默认为:E:/模块目录/target/test-classes/

相关文章:

  • 2021-09-10
  • 2022-12-23
  • 2021-09-05
  • 2021-10-20
  • 2021-11-01
  • 2021-07-12
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-03-11
  • 2021-08-16
  • 2022-12-23
相关资源
相似解决方案