From 78b6cff764dd118fddbfb311f58d4252c99c6d0e Mon Sep 17 00:00:00 2001
From: dion
- Maven utilizes Ant
- to provide users with an easy-to-use and familiar interface to
- manage projects that have been described with a valid Maven project descriptor.
- The build files that Maven
- installs are stored in
- This document describes the Ant build file and targets
- that are available when using the Struts Plug-in with Maven.
-
- The current recommended approach to using Maven is to add
- delegators to these Maven-provided targets in your project's
- main build file. This will enable you to use your existing
- build file with the additional Maven functionality. In
- addition, it is also recommended that you load a standard set of
- property files. The property files will setup your environment,
-
- The following table contains a brief overview of the
- build file that is installed as part of the Maven Struts Plug-in in the
-
- The build file utilizes various properties for default and
- user-configurable settings. All Struts Plug-in properties are described
- in the Properties document.
-
- The rest of this document assumes your project follows the standard
- Directory Layout; however, it is
- possible to override many of these defaults.
-
- The
- The validator checks the folowing:
- ${maven.home} directory.
- ${lib.repo} and ${maven.home}, and
- allow you to override Maven defaults properties. Please refer
- to the Integration document for
- more information on how to integrate these build targets into
- your project.
- ${maven.home}/plugin/struts directory. In addition,
- the various Ant targets in this file is discussed.
-
-
-
- Build File Description
-
- build.xml
-
- Contains a target validate Struts
- WAR files.
-
-
-
-
- Target Description
-
- maven:validate-struts-war
- Validate a Struts
- WAR file.maven:validate-struts-war target validates the struts
- war file.
-
-
- WEB-INF/struts-config.xml<form-bean> tag
- have a type that is loadable from the war file
- and not the classpath. If the form bean has
- a className, that class too must be loaded from
- the war<action< tag have
- several validations:
-
-
- className attribute must be a
- class loadable from the warname attribute, must match a
- <form-bean> name attribute.path attribute must start with a
- forward slash, i.e. '/'scope attribute must be one of
- request or sesssiontype attribute must be a class
- loadable from the warunknown and validate
- attributes must be either true or
- false
- Having a common directory layout would allow for users familiar - with one Maven project to immediately feel at home in another - Maven project. The advantages are analogous to adopting a - site-wide look-and-feel. Common Maven procedures strengthen the - Maven brand. -
-- The next two sections document the directory layout expected by - Maven and the directory layout created by Maven. Please try to - conform to this structure as much as possible; however, if you - must these settings can be overridden via properties as - documented in the Integration document. -
-| Directory name | -Content | -Comment | -
|---|---|---|
| target/ | -Contains compiled WARs. | -- This directory is used by the Struts Plug-in as the source of the - war to be validated. - | -