On the difference between Maven’s jar package and war package and the packaging method
Jar files include Java ordinary classes, resource files and ordinary files. In maven, you can package all files under Src / main / Java and Src / main / resources resource folders. The mata-inf folder will be automatically generated during packaging to store Maven's POM information and manifest MF file. For example:
The war file contains all web applications, that is, all Java classes, configuration information and static resources such as JSP and JS. However, it should be noted that when war references war, all the resources applying war will be copied to the same file of the current war, and the file with the same name will be replaced. For example:
War package dependency:
The location of the package. This is my direct project. Right click - > run as - > Maven clean, and then Maven install
introduction:
Everyone must have used full-text search tools at ordinary times, and Baidu Google, the most commonly used tool, is a typical one. If you can do one, do you think it will make you full. Apache provides us with such a framework,
The following is a small demo of Lucene in the actual development.
This project is based on the SSM built by idea,
Writing Lucene tool classes
I won't mention the specific code in this tool class separately. I have comments on every key place, and I'll discuss it if it's unclear.
This article on the difference between Maven's jar package and war package and the packaging method is all the content shared by Xiaobian. I hope it can give you a reference and support more programming tips.