John Casey wrote:
so, how do you gain access to the custom section? Would you have to
re-parse the whole pom? Also, would <custom/> be subject to any sort of
inheritance, or would it simply be invisible to the project builder?
Think the most convenient would to put the Xpp3DOM object in the
MavenProject so that you could gain raw access to anything in the
document. That would probably require a change to modello so that you
didn't have to parse it twice
I think some simple attributes for indicating whether you want an
element aggregated or overridden would do the trick for inheritance. So
each MavenProject gets the built up custom Xpp3Dom and then, at first,
plug-ins do whatever they want with the information. Even if we were to
use something like RDF (as some are suggesting on IRC) you would need a
general way to get at the XML to process it. We could probably have an
abstract plug-in or tool that did our standard Xpp3Dom -> object model
mapping to make it easier. But I think that would pretty much do it.
Maybe for 2.1 (or 2.2) we could do RDF but I think this allows some
flexibility in the meantime allows us to get some extensions in without
having to formalize the model. If we stick with the one <custom/>
element we could probably think now about how this could map to RDF or
namespace use if we go that way. So it works now and can be mapped to
whatever we might use in the future if we decide to go RDF/namespaces.
-john
Jason van Zyl wrote:
Jason van Zyl wrote:
Hi,
For some reason I thought that the strictness in model parsing had
been turned off. I was playing around trying to add a <custom/>
element and noticed it is still on.
Can we enable the lax parsing in order to make the POM extensible?
The POM will will still be validated at the object model level so
this shouldn't cause any grief. I just want to put this on the trunk
and maybe push out in the next point release.
I turned off strict parsing and could bootstrap no problem with this
in the Maven top-level POM:
<project>
...
<custom>
<categories>
<category>Build Tools<category>
</categories>
<tags>
<tag>Project Management</tag>
<tag>Build Management</tag>
</tags>
<downloadSite>http://maven.apache.org/download.html</downloadSite>
</custom>
...
</project>
This these little blurbs I'm trying to make a baby CodeZoo
(http://www.codezoo.org) and a DOAP file generator plugin. We have
most of the bits needed for DOAP but we're missing a couple things.
All sorts of cool stuff we could do!
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
jvz.
Jason van Zyl
jason at maven.org
http://maven.apache.org
Three people can keep a secret provided two of them are dead.
-- Unknown
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]