> From: news [mailto:[EMAIL PROTECTED]]On Behalf Of Ulrich Mayring
> In our version of Phoenix (pre 4.0) it was not returning null, but the
> empty string.
> 
> As far as I see it, now it is not possible anymore to distinguish
> between "empty element" (returns "") and "element not 
> present" (returns
> null). Many of our applications use these tests.


It is possible if you use "null" as your default value:

String myVal = config.getAttribute("name", null);
if (myVal == null) throw new NullPointerException("@name");


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

Reply via email to