Package org.apache.maven.project
Interface ProjectBuildingRequest
- All Known Implementing Classes:
DefaultProjectBuildingRequest
public interface ProjectBuildingRequest
ProjectBuildingRequest
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic enum
The possible merge modes for combining remote repositories. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addProfile
(Profile profile) Add aProfile
that has come from an external source.Gets the start time of the build.Deprecated.Gets the merge mode used to combine repositories declared in the POM with the repositories specified in this requestorg.eclipse.aether.RepositorySystemSession
Gets the system properties to use for interpolation and profile activation.Gets the user properties to use for interpolation and profile activation.int
Gets the level of validation to perform on processed models.boolean
boolean
boolean
Deprecated.This got added when implementing MNG-2199 and is no longer used.void
setActiveProfileIds
(List<String> activeProfileIds) Set any active profiles that theProjectBuilder
should consider while constructing aMavenProject
.void
setBuildStartInstant
(Instant buildStartInstant) Sets the start time of the build.void
setBuildStartTime
(Date buildStartTime) Deprecated.void
setInactiveProfileIds
(List<String> inactiveProfileIds) setLocalRepository
(ArtifactRepository localRepository) setPluginArtifactRepositories
(List<ArtifactRepository> pluginArtifactRepositories) setProcessPlugins
(boolean processPlugins) void
setProfiles
(List<Profile> profiles) void
setProject
(MavenProject mavenProject) setRemoteRepositories
(List<ArtifactRepository> remoteRepositories) Sets the merge mode used to combine repositories declared in the POM with the repositories specified in this request.setRepositorySession
(org.eclipse.aether.RepositorySystemSession repositorySession) setResolveDependencies
(boolean resolveDependencies) setResolveVersionRanges
(boolean value) Deprecated.This got added when implementing MNG-2199 and is no longer used.setSystemProperties
(Properties systemProperties) Sets the system properties to use for interpolation and profile activation.setUserProperties
(Properties userProperties) Sets the user properties to use for interpolation and profile activation.setValidationLevel
(int validationLevel) Controls the level of validation to perform on processed models.
-
Method Details
-
setLocalRepository
-
getLocalRepository
ArtifactRepository getLocalRepository() -
setRemoteRepositories
-
getRemoteRepositories
List<ArtifactRepository> getRemoteRepositories() -
setPluginArtifactRepositories
ProjectBuildingRequest setPluginArtifactRepositories(List<ArtifactRepository> pluginArtifactRepositories) -
getPluginArtifactRepositories
List<ArtifactRepository> getPluginArtifactRepositories() -
setSystemProperties
Sets the system properties to use for interpolation and profile activation. The system properties are collected from the runtime environment likeSystem.getProperties()
and environment variables.- Parameters:
systemProperties
- The system properties, may benull
.- Returns:
- This request, never
null
.
-
getSystemProperties
Properties getSystemProperties()Gets the system properties to use for interpolation and profile activation. The system properties are collected from the runtime environment likeSystem.getProperties()
and environment variables.- Returns:
- The system properties, never
null
.
-
setUserProperties
Sets the user properties to use for interpolation and profile activation. The user properties have been configured directly by the user on his discretion, e.g. via the-Dkey=value
parameter on the command line.- Parameters:
userProperties
- The user properties, may benull
.- Returns:
- This request, never
null
.
-
getUserProperties
Properties getUserProperties()Gets the user properties to use for interpolation and profile activation. The user properties have been configured directly by the user on his discretion, e.g. via the-Dkey=value
parameter on the command line.- Returns:
- The user properties, never
null
.
-
setProject
-
getProject
MavenProject getProject() -
setProcessPlugins
-
isProcessPlugins
boolean isProcessPlugins() -
setResolveDependencies
-
isResolveDependencies
boolean isResolveDependencies() -
setValidationLevel
Controls the level of validation to perform on processed models. By default, models are validated in strict mode.- Parameters:
validationLevel
- The level of validation to perform on processed models, e.g.ModelBuildingRequest.VALIDATION_LEVEL_STRICT
.- Returns:
- This configuration, never
null
.
-
getValidationLevel
int getValidationLevel()Gets the level of validation to perform on processed models.- Returns:
- The level of validation to perform on processed models.
-
setActiveProfileIds
Set any active profiles that theProjectBuilder
should consider while constructing aMavenProject
. -
getActiveProfileIds
-
setInactiveProfileIds
-
getInactiveProfileIds
-
addProfile
Add aProfile
that has come from an external source. This may be from a custom configuration like the MavenCLI settings.xml file, or from a custom dialog in an IDE integration like M2Eclipse.- Parameters:
profile
-
-
setProfiles
-
getProfiles
-
getBuildStartTime
Deprecated.Gets the start time of the build.- Returns:
- The start time of the build or
null
if unknown.
-
setBuildStartTime
Deprecated.Sets the start time of the build.- Parameters:
buildStartTime
- The start time of the build, may benull
.
-
getBuildStartInstant
Instant getBuildStartInstant()Gets the start time of the build.- Returns:
- The start time of the build or
null
if unknown.
-
setBuildStartInstant
Sets the start time of the build.- Parameters:
buildStartInstant
- The start time of the build, may benull
.
-
getRepositorySession
org.eclipse.aether.RepositorySystemSession getRepositorySession() -
setRepositorySession
ProjectBuildingRequest setRepositorySession(org.eclipse.aether.RepositorySystemSession repositorySession) -
setRepositoryMerging
Sets the merge mode used to combine repositories declared in the POM with the repositories specified in this request.- Parameters:
mode
- The repository merge mode, must not benull
.- Returns:
- This request for chaining, never
null
. - See Also:
-
getRepositoryMerging
ProjectBuildingRequest.RepositoryMerging getRepositoryMerging()Gets the merge mode used to combine repositories declared in the POM with the repositories specified in this request- Returns:
- The merge mode, never
null
.
-
isResolveVersionRanges
Deprecated.This got added when implementing MNG-2199 and is no longer used. Commit 6cf9320942c34bc68205425ab696b1712ace9ba4 updated the way 'MavenProject' objects are initialized.- Since:
- 3.2.2
-
setResolveVersionRanges
Deprecated.This got added when implementing MNG-2199 and is no longer used. Commit 6cf9320942c34bc68205425ab696b1712ace9ba4 updated the way 'MavenProject' objects are initialized.- Since:
- 3.2.2
-