2. Create a TestUtils class in the project, and in them to write the main method
3. In this way, in addition to a main springboot start class, there is also a TestUtils in main
4. Use maven into jars
5. We can through the use of the command Java jar test - the main - 0.0.1 - the SNAPSHOT. Jar to launch this web project
6. But now I don't want to start by the above command, but only the main method in the implementation in the jar package TestUtils
Said 7. Find relevant methods, using Java - cp test - the main - 0.0.1 - the SNAPSHOT. Jar. Com yanva. Testmain. TestUtils parameters 1 2 this way of command can be performed to specify the main method
8 but run results is so (figure 5) error: can't find or unable to load the main class com. The yanva. Testmain. TestUtils
9. Maven is
Org. Springframework. Boot Spring - the boot - maven - plugin
10. Please god project baidu network location address https://pan.baidu.com/s/1pnFKvPxS_NQocFl8CcbLlw
CodePudding user response:
Excuse me, would you please tell me how to solve this problem? How to solve?