blob: 8d97c08ac50a9a306fe2b368c697c5769d124b9a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
|
diff -ru maven-plugin-api-bootstrap.orig/src/main/java/org/apache/maven/plugin/descriptor/PluginDescriptor.java maven-plugin-api-bootstrap/src/main/java/org/apache/maven/plugin/descriptor/PluginDescriptor.java
--- maven-plugin-api-bootstrap.orig/src/main/java/org/apache/maven/plugin/descriptor/PluginDescriptor.java 2014-02-14 12:34:53.000000000 -0500
+++ maven-plugin-api-bootstrap/src/main/java/org/apache/maven/plugin/descriptor/PluginDescriptor.java 2014-05-30 17:11:56.686594113 -0400
@@ -34,10 +34,6 @@
import org.apache.maven.artifact.Artifact;
import org.apache.maven.artifact.ArtifactUtils;
-import org.apache.maven.model.Plugin;
-import org.apache.maven.plugin.lifecycle.Lifecycle;
-import org.apache.maven.plugin.lifecycle.LifecycleConfiguration;
-import org.apache.maven.plugin.lifecycle.io.xpp3.LifecycleMappingsXpp3Reader;
import org.codehaus.plexus.classworlds.realm.ClassRealm;
import org.codehaus.plexus.component.repository.ComponentSetDescriptor;
import org.codehaus.plexus.util.IOUtil;
@@ -81,12 +77,8 @@
private String requiredMavenVersion;
- private Plugin plugin;
-
private Artifact pluginArtifact;
- private Map<String, Lifecycle> lifecycleMappings;
-
// ----------------------------------------------------------------------
//
// ----------------------------------------------------------------------
@@ -350,16 +342,6 @@
return requiredMavenVersion;
}
- public void setPlugin( Plugin plugin )
- {
- this.plugin = plugin;
- }
-
- public Plugin getPlugin()
- {
- return plugin;
- }
-
public Artifact getPluginArtifact()
{
return pluginArtifact;
@@ -370,36 +352,6 @@
this.pluginArtifact = pluginArtifact;
}
- public Lifecycle getLifecycleMapping( String lifecycleId )
- throws IOException, XmlPullParserException
- {
- if ( lifecycleMappings == null )
- {
- LifecycleConfiguration lifecycleConfiguration;
-
- Reader reader = null;
- try
- {
- reader = ReaderFactory.newXmlReader( getDescriptorStream( LIFECYCLE_DESCRIPTOR ) );
-
- lifecycleConfiguration = new LifecycleMappingsXpp3Reader().read( reader );
- }
- finally
- {
- IOUtil.close( reader );
- }
-
- lifecycleMappings = new HashMap<String, Lifecycle>();
-
- for ( Lifecycle lifecycle : lifecycleConfiguration.getLifecycles() )
- {
- lifecycleMappings.put( lifecycle.getId(), lifecycle );
- }
- }
-
- return lifecycleMappings.get( lifecycleId );
- }
-
private InputStream getDescriptorStream( String descriptor )
throws IOException
{
|