public class LifecycleMappingFactory extends Object
Modifier and Type | Field and Description |
---|---|
static String |
EXTENSION_LIFECYCLE_MAPPING_METADATA_SOURCE |
static String |
EXTENSION_LIFECYCLE_MAPPINGS |
static String |
EXTENSION_PROJECT_CONFIGURATORS |
static String |
LIFECYCLE_MAPPING_METADATA_SOURCE_NAME |
static String |
LIFECYCLE_MAPPING_PLUGIN_ARTIFACTID |
static String |
LIFECYCLE_MAPPING_PLUGIN_GROUPID |
static String |
LIFECYCLE_MAPPING_PLUGIN_VERSION |
Constructor and Description |
---|
LifecycleMappingFactory() |
Modifier and Type | Method and Description |
---|---|
static List<MappingMetadataSource> |
asList(Map<String,List<MappingMetadataSource>> map) |
static void |
calculateEffectiveLifecycleMappingMetadata(LifecycleMappingResult result,
List<MappingMetadataSource> metadataSources,
org.apache.maven.project.MavenProject mavenProject,
List<org.apache.maven.plugin.MojoExecution> mojoExecutions,
boolean applyDefaultStrategy,
org.eclipse.core.runtime.IProgressMonitor monitor) |
static void |
calculateEffectiveLifecycleMappingMetadata(LifecycleMappingResult result,
org.apache.maven.project.MavenProject mavenProject,
List<org.apache.maven.plugin.MojoExecution> mojoExecutions,
org.eclipse.core.runtime.IProgressMonitor monitor) |
static LifecycleMappingResult |
calculateLifecycleMapping(org.apache.maven.project.MavenProject mavenProject,
List<org.apache.maven.plugin.MojoExecution> mojoExecutions,
String lifecycleMappingId,
org.eclipse.core.runtime.IProgressMonitor monitor) |
static LifecycleMappingMetadataSource |
createLifecycleMappingMetadataSource(InputStream is) |
static MojoExecutionBuildParticipant |
createMojoExecutionBuildParicipant(IMavenProjectFacade projectFacade,
org.apache.maven.plugin.MojoExecution mojoExecution,
IPluginExecutionMetadata executionMetadata) |
static AbstractProjectConfigurator |
createProjectConfigurator(IPluginExecutionMetadata metadata) |
static AbstractProjectConfigurator |
createProjectConfigurator(String configuratorId) |
static String |
getActionMessage(IPluginExecutionMetadata metadata) |
static List<LifecycleMappingMetadataSource> |
getBundleMetadataSources()
Returns lifecycle mapping metadata sources provided by all installed bundles
|
static LifecycleMappingMetadataSource |
getDefaultLifecycleMappingMetadataSource() |
static ILifecycleMapping |
getLifecycleMapping(IMavenProjectFacade facade) |
static Map<String,org.eclipse.core.runtime.IConfigurationElement> |
getLifecycleMappingExtensions() |
static List<LifecycleMappingMetadataSource> |
getPomMappingMetadataSources(org.apache.maven.project.MavenProject mavenProject,
org.eclipse.core.runtime.IProgressMonitor monitor)
Returns lifecycle mapping metadata sources embedded or referenced by pom.xml in the following order
this pom.xml embedded
this pom.xml referenced
parent pom.xml embedded
parent pom.xml referenced
grand parent embedded
and so on
Returns empty list if no metadata sources are embedded/referenced by pom.xml
|
static Map<String,org.eclipse.core.runtime.IConfigurationElement> |
getProjectConfiguratorExtensions() |
static Map<String,org.eclipse.core.runtime.IConfigurationElement> |
getProjectConfiguratorExtensions(org.eclipse.core.runtime.IExtensionRegistry registry) |
static String |
getProjectConfiguratorId(IPluginExecutionMetadata metadata) |
static Map<String,AbstractProjectConfigurator> |
getProjectConfigurators(IMavenProjectFacade facade) |
static List<MappingMetadataSource> |
getProjectMetadataSources(org.apache.maven.project.MavenProject mavenProject,
List<LifecycleMappingMetadataSource> bundleMetadataSources,
List<org.apache.maven.plugin.MojoExecution> mojoExecutions,
boolean includeDefault,
org.eclipse.core.runtime.IProgressMonitor monitor) |
static Map<String,List<MappingMetadataSource>> |
getProjectMetadataSourcesMap(org.apache.maven.project.MavenProject mavenProject,
List<LifecycleMappingMetadataSource> bundleMetadataSources,
List<org.apache.maven.plugin.MojoExecution> mojoExecutions,
boolean includeDefault,
org.eclipse.core.runtime.IProgressMonitor monitor) |
static LifecycleMappingMetadataSource |
getWorkspaceMetadata(boolean reload) |
static void |
instantiateLifecycleMapping(LifecycleMappingResult result,
org.apache.maven.project.MavenProject mavenProject,
String lifecycleMappingId) |
static void |
instantiateProjectConfigurators(org.apache.maven.project.MavenProject mavenProject,
LifecycleMappingResult result,
Map<MojoExecutionKey,List<IPluginExecutionMetadata>> map) |
static boolean |
isInterestingPhase(String phase) |
static boolean |
isLifecycleMappingChanged(IMavenProjectFacade newFacade,
ILifecycleMappingConfiguration oldConfiguration,
org.eclipse.core.runtime.IProgressMonitor monitor) |
static void |
setBundleMetadataSources(List<LifecycleMappingMetadataSource> bundleMetadataSources) |
static void |
setDefaultLifecycleMappingMetadataSource(LifecycleMappingMetadataSource defaultLifecycleMappingMetadataSource)
For unit tests only
|
static void |
setUseDefaultLifecycleMappingMetadataSource(boolean use)
For unit tests only
|
static void |
writeWorkspaceMetadata(LifecycleMappingMetadataSource metadata) |
public static final String LIFECYCLE_MAPPING_PLUGIN_GROUPID
public static final String LIFECYCLE_MAPPING_PLUGIN_ARTIFACTID
public static final String LIFECYCLE_MAPPING_PLUGIN_VERSION
public static final String LIFECYCLE_MAPPING_METADATA_SOURCE_NAME
public static final String EXTENSION_LIFECYCLE_MAPPINGS
public static final String EXTENSION_PROJECT_CONFIGURATORS
public static final String EXTENSION_LIFECYCLE_MAPPING_METADATA_SOURCE
public static LifecycleMappingResult calculateLifecycleMapping(org.apache.maven.project.MavenProject mavenProject, List<org.apache.maven.plugin.MojoExecution> mojoExecutions, String lifecycleMappingId, org.eclipse.core.runtime.IProgressMonitor monitor)
public static void calculateEffectiveLifecycleMappingMetadata(LifecycleMappingResult result, org.apache.maven.project.MavenProject mavenProject, List<org.apache.maven.plugin.MojoExecution> mojoExecutions, org.eclipse.core.runtime.IProgressMonitor monitor) throws org.eclipse.core.runtime.CoreException
org.eclipse.core.runtime.CoreException
public static List<MappingMetadataSource> getProjectMetadataSources(org.apache.maven.project.MavenProject mavenProject, List<LifecycleMappingMetadataSource> bundleMetadataSources, List<org.apache.maven.plugin.MojoExecution> mojoExecutions, boolean includeDefault, org.eclipse.core.runtime.IProgressMonitor monitor) throws org.eclipse.core.runtime.CoreException, LifecycleMappingConfigurationException
org.eclipse.core.runtime.CoreException
LifecycleMappingConfigurationException
public static Map<String,List<MappingMetadataSource>> getProjectMetadataSourcesMap(org.apache.maven.project.MavenProject mavenProject, List<LifecycleMappingMetadataSource> bundleMetadataSources, List<org.apache.maven.plugin.MojoExecution> mojoExecutions, boolean includeDefault, org.eclipse.core.runtime.IProgressMonitor monitor) throws org.eclipse.core.runtime.CoreException, LifecycleMappingConfigurationException
org.eclipse.core.runtime.CoreException
LifecycleMappingConfigurationException
public static List<MappingMetadataSource> asList(Map<String,List<MappingMetadataSource>> map)
public static LifecycleMappingMetadataSource getWorkspaceMetadata(boolean reload)
public static void writeWorkspaceMetadata(LifecycleMappingMetadataSource metadata)
public static void calculateEffectiveLifecycleMappingMetadata(LifecycleMappingResult result, List<MappingMetadataSource> metadataSources, org.apache.maven.project.MavenProject mavenProject, List<org.apache.maven.plugin.MojoExecution> mojoExecutions, boolean applyDefaultStrategy, org.eclipse.core.runtime.IProgressMonitor monitor)
public static void instantiateLifecycleMapping(LifecycleMappingResult result, org.apache.maven.project.MavenProject mavenProject, String lifecycleMappingId)
public static void instantiateProjectConfigurators(org.apache.maven.project.MavenProject mavenProject, LifecycleMappingResult result, Map<MojoExecutionKey,List<IPluginExecutionMetadata>> map)
public static List<LifecycleMappingMetadataSource> getPomMappingMetadataSources(org.apache.maven.project.MavenProject mavenProject, org.eclipse.core.runtime.IProgressMonitor monitor) throws org.eclipse.core.runtime.CoreException
org.eclipse.core.runtime.CoreException
- if metadata sources cannot be resolved or readpublic static AbstractProjectConfigurator createProjectConfigurator(IPluginExecutionMetadata metadata)
public static String getProjectConfiguratorId(IPluginExecutionMetadata metadata)
public static String getActionMessage(IPluginExecutionMetadata metadata)
public static LifecycleMappingMetadataSource createLifecycleMappingMetadataSource(InputStream is) throws IOException, org.codehaus.plexus.util.xml.pull.XmlPullParserException
IOException
org.codehaus.plexus.util.xml.pull.XmlPullParserException
public static MojoExecutionBuildParticipant createMojoExecutionBuildParicipant(IMavenProjectFacade projectFacade, org.apache.maven.plugin.MojoExecution mojoExecution, IPluginExecutionMetadata executionMetadata)
public static Map<String,org.eclipse.core.runtime.IConfigurationElement> getLifecycleMappingExtensions()
public static AbstractProjectConfigurator createProjectConfigurator(String configuratorId)
public static Map<String,org.eclipse.core.runtime.IConfigurationElement> getProjectConfiguratorExtensions()
public static Map<String,org.eclipse.core.runtime.IConfigurationElement> getProjectConfiguratorExtensions(org.eclipse.core.runtime.IExtensionRegistry registry)
public static LifecycleMappingMetadataSource getDefaultLifecycleMappingMetadataSource()
public static void setDefaultLifecycleMappingMetadataSource(LifecycleMappingMetadataSource defaultLifecycleMappingMetadataSource)
public static void setUseDefaultLifecycleMappingMetadataSource(boolean use)
public static List<LifecycleMappingMetadataSource> getBundleMetadataSources()
public static ILifecycleMapping getLifecycleMapping(IMavenProjectFacade facade)
public static Map<String,AbstractProjectConfigurator> getProjectConfigurators(IMavenProjectFacade facade)
public static boolean isLifecycleMappingChanged(IMavenProjectFacade newFacade, ILifecycleMappingConfiguration oldConfiguration, org.eclipse.core.runtime.IProgressMonitor monitor)
public static boolean isInterestingPhase(String phase)
public static void setBundleMetadataSources(List<LifecycleMappingMetadataSource> bundleMetadataSources)
bundleMetadataSources
- The bundleMetadataSources to set.Copyright © 2005–2015 Sonatype, Inc.. All rights reserved.