package in .java file makes class file unuseable

前端 未结 4 1811
忘掉有多难
忘掉有多难 2021-01-22 16:41

It\'s been too long since I\'ve last done Java, and I can\'t remember why the following happens:

Given this file, created by a standard Maven project, as can be seen her

4条回答
  •  半阙折子戏
    2021-01-22 16:55

    You need to add the com/mycompany/app folder to your Java CLASSPATH . If I remember well, you can also do it from the cmdline using the parameter "-cp".

提交回复
热议问题