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(MavenProject project,
PluginDescriptor pluginDescriptor) |
Modifier and Type | Method and Description |
---|---|
Set<Artifact> |
getDependencies()
Returns the list of
Artifact used in class path scanning for annotations |
String |
getEncoding()
Gets the file encoding of the source files.
|
ArtifactRepository |
getLocal() |
PluginDescriptor |
getPluginDescriptor() |
MavenProject |
getProject() |
List<ArtifactRepository> |
getRemoteRepos() |
boolean |
isSkipErrorNoDescriptorsFound() |
PluginToolsRequest |
setDependencies(Set<Artifact> dependencies) |
PluginToolsRequest |
setEncoding(String encoding)
Sets the file encoding of the source files.
|
PluginToolsRequest |
setLocal(ArtifactRepository local) |
PluginToolsRequest |
setPluginDescriptor(PluginDescriptor pluginDescriptor) |
PluginToolsRequest |
setProject(MavenProject project) |
PluginToolsRequest |
setRemoteRepos(List<ArtifactRepository> remoteRepos) |
PluginToolsRequest |
setSkipErrorNoDescriptorsFound(boolean skipErrorNoDescriptorsFound)
By default an exception is throw if no mojo descriptor is found.
|
public DefaultPluginToolsRequest(MavenProject project, PluginDescriptor pluginDescriptor)
public PluginDescriptor getPluginDescriptor()
getPluginDescriptor
in interface PluginToolsRequest
PluginDescriptor
currently being populated as part of the build of the
current plugin project.public PluginToolsRequest setPluginDescriptor(PluginDescriptor pluginDescriptor)
setPluginDescriptor
in interface PluginToolsRequest
pluginDescriptor
- the PluginDescriptor
PluginToolsRequest.getPluginDescriptor()
public MavenProject getProject()
getProject
in interface PluginToolsRequest
MavenProject
instance in use.public PluginToolsRequest setProject(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<Artifact> getDependencies()
PluginToolsRequest
Artifact
used in class path scanning for annotationsgetDependencies
in interface PluginToolsRequest
public PluginToolsRequest setDependencies(Set<Artifact> dependencies)
setDependencies
in interface PluginToolsRequest
dependencies
- the dependenciespublic List<ArtifactRepository> getRemoteRepos()
getRemoteRepos
in interface PluginToolsRequest
public PluginToolsRequest setRemoteRepos(List<ArtifactRepository> remoteRepos)
setRemoteRepos
in interface PluginToolsRequest
remoteRepos
- the remote repositoriespublic ArtifactRepository getLocal()
getLocal
in interface PluginToolsRequest
public PluginToolsRequest setLocal(ArtifactRepository local)
setLocal
in interface PluginToolsRequest
local
- the local repositoryCopyright © 2004–2022 The Apache Software Foundation. All rights reserved.