public class Maven extends Object
resolver()
is analogous to a more longhand, formal call to
Resolvers.use(Class)
, passing MavenResolverSystem
as the argument. Also supports configuration via
configureResolver()
.Constructor and Description |
---|
Maven() |
Modifier and Type | Method and Description |
---|---|
static ConfigurableMavenResolverSystem |
configureResolver()
Creates and returns a new
ConfigurableMavenResolverSystem instance which may be used to create new
MavenResolverSystem instances |
static PomEquippedResolveStage |
configureResolverViaPlugin()
Configures the
MavenResolverSystem with settings.xml and POM metadata as picked up from the
environment (these properties are set by the ShrinkWrap Maven Resolver Plugin). |
static PomEquippedResolveStage |
configureResolverViaPlugin(ClassLoader cl)
Configures the
MavenResolverSystem with settings.xml and POM metadata as picked up from the
environment (these properties are set by the ShrinkWrap Maven Resolver Plugin). |
static MavenResolverSystem |
resolver()
Creates and returns a new
MavenResolverSystem instance |
public static MavenResolverSystem resolver()
MavenResolverSystem
instanceMavenResolverSystem
instancepublic static ConfigurableMavenResolverSystem configureResolver()
ConfigurableMavenResolverSystem
instance which may be used to create new
MavenResolverSystem
instancesConfigurableMavenResolverSystem
instance which may be used to create new
MavenResolverSystem
instancespublic static PomEquippedResolveStage configureResolverViaPlugin() throws InvalidEnvironmentException
MavenResolverSystem
with settings.xml
and POM metadata as picked up from the
environment (these properties are set by the ShrinkWrap Maven Resolver Plugin). The new instance will be created
by the current Thread.getContextClassLoader()
.MavenResolverSystem
configured with settings.xml
and POM metadata as picked up
from the environmentInvalidEnvironmentException
- If this is executed outside the context of the ShrinkWrap Maven Resolver Plugin Environmentpublic static PomEquippedResolveStage configureResolverViaPlugin(ClassLoader cl) throws InvalidEnvironmentException, IllegalArgumentException
MavenResolverSystem
with settings.xml
and POM metadata as picked up from the
environment (these properties are set by the ShrinkWrap Maven Resolver Plugin).cl
- The ClassLoader
used to create the new instance; requiredMavenResolverSystem
configured with settings.xml
and POM metadata as picked up
from the environmentIllegalArgumentException
- If the ClassLoader
is not specifiedInvalidEnvironmentException
- If this is executed outside the context of the ShrinkWrap Maven Resolver Plugin EnvironmentCopyright © 2022 JBoss by Red Hat. All rights reserved.