Referencing Resources in Maven Artifacts - highsource/jaxb-tools GitHub Wiki
The URI syntax for Maven artifact resources is as follows:
maven:groupId:artifactId:type:classifier:version!/my/schema.xsd
groupId
is required.artifactId
is required.type
is optional, defaults tojar
.classifier
is optional, default to none.version
is optional if artifact is defined in project dependencies or dependency management.!/
is used as resource delimiter.
A few examples:
maven:org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-tests-episodes-a!/a.xsd
-a.xsd
from the mainmaven-jaxb2-plugin-tests-episodes-a
JAR.maven:org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-tests-episodes-a:jar!/a.xsd
- equivalent to above.maven:org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-tests-episodes-a:jar:!/a.xsd
- equivalent to above.maven:org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-tests-episodes-a:jar::!/a.xsd
- equivalent to above.maven:org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-tests-episodes-a:::!/a.xsd
- equivalent to above.maven:org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-tests-episodes-a:::0.8.1!/a.xsd
- using a specific version, type is defaulted tojar
.maven:org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-tests-episodes-a::sources!/a.xsd
-a.xsd
from the sources JAR.