org.apache.myfaces.buildtools.maven2.plugin.builder
Class BuildMetaDataMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.apache.myfaces.buildtools.maven2.plugin.builder.BuildMetaDataMojo
- All Implemented Interfaces:
- org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
public class BuildMetaDataMojo
- extends org.apache.maven.plugin.AbstractMojo
Maven goal which runs one or more ModelBuilder objects to gather metadata
about JSF artifacts into a Model object, then save that model object as an
xml file for use by other goals of this plugin.
By default, the generated file is named "META-INF/myfaces-metadata.xml".
This file will be included in the final artifact for this project. Having
that metadata file embedded in the generated jarfile is useful for two
purposes:
- It is needed if other projects then use the myfaces-builder-plugin to
create subclasses of the jsf classes in this project.
- It is good documentation (more precise than the tld and faces-config.xml
files).
Note that the generated file contains all the metadata needed by this
project, including a copy of all the metadata from other projects that
this one depends on. All other goals of this plugin can execute with
just the generated metadata as input, without needing to load other
projects. Each entry in the metadata is labelled with a "modelId"
property that indicates where it originally came from.
Fields inherited from interface org.apache.maven.plugin.Mojo |
ROLE |
Method Summary |
protected void |
addResourceRoot(org.apache.maven.project.MavenProject project,
String resourceRoot)
|
void |
execute()
Create a metadata file containing information imported from other projects
plus data extracted from annotated classes in this project. |
protected boolean |
isCachingEnabled()
|
Methods inherited from class org.apache.maven.plugin.AbstractMojo |
getLog, getPluginContext, setLog, setPluginContext |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BuildMetaDataMojo
public BuildMetaDataMojo()
execute
public void execute()
throws org.apache.maven.plugin.MojoExecutionException
- Create a metadata file containing information imported from other projects
plus data extracted from annotated classes in this project.
- Throws:
org.apache.maven.plugin.MojoExecutionException
isCachingEnabled
protected boolean isCachingEnabled()
addResourceRoot
protected void addResourceRoot(org.apache.maven.project.MavenProject project,
String resourceRoot)
Copyright © 2001-2013 The Apache Software Foundation. All Rights Reserved.