--- Adam Murdoch <[EMAIL PROTECTED]> wrote: > > > > From: Jose Alberto Fernandez > > As for clashes, there are several things that need > to be done: > > > > 1) Buildfiles should execute on a stable > environment i.e., no auto-install > > but all libraries (appart from core) should be > declared on the buildfile. > > > > This doesn't really solve the problem, just makes it > less likely to happen. Which just makes having to > declare stuff an inconvenience. The real solution > is 2) and 3) below. >
The importance of (1) is that it allows you to make sure your buildfile will work no matter what the developer has installed in the machine. Remember buildfiles are a share resource for all the developers in the project, it has to work correctly as long as any required tasklib is available and even if a developer has additional tasklibs for other projects. > Perhaps a good compromise would be no auto-install > and an <import-all/> task. > On a tipical buildfile, how many different tasklibs do you think people will be using? 1, 2, 100? I bet the number will be in the low range for most cases. And if not, you can always import or include the file containing the declarations. I do not see people screeming about imports in Java. > > 2) The container should detect clashes by looking > at all possible > > role registries > > that may apply. This can be done quite > efficiently. > > > > Definitely a good thing - the container should bail > on a clash. > Yes! > > 3) A clash resolution mechanism should be > provided, posibly using > > aspects to > > indicate the expected role to be used in a > particular occurrance. > > Its really up to the user (build file writer) to > sort out the ambiguity. There's not much Ant > (configurer, aspect, or otherwise) can do except try > to guess. > OK, I may be using the term aspect wrongly. What I meant was that the user could write something like this to solve the conflict: <task1> <a/> <b ant:role="task" /> </task1> 'ant:role' is not an attribute for the task, but for the confgurator to know how to resolve the conflict. I thought this is a use of aspect, the same way we have discussed how to deal with failonerror (i.e., ant:failonerror="true"). Jose Alberto __________________________________________________ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
