ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 23540] - patch task should have failonerror attribute
Date Fri, 03 Oct 2003 08:43:10 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23540>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23540

patch task should have failonerror attribute





------- Additional Comments From emmanuel.feller@free.fr  2003-10-03 08:43 -------
the simplest way to fix is :

- add the failonerror field with his accessor (get, set)
- create a method on task called _execute() like this :
public void _execute()
{
  try{
    execute()
  }
  catch(BuildException be)
  {
    if (getFailonerror()) throw be;
  }
}

- change the reflective call from execute() to _execute() (if the call fail, it 
could be good to mark the task as deprecated in log, because im my humble 
opinion the third party task should extend Task, and do the execute() call).

So it will set up the behavior for every task wich extend Task.

This is backward compatible ;) and this is backward compatible with task wich 
have already the failonerror field (the test will be done twice but will have 
the expected behavior).

Emmanuel

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message