Article One: Eclipse create maven Project

Source: Internet
Author: User

I. Overview

The projects that Maven creates are divided into three main categories: War (Web Project), Jar (Java Engineering), POM (parent project);

War: Web project, including WebApp, for view layer

Jar:java Engineering for the provision of methods, service, DAO and other services

POM: Parent project, typically do not write code, just configure the jar version in the Pom.xml file, etc.

Ii. Eclipse creation of the War project

1, unified set the format of the work space encoding

window-->preferences--> input "enc", which changes the code to "UTF-8"

     

  

2. Create Maven Project

New-->maven-->maven Project

    

Choose Simple Project, and manually configure the package path to avoid packet structure confusion

    

Fill in the basic message, where packaging Select the war, fill out the click "Finish"

    

Iii. automatic generation of Web. xml

Simple project created by default, does not contain Web. XML, and will be an error message after creation "web. XML is Missing"

Select Item-->properties-->project Facets

  

Click "futher configuration Available" To configure the path to Web. xml: Src/main/webapp

  

Finally click on Apply button application configuration is OK

Article One: Eclipse create maven Project

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.