ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Craeg K Strong <>
Subject Re: [TASTE QUESTION] Enhance style task or enhance merge mapper/uptodate task?
Date Thu, 21 Jun 2001 16:45:03 GMT
Jose Alberto Fernandez wrote:

>>>Note that these dependencies may not actually be _computable_ --
>>>rather they are simply asserted.
>>But this doesn't exclusively apply to <style>.  Say I have Java code
>>that uses a different class via reflection - neither <javac> nor
>><depend> will catch this.
>>For this situation I've been playing with the idea of
>><explicit-depend src="foo" dest="bar">
>>  <dependency target="targetfile">
>>    <source name="source1" />
>>    <source name="source2" />
>>  </dependency>
>>which would - similar to depend - delete bar/targetfile if foo/source1
>>or foo/source2 is newer than that.
>>This would help in more than just these situations but could be used
>>to support the more generic tasks we have in several other fields.
Agreed.  However, this may still necessitate some small enhancements in 
our mappers
and such.   For example, I don't believe it is possible (today) to 
concisely state the following:

if _any_ of the files ${foo}/**/*.xml and ${bar}/baz/l-*.xml  are older 

${schema.dir}/myschema.xsd, ${dtd.dir}/mydtd.dtd, OR ${xsl.dir}/common.xsl

There is no reason we shouldn't be able to express this kind of 
dependency, ne c'est pas?

>It would be nice if we could define this in a more general way as a sort of
>dependency pattern. The idea being that you can define them and then add it
>as references to <depend>-like tasks that are specific to the particular
>	<depend> for java code;
>	<cc> which does its own dependency analysis; etc
Sounds good.

One question:   will this require some kind of enhancement to
a certain class of Tasks?  Namely, those tasks for which one might want 
to define a dependset?
Were you thinking of defining a new base class that inherits from 
MatchingTask but with
the added capability to accept references to dependsets?  

>This task would handle several dependencies at once (I'd translate all
>source tags to includes in a fileset with dir "src" and create a
>single mapper from all dependency rules).
>who doesn't really like the name explicit-depend.

>If it where some kind of pattern, then it may be better called <dependset>
>or something like that.

>Jose Alberto

Craeg K. Strong                               |
Ariel Partners LLC		              | 
85 River Street, Ste. 3A                      | Fax:      (781) 647-9690
Waltham, MA 02453                             | Voice:    (781) 647-2425

View raw message