public class DefaultPluginToolsRequest extends Object implements PluginToolsRequest
PluginToolsRequest
, which is used to pass parameters to components used to extract
MojoDescriptor
instances from different types of metadata
for a given plugin.Constructor and Description |
---|
DefaultPluginToolsRequest(org.apache.maven.project.MavenProject project,
org.apache.maven.plugin.descriptor.PluginDescriptor pluginDescriptor) |
Modifier and Type | Method and Description |
---|---|
Set<org.apache.maven.artifact.Artifact> |
getDependencies()
Returns the list of
Artifact used in class path scanning for annotations |
String |
getEncoding()
Gets the file encoding of the source files.
|
List<URI> |
getExternalJavadocBaseUrls() |
URI |
getInternalJavadocBaseUrl() |
String |
getInternalJavadocVersion() |
org.apache.maven.artifact.repository.ArtifactRepository |
getLocal() |
org.apache.maven.plugin.descriptor.PluginDescriptor |
getPluginDescriptor() |
org.apache.maven.project.MavenProject |
getProject() |
List<org.apache.maven.artifact.repository.ArtifactRepository> |
getRemoteRepos() |
org.apache.maven.settings.Settings |
getSettings() |
boolean |
isSkipErrorNoDescriptorsFound() |
PluginToolsRequest |
setDependencies(Set<org.apache.maven.artifact.Artifact> dependencies) |
PluginToolsRequest |
setEncoding(String encoding)
Sets the file encoding of the source files.
|
PluginToolsRequest |
setExternalJavadocBaseUrls(List<URI> javadocLinks) |
PluginToolsRequest |
setInternalJavadocBaseUrl(URI baseUrl) |
PluginToolsRequest |
setInternalJavadocVersion(String javadocVersion) |
PluginToolsRequest |
setLocal(org.apache.maven.artifact.repository.ArtifactRepository local) |
PluginToolsRequest |
setPluginDescriptor(org.apache.maven.plugin.descriptor.PluginDescriptor pluginDescriptor) |
PluginToolsRequest |
setProject(org.apache.maven.project.MavenProject project) |
PluginToolsRequest |
setRemoteRepos(List<org.apache.maven.artifact.repository.ArtifactRepository> remoteRepos) |
PluginToolsRequest |
setSettings(org.apache.maven.settings.Settings settings) |
PluginToolsRequest |
setSkipErrorNoDescriptorsFound(boolean skipErrorNoDescriptorsFound)
By default an exception is throw if no mojo descriptor is found.
|
public DefaultPluginToolsRequest(org.apache.maven.project.MavenProject project, org.apache.maven.plugin.descriptor.PluginDescriptor pluginDescriptor)
public org.apache.maven.plugin.descriptor.PluginDescriptor getPluginDescriptor()
getPluginDescriptor
in interface PluginToolsRequest
PluginDescriptor
currently being populated as part of the build of the
current plugin project.public PluginToolsRequest setPluginDescriptor(org.apache.maven.plugin.descriptor.PluginDescriptor pluginDescriptor)
setPluginDescriptor
in interface PluginToolsRequest
pluginDescriptor
- the PluginDescriptor
PluginToolsRequest.getPluginDescriptor()
public org.apache.maven.project.MavenProject getProject()
getProject
in interface PluginToolsRequest
MavenProject
instance in use.public PluginToolsRequest setProject(org.apache.maven.project.MavenProject project)
setProject
in interface PluginToolsRequest
project
- the current MavenProject
PluginToolsRequest.getProject()
public String getEncoding()
getEncoding
in interface PluginToolsRequest
null
.public PluginToolsRequest setEncoding(String encoding)
setEncoding
in interface PluginToolsRequest
encoding
- The file encoding of the source files, may be empty or null
to use the platform's
default encoding.public boolean isSkipErrorNoDescriptorsFound()
isSkipErrorNoDescriptorsFound
in interface PluginToolsRequest
true
if no descriptor found should not cause a failurepublic PluginToolsRequest setSkipErrorNoDescriptorsFound(boolean skipErrorNoDescriptorsFound)
setSkipErrorNoDescriptorsFound
in interface PluginToolsRequest
skipErrorNoDescriptorsFound
- true
to skip errors because of not found descriptorspublic Set<org.apache.maven.artifact.Artifact> getDependencies()
PluginToolsRequest
Artifact
used in class path scanning for annotationsgetDependencies
in interface PluginToolsRequest
public PluginToolsRequest setDependencies(Set<org.apache.maven.artifact.Artifact> dependencies)
setDependencies
in interface PluginToolsRequest
dependencies
- the dependenciespublic List<org.apache.maven.artifact.repository.ArtifactRepository> getRemoteRepos()
getRemoteRepos
in interface PluginToolsRequest
public PluginToolsRequest setRemoteRepos(List<org.apache.maven.artifact.repository.ArtifactRepository> remoteRepos)
setRemoteRepos
in interface PluginToolsRequest
remoteRepos
- the remote repositoriespublic org.apache.maven.artifact.repository.ArtifactRepository getLocal()
getLocal
in interface PluginToolsRequest
public PluginToolsRequest setLocal(org.apache.maven.artifact.repository.ArtifactRepository local)
setLocal
in interface PluginToolsRequest
local
- the local repositorypublic PluginToolsRequest setInternalJavadocBaseUrl(URI baseUrl)
setInternalJavadocBaseUrl
in interface PluginToolsRequest
baseUrl
- may be relative to the current site's rootpublic URI getInternalJavadocBaseUrl()
getInternalJavadocBaseUrl
in interface PluginToolsRequest
public PluginToolsRequest setInternalJavadocVersion(String javadocVersion)
setInternalJavadocVersion
in interface PluginToolsRequest
public String getInternalJavadocVersion()
getInternalJavadocVersion
in interface PluginToolsRequest
public PluginToolsRequest setExternalJavadocBaseUrls(List<URI> javadocLinks)
setExternalJavadocBaseUrls
in interface PluginToolsRequest
public List<URI> getExternalJavadocBaseUrls()
getExternalJavadocBaseUrls
in interface PluginToolsRequest
public PluginToolsRequest setSettings(org.apache.maven.settings.Settings settings)
setSettings
in interface PluginToolsRequest
settings
- the Maven settingspublic org.apache.maven.settings.Settings getSettings()
getSettings
in interface PluginToolsRequest
Copyright © 2004–2022 The Apache Software Foundation. All rights reserved.