Tutorial - step 1: create a new project

Creating a new web project

First of all, we need to create a new Web Project, to build our new web application.

Click on the following icon:

Then select new dynamic web project:

Enter a project name (HelloWorld for instance), and apply your usual web-project properties, and finish creating the project:

This creates a new standard eclipse web project.

Creating a new MVC Web Project file

For the moment, MVC Web Project plugin has not been used. To activate it, we must create a new MVC Web Project file.

Select the project, and right click to create a new file:

Select Web/Alveole Studio MVC Web Project:

Enter a file name (project for instance):

Enter a description for the project:

Activate struts2 plugin:

And click finish.

A project.aswp is created, and WEB-INF/lib contains all struts2 jar files:

Also note that src directory contains the following files:

  • struts.xml: a generic struts.xml file that includes two others,
  • alveole-defaults.xml: a struts2 file that defines struts2 package alveole-defaults that can be used to define default parameters for MVC project,
  • alveole-struts.xml: a struts2 file that will contain all action-mappings of our project,
  • alveole-links.properties: a properties file that will contain a mapping from link names to URLs.