ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: Proposal: XML output from ant tasks
Date Thu, 24 Feb 2000 10:07:53 GMT
> I see _lots_ of design problems though:
> 1) a log schema must be established and this is the log format used by
> ant itself. To avoid collisions, we should create namespaces for each
> task... even if this makes XSLT processing more painful.

Same as in ant - each task can define it's own schema, and we can live
without a DTD for a while. Yes, it's not perfect - but it might work
(same as in ant case).

> 2) how do we trigger this? I mean, logs cannot follow the inversion of
> control tasks do: ant is called by the log methods, not the other way
> around. So there is no way to _force_ the output to be structured but it
> depends on task behavior.

My opinion was to just output xml - having both xml and text is far too
complicated.  A task can output an xml fragment instead of it's plain
text, without any pain ( using the current log method ).

It's a choice - each alternative have advantages.

One possible ( but complex ) solution would be to have a:
   log( String tag , Hashtable attributes, String body )

Most tasks will just use 
   log( String tag, String body )

The logger can add few standard attributes to tag ( like timestamp ).

It's not that difficult, and we can still output text.


View raw message