Peter,

your fix below looks funny (but maybe I am out of context)
You seem to pass a parameter called instance but set a value self not
mentioned.
Is that correct?

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
...
>   Index: ScriptDef.java
>   ===================================================================
>   RCS file: 
> /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/optional/
> script/ScriptDef.java,v
>   retrieving revision 1.13
>   retrieving revision 1.14
>   diff -u -r1.13 -r1.14
>   --- ScriptDef.java  23 Apr 2004 14:18:15 -0000      1.13
>   +++ ScriptDef.java  7 Jul 2004 08:32:02 -0000       1.14
>   @@ -307,13 +307,30 @@
>         * Execute the script.
>         *
>         * @param attributes collection of attributes
>   -     *
>         * @param elements a list of nested element values.
>   +     * @deprecated use executeScript(attribute, elements, 
> instance) instead
>         */
>        public void executeScript(Map attributes, Map elements) {
>            runner.addBean("attributes", attributes);
>            runner.addBean("elements", elements);
>            runner.addBean("project", getProject());
>   +        runner.executeScript("scriptdef_" + name);
>   +    }
>   +
>   +    /**
>   +     * Execute the script.
>   +     * This is called by the script instance to execute 
> the script for this
>   +     * definition.
>   +     *
>   +     * @param attributes collection of attributes
>   +     * @param elements   a list of nested element values.
>   +     * @param instance   the script instance
>   +     */
>   +    public void executeScript(Map attributes, Map 
> elements, ScriptDefBase instance) {
>   +        runner.addBean("attributes", attributes);
>   +        runner.addBean("elements", elements);
>   +        runner.addBean("project", getProject());
>   +        runner.addBean("self", self);
>            runner.executeScript("scriptdef_" + name);
>        }

The last "+" line is the one that looks funny. Do not have a full CVS at
hand
so I may have missed something.

Jose Alberto

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to