On 10/31/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>1)
>the antlib.xml does not set the onerror attribute, this means
>that all the definitions will be loaded when one is loaded,
>using onerror="ignore" should be used.
>("ignore" is a bit of a misnomer - it should be "deferred", i.e.
>the check will be made when the task is first used).

Where is this documented?
Good point!
It is not documented.

<taskdef name="mytask" classname="this.does.not.exist"
             onerror="ignore"

will be accepted ok.
However when used,
<mytask/>
one gets the message:
C:\Documents and Settings\reilly\learning\a\typedef\build.xml:6:
Problem: failed to create task or type mytask
Cause: the class this.does.not.exist was not found.
Action: Check that the component has been correctly declared
.....

The idea of using the value "ignore" in an antlib is to
defer creating the types/tasks until they are used by the
build script - this emulates the built-in tasks/types of
ant and allows thirdparty antlibs to have "optional" types/tasks


Peter



Jan

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



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

Reply via email to