ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <>
Subject Re: Scope of Types
Date Tue, 05 Jun 2001 07:53:36 GMT
At 09:36 AM 6/5/01 +0200, Stefan Bodewig wrote:
>Peter Donald <> wrote:
>> Can anyone give a good usecase forsharing type defs between peer
>> projects?
>Your counterargument is sharing values via the ${} syntax doesn't
>require sharing types - but what if you want to share IDs?

whats the difference between IDs and property values?

>Say project A defines a type mailaddressset - a set of email addresses
>to use in the to field of a custom mailreport task.  In project A we
><mailaddressset id="send-report-to">
>  <address to="" />
>  <address to="" />
><target name="mail">
>  <mailreport>
>    <to refid="send-report-to" />
>  </mailreport>
>And now in project B I want to do something like
><projectref name="B">
>  <A:mailaddressset id="send-report-to">
>    <address to="" />
>  </A:mailaddressset>
>as I know Pete is not going to be interested in the reports I generate
>when running it from project B.

In that case it is better to redefine mailaddressset in project B aswell.
Much like if you refer to type URL in a java source file you import it in
the source file. You do not say the type by name of URL imported in source
file X where X is another sourcefile.



| "Faced with the choice between changing one's mind, |
| and proving that there is no need to do so - almost |
| everyone gets busy on the proof."                   |
|              - John Kenneth Galbraith               |

View raw message