[jdom-interest] [Vote] NoSuchChildException

Elliotte Rusty Harold elharo at metalab.unc.edu
Thu Jul 13 04:53:43 PDT 2000

At 8:24 PM -0700 7/12/00, Randall Parker wrote:
>Do you oppose the use of default values within the DTD itself?

Default values in the DTD are genuine defaults. That's how I was 
thinking the below method would be used. That's fine. It's only 
defaults used as error messages that are a problem.

>>>Excellent reasoning! So since we all know people are going to be enraged
>>>by this ;-), do you also feel we should not provide:
>>>public Element getChild(String name, Element defaultValue);
>>I hadn't thought of that method that way. I was thinking that people
>>would provide the defaultValue as something they could use if there
>>was no child, not as a simple error flag. But if it's just an error
>>flag, then yes, I would say we shouldn't provide that method.

| Elliotte Rusty Harold | elharo at metalab.unc.edu | Writer/Programmer |
|                  The XML Bible (IDG Books, 1999)                   |
|              http://metalab.unc.edu/xml/books/bible/               |
|   http://www.amazon.com/exec/obidos/ISBN=0764532367/cafeaulaitA/   |
|  Read Cafe au Lait for Java News:  http://metalab.unc.edu/javafaq/ |
|  Read Cafe con Leche for XML News: http://metalab.unc.edu/xml/     |

More information about the jdom-interest mailing list