Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIgor Fedorenko2011-09-15 10:25:12 -0400
committerIgor Fedorenko2011-09-15 10:25:12 -0400
commit748499b3616ad58fba9954a3d9dd3f13cbee427b (patch)
treeb1e0d0f103787d7bb1ca6b96bcc4295c1ba62614
parentc2312722f9a740dc3541dd1a7ea6988e15f41344 (diff)
downloadm2e-core-748499b3616ad58fba9954a3d9dd3f13cbee427b.tar.gz
m2e-core-748499b3616ad58fba9954a3d9dd3f13cbee427b.tar.xz
m2e-core-748499b3616ad58fba9954a3d9dd3f13cbee427b.zip
cleanup
Signed-off-by: Igor Fedorenko <igor@ifedorenko.com>
-rw-r--r--org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/LifecycleMappingFactory.java7
-rw-r--r--org.eclipse.m2e.jdt/src/org/eclipse/m2e/jdt/internal/SourcesGenerationProjectConfigurator.java2
2 files changed, 6 insertions, 3 deletions
diff --git a/org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/LifecycleMappingFactory.java b/org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/LifecycleMappingFactory.java
index 2a3aaec2..31065cb5 100644
--- a/org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/LifecycleMappingFactory.java
+++ b/org.eclipse.m2e.core/src/org/eclipse/m2e/core/internal/lifecyclemapping/LifecycleMappingFactory.java
@@ -97,6 +97,7 @@ import org.eclipse.m2e.core.project.configurator.MojoExecutionKey;
* @author igor
*/
public class LifecycleMappingFactory {
+
private static final Logger log = LoggerFactory.getLogger(LifecycleMappingFactory.class);
public static final String LIFECYCLE_MAPPING_PLUGIN_GROUPID = "org.eclipse.m2e"; //$NON-NLS-1$
@@ -114,6 +115,8 @@ public class LifecycleMappingFactory {
private static final String LIFECYCLE_MAPPING_METADATA_SOURCE_PATH = "/" + LIFECYCLE_MAPPING_METADATA_SOURCE_NAME; //$NON-NLS-1$
+ private static final String LIFECYCLE_MAPPING_METADATA_EMBEDDED_SOURCE_PATH = "META-INF/m2e/" + LIFECYCLE_MAPPING_METADATA_SOURCE_NAME; //$NON-NLS-1$
+
public static final String EXTENSION_LIFECYCLE_MAPPINGS = IMavenConstants.PLUGIN_ID + ".lifecycleMappings"; //$NON-NLS-1$
public static final String EXTENSION_PROJECT_CONFIGURATORS = IMavenConstants.PLUGIN_ID + ".projectConfigurators"; //$NON-NLS-1$
@@ -319,7 +322,7 @@ public class LifecycleMappingFactory {
if(file.isFile()) {
JarFile jar = new JarFile(file);
try {
- ZipEntry entry = jar.getEntry("META-INF/m2e/lifecycle-mapping-metadata.xml");
+ ZipEntry entry = jar.getEntry(LIFECYCLE_MAPPING_METADATA_EMBEDDED_SOURCE_PATH);
if(entry == null) {
return null;
}
@@ -335,7 +338,7 @@ public class LifecycleMappingFactory {
} else if(file.isDirectory()) {
try {
InputStream is = new BufferedInputStream(new FileInputStream(new File(file,
- "META-INF/m2e/lifecycle-mapping-metadata.xml")));
+ LIFECYCLE_MAPPING_METADATA_EMBEDDED_SOURCE_PATH)));
try {
return readMavenPluginEmbeddedMetadata(artifact, is);
} finally {
diff --git a/org.eclipse.m2e.jdt/src/org/eclipse/m2e/jdt/internal/SourcesGenerationProjectConfigurator.java b/org.eclipse.m2e.jdt/src/org/eclipse/m2e/jdt/internal/SourcesGenerationProjectConfigurator.java
index 64d0ece1..7cfb21bd 100644
--- a/org.eclipse.m2e.jdt/src/org/eclipse/m2e/jdt/internal/SourcesGenerationProjectConfigurator.java
+++ b/org.eclipse.m2e.jdt/src/org/eclipse/m2e/jdt/internal/SourcesGenerationProjectConfigurator.java
@@ -54,7 +54,7 @@ import org.eclipse.m2e.jdt.IJavaProjectConfigurator;
* <li>File outputDirecotry, location of generated sources on the local filesystem. Default ${mojo.outputDirecotry}.</li>
* <li>File sourceDirectory, location of input resources used by the code generation plugin. Used to suppress unneeded
* code generation when there are no changes. Can be null, in which case code generation will be executed on full
- * workspace builds only.</li>
+ * workspace builds only, unless incremental build is forced with runOnIncremental=true</li>
* <li>Boolean runOnIncremental, if <code>true</code> the code generation will be executed on incremental builds, if
* <code>false</code> the code generation will be executed on full builds only. Default is to execute code generation on
* incremental builds if sourceDirectory is provided.</li>

Back to the top