Here is a small Example of what I would like to achieve:
Maven Artifact A is one of many Webservices and defines a XSD Schema with definitions for Requests and Response
I think your question is reasonable. In the past I have often found that I have a Maven module that needs to do special processing on files that can be found in dependent JARs.
What I have done in the past is to make Artifact B a dependency of Artifact A. Then in the pom.xml of Artifact A I use a special configuration of the Maven dependency plugin as follows:
org.apache.maven.plugins
maven-dependency-plugin
unpack-xsd-files
initialize
unpack
com.mycorp
artifact-b
${artifact-b.version}
jar
**/*.xsd
${project.basedir}/target/xsd-includes
Now your XSD files of interest can be found in the target directory of Artifact A and from there you can do anything you want with them. You can include them as resources, reference them from other XSD files, embed them in your own JARs or whatever! As you can see from the configuration, you also don't have to put them in your target directory; you could put them directly into your /src/main/resources
directory.
You can add this configuration to any Maven module you want so that multiple modules can all work the same way. The nice thing about this approach is that it will also work from with Eclipse via M2Eclipse.