ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 4752] Make Ant report an error when an undefined property is referenced.
Date Thu, 30 Oct 2008 14:33:02 GMT

--- Comment #4 from Ville Oikarinen <>  2008-10-30 07:33:01 PST ---
Thanks Matt, but we are not there yet.

The apidoc at,

seems to point at the method responsible for resolving a property. But the
contract seems to be to return null for undefined properties.

Maybe I should overrid this method like this:
public java.lang.Object getUserProperty(java.lang.String ns,
                                        java.lang.String name) {
  Object retval = super.getUserProperty(ns,name);
  if(retval == null) throw new SomeException();
  else return retval;

How will this contract violation work (now and in the future)? What should
SomeException be? Etc. Seems that it's the caller's responsibility to handle
null in a different way.

Besides, the apidoc starts with "NOT FINAL. API MAY CHANGE". Doesn't sound like
fun to customize this, does it :)

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

View raw message