Package org.apache.maven.api.model
Class DistributionManagement
java.lang.Object
org.apache.maven.api.model.DistributionManagement
- All Implemented Interfaces:
Serializable,InputLocationTracker
@Experimental
@Generated
@ThreadSafe
@Immutable
public class DistributionManagement
extends Object
implements Serializable, InputLocationTracker
This elements describes all that pertains to distribution for a project. It is
primarily used for deployment of artifacts and the site produced by the build.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classBuilder class used to create DistributionManagement instances. -
Method Summary
Modifier and TypeMethodDescriptionThe URL of the project's download page.getLocation(Object key) Gets the location of the specified field in the input source.Relocation information of the artifact if it has been moved to a new group ID and/or artifact ID.Information needed to deploy the artifacts generated by the project to a remote repository.getSite()Information needed for deploying the web site of the project.Where to deploy snapshots of artifacts to.Gives the status of this artifact in the remote repository.Creates a newDistributionManagementbuilder instance.newBuilder(boolean withDefaults) Creates a newDistributionManagementbuilder instance using default values or not.Creates a newDistributionManagementbuilder instance using the specified object as a basis.newBuilder(DistributionManagement from, boolean forceCopy) Creates a newDistributionManagementbuilder instance using the specified object as a basis.static DistributionManagementCreates a newDistributionManagementinstance.static DistributionManagementnewInstance(boolean withDefaults) Creates a newDistributionManagementinstance using default values or not.with()Creates a new builder with this object as the basis.withDownloadUrl(String downloadUrl) Creates a newDistributionManagementinstance using the specified downloadUrl.withRelocation(Relocation relocation) Creates a newDistributionManagementinstance using the specified relocation.withRepository(DeploymentRepository repository) Creates a newDistributionManagementinstance using the specified repository.Creates a newDistributionManagementinstance using the specified site.withSnapshotRepository(DeploymentRepository snapshotRepository) Creates a newDistributionManagementinstance using the specified snapshotRepository.withStatus(String status) Creates a newDistributionManagementinstance using the specified status.
-
Method Details
-
getRepository
Information needed to deploy the artifacts generated by the project to a remote repository.- Returns:
- a
DeploymentRepository
-
getSnapshotRepository
Where to deploy snapshots of artifacts to. If not given, it defaults to therepositoryelement.- Returns:
- a
DeploymentRepository
-
getSite
Information needed for deploying the web site of the project.- Returns:
- a
Site
-
getDownloadUrl
The URL of the project's download page. If not given users will be referred to the homepage given byurl. This is given to assist in locating artifacts that are not in the repository due to licensing restrictions.- Returns:
- a
String
-
getRelocation
Relocation information of the artifact if it has been moved to a new group ID and/or artifact ID.- Returns:
- a
Relocation
-
getStatus
Gives the status of this artifact in the remote repository. This must not be set in your local project, as it is updated by tools placing it in the repository. Valid values are:none(default),converted(repository manager converted this from an Maven 1 POM),partner(directly synced from a partner Maven 2 repository),deployed(was deployed from a Maven 2 instance),verified(has been hand verified as correct and final).- Returns:
- a
String
-
getLocation
Gets the location of the specified field in the input source.- Specified by:
getLocationin interfaceInputLocationTracker
-
with
Creates a new builder with this object as the basis.- Returns:
- a
Builder
-
withRepository
Creates a newDistributionManagementinstance using the specified repository.- Parameters:
repository- the newDeploymentRepositoryto use- Returns:
- a
DistributionManagementwith the specified repository
-
withSnapshotRepository
@Nonnull public DistributionManagement withSnapshotRepository(DeploymentRepository snapshotRepository) Creates a newDistributionManagementinstance using the specified snapshotRepository.- Parameters:
snapshotRepository- the newDeploymentRepositoryto use- Returns:
- a
DistributionManagementwith the specified snapshotRepository
-
withSite
Creates a newDistributionManagementinstance using the specified site.- Parameters:
site- the newSiteto use- Returns:
- a
DistributionManagementwith the specified site
-
withDownloadUrl
Creates a newDistributionManagementinstance using the specified downloadUrl.- Parameters:
downloadUrl- the newStringto use- Returns:
- a
DistributionManagementwith the specified downloadUrl
-
withRelocation
Creates a newDistributionManagementinstance using the specified relocation.- Parameters:
relocation- the newRelocationto use- Returns:
- a
DistributionManagementwith the specified relocation
-
withStatus
Creates a newDistributionManagementinstance using the specified status.- Parameters:
status- the newStringto use- Returns:
- a
DistributionManagementwith the specified status
-
newInstance
Creates a newDistributionManagementinstance. Equivalent tonewInstance(true).- Returns:
- a new
DistributionManagement - See Also:
-
newInstance
Creates a newDistributionManagementinstance using default values or not. Equivalent tonewBuilder(withDefaults).build().- Parameters:
withDefaults- the boolean indicating whether default values should be used- Returns:
- a new
DistributionManagement
-
newBuilder
Creates a newDistributionManagementbuilder instance. Equivalent tonewBuilder(true).- Returns:
- a new
Builder - See Also:
-
newBuilder
Creates a newDistributionManagementbuilder instance using default values or not.- Parameters:
withDefaults- the boolean indicating whether default values should be used- Returns:
- a new
Builder
-
newBuilder
Creates a newDistributionManagementbuilder instance using the specified object as a basis. Equivalent tonewBuilder(from, false).- Parameters:
from- theDistributionManagementinstance to use as a basis- Returns:
- a new
Builder
-
newBuilder
@Nonnull public static DistributionManagement.Builder newBuilder(DistributionManagement from, boolean forceCopy) Creates a newDistributionManagementbuilder instance using the specified object as a basis.- Parameters:
from- theDistributionManagementinstance to use as a basisforceCopy- the boolean indicating if a copy should be forced- Returns:
- a new
Builder
-