I'm writing a plugin which in part takes as an input groupId:artifactId:version, and interrogates it POM.
In Maven2, there was an option to use MavenProjectBuilder. I could download the pom for the input GAV, and using MavenProjectBuilder, build a MavenProject and thus interrogate all I need from this pom (dependencies, scm tag),开发者_开发知识库 etc.
In Maven3, MavenProjectBuilder is deprecated, and I couldn't find any resource on replacement for it. Usually when you deprecate a class you add @see to help developers use the new class. Maven developers didn't,
Thanks!
Asaf
Though it's not specifically referenced in the 3.0.3 API (as you mentioned), I think org.apache.maven.project.DefaultProjectBuilder (and the interface it implements) is the likely replacement. They seem to have done away with some of the convenience methods.
精彩评论