Package org.infinispan.commons.maven
Class MavenArtifact
java.lang.Object
org.infinispan.commons.maven.AbstractArtifact
org.infinispan.commons.maven.MavenArtifact
- All Implemented Interfaces:
Artifact
Maven artifact coordinate specification.
- Author:
- David M. Lloyd
-
Field Summary
Fields inherited from class org.infinispan.commons.maven.AbstractArtifact
force, verbose
-
Constructor Summary
ConstructorDescriptionMavenArtifact
(String groupId, String artifactId, String version) Construct a new instance with an empty classifier.MavenArtifact
(String groupId, String artifactId, String version, String classifier) Construct a new instance. -
Method Summary
Modifier and TypeMethodDescriptionstatic MavenArtifact
fromString
(String string) Parse a string and produce artifact coordinates from it.static boolean
isMavenArtifact
(String string) relativeArtifactPath
(char separator) Create a relative repository path for the given artifact coordinates.toString()
Get the string representation.Methods inherited from class org.infinispan.commons.maven.AbstractArtifact
downloadFile, force, getFilenameFromURL, verbose
-
Constructor Details
-
MavenArtifact
Construct a new instance.- Parameters:
groupId
- the group ID (must not benull
)artifactId
- the artifact ID (must not benull
)version
- the version string (must not benull
)classifier
- the classifier string (must not benull
, may be empty)
-
MavenArtifact
Construct a new instance with an empty classifier.- Parameters:
groupId
- the group ID (must not benull
)artifactId
- the artifact ID (must not benull
)version
- the version string (must not benull
)
-
-
Method Details
-
fromString
Parse a string and produce artifact coordinates from it.- Parameters:
string
- the string to parse (must not benull
)- Returns:
- the artifact coordinates object (not
null
)
-
isMavenArtifact
-
resolveArtifact
- Throws:
IOException
-
relativeArtifactPath
Create a relative repository path for the given artifact coordinates.- Parameters:
separator
- the separator character to use (typically'/'
orFile.separatorChar
)- Returns:
- the path string
-
toString
Get the string representation.
-