Package org.apache.maven.impl
Class DefaultDependencyCoordinates
java.lang.Object
org.apache.maven.impl.DefaultDependencyCoordinates
- All Implemented Interfaces:
org.apache.maven.api.ArtifactCoordinates,org.apache.maven.api.DependencyCoordinates
public class DefaultDependencyCoordinates
extends Object
implements org.apache.maven.api.DependencyCoordinates
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultDependencyCoordinates(InternalSession session, org.eclipse.aether.graph.Dependency dependency) -
Method Summary
Modifier and TypeMethodDescriptionReturns the artifact identifier of the wrapped dependency.Returns the classifier ("jar", "test-jar", …) of the wrapped dependency.Collection<org.apache.maven.api.Exclusion> Returns the file extension of the wrapped dependency.Returns the group identifier of the wrapped dependency.org.apache.maven.api.DependencyScopegetScope()Returns the scope (compile, test, …) of this dependency.org.apache.maven.api.TypegetType()Returns the type of the wrapped dependency.org.apache.maven.api.VersionConstrainttoString()Returns a string representation of this dependency.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.maven.api.ArtifactCoordinates
getArtifactId, getClassifier, getExtension, getGroupId, getIdMethods inherited from interface org.apache.maven.api.DependencyCoordinates
getScope, getType
-
Constructor Details
-
DefaultDependencyCoordinates
public DefaultDependencyCoordinates(@Nonnull InternalSession session, @Nonnull org.eclipse.aether.graph.Dependency dependency)
-
-
Method Details
-
getVersionConstraint
public org.apache.maven.api.VersionConstraint getVersionConstraint()- Specified by:
getVersionConstraintin interfaceorg.apache.maven.api.ArtifactCoordinates
-
getOptional
- Specified by:
getOptionalin interfaceorg.apache.maven.api.DependencyCoordinates
-
getExclusions
- Specified by:
getExclusionsin interfaceorg.apache.maven.api.DependencyCoordinates
-
getGroupId
Returns the group identifier of the wrapped dependency. The default implementation delegates to the Eclipse Aether artifact.- Returns:
- the group identifier of the wrapped dependency
-
getArtifactId
Returns the artifact identifier of the wrapped dependency. The default implementation delegates to the Eclipse Aether artifact.- Returns:
- the artifact identifier of the wrapped dependency
-
getExtension
Returns the file extension of the wrapped dependency. The default implementation delegates to the Eclipse Aether artifact.- Returns:
- the file extension of the wrapped dependency
-
getType
public org.apache.maven.api.Type getType()Returns the type of the wrapped dependency. The default implementation infers the type from the properties associated to the Eclipse Aether artifact.- Returns:
- the type of the wrapped dependency
-
getClassifier
Returns the classifier ("jar", "test-jar", …) of the wrapped dependency. The default implementation first delegates to the Eclipse Aether artifact. If the latter does not provide a non-empty classifier, then the default value is determined by type.- Returns:
- the classifier ("jar", "test-jar", …) of the wrapped dependency
-
getScope
@Nonnull public org.apache.maven.api.DependencyScope getScope()Returns the scope (compile, test, …) of this dependency.- Returns:
- the scope (compile, test, …) of this dependency
-
toString
Returns a string representation of this dependency. This is for debugging purposes only and may change in any future version.
-