Hello
Le 2023-12-19 à 10 h 10, Tamás Cservenák a écrit :
These are all good questions. Ideally I'd not touch maven-artifact,
rather all should be usable with the new Maven API. For example: in
new Api there is Project, and DependencyResolver service, it does not
help? (by revealing properties?)
Thanks for your reply. I just had a look to DependencyResolver. Can you
confirm if my understanding is right, and point me to the right approach
if not?
* org.apache.maven.project.MavenProject is the place where the
classpath is built. This is the crucial part of this work, I'm
looking for a central place which does the analysis of dependency
properties and build class-path, module-path, doclet-path,
agent-path, processor-path, etc. from them.
* org.apache.maven.api.services.DependencyResolver has "resolve"
methods which provide dependency properties through the
DependencyResolverResult → Node → Dependency → DependencyProperties
path.
However in MavenProject (if it is the right place where to build
class-path, module-path, etc.), I see no DependencyResolver,
DependencyResolverResult or Node. How do I make the link?
Regarding the separation between "maven-artifact" and "maven-api-core"
modules, I see that both of them define their own Artifact interface:
* org.apache.maven.artifact.Artifact
* org.apache.maven.api.Artifact
Somewhere there is code that copy data from one structure to the other.
Wouldn't it be simpler to have only one interface?
Martin