Table of Contents

Understanding Maven project layout


Maven project is opened in Visual Studio. You can find instructions how to create a Maven project in this section.


When the project is opened, you can browse its contents in Solution Explorer. The content is presented in a tree form, same as for any other project in Visual Studio. An example view of a project (after expanding some nodes) might look like this:

You can see several distinct parts. Note that Maven projects are more complex than typical Visual Studio projects for C++ or C# language. IntegraStudio does not hide Maven build file structure. It also does not create any kind of its own project model replacing Maven structures. This allows utilisation of full Maven potential and interoperability with other IDEs. However, IntegraStudio adds some extra nodes of its own in order to make working with projects easier and more "Visual Studio-like".

The first node is the Sources node. It contains three branches: Main, Test and Scripts. Each of them represent a root view for Java source directories and files. They appear inside the view as on disk. Source directories to display are taken from Maven (using the sourceDirectory, testSourceDirectory and scriptSourceDirectory properties of the effective POM). All the visible folders are equivalent to physical disk folders, as usual in Java IDEs. In other aspects, they work similar to folders and files in C++ or C# Visual Studio project. You can add new elements, rename existing ones or delete them. To open a file for editing, just double-click the name.

Next, there come Resource directories and Test resource directories nodes. Both host physical directories containing resources for the proper build and tests.

The Subprojects node contains views of inner projects, known as modules in Maven terminology. In Maven, you can have a project which serves as a container for other projects. This is somewhat different from Visual Studio, where the solution performs such role. Under IntegraStudio, you can have the VS solution which hosts a container Maven project, which in turn has child projects. They are visible under the Subprojects node. [Note: under IntegraStudio beta the subproject mechanism works for the most part, but has been not fully implemented yet.]

Configuration is a view of the Maven project metadata. Maven project file is also called POM (Project Object Model) and it is a XML file, typically named pom.xml. The Configuration node actually shows directly exposed POM file structure. You can configure every available option here, including dependencies and plugin configuration. You can find reference documentation regarding the POM in this section of Maven docs.

Editing properties

Most of the nodes in Solution Explorer have editable properties. In order to edit them, right-click on a node and choose Properties. For example, the main project node has the following properties:

Another example: properties of a dependency node:

Every type of a node has its own set of properties.

Adding new items and deleting existing ones

Many of the nodes act as containers for other nodes. IntegraStudio offers usual Add / New item and Add / New folder options for them, which add a child node. The type of the node depends on which parent node you are adding a child to. For example:

Table of Contents

Copyright (C) 2014-2016 SOFT-ERG. All rights reserved.