Re: [axiom] [axis2] Coding style

Sanjiva Weerawarana <[email protected]>
Newsgroups gmane.text.xml.axis.devel,gmane.text.xml.commons.devel
Organization WSO2 Inc.
Message-ID <[email protected]>
Eran Chinthaka wrote:
>> 2) When generating exceptions like this, it really isn't very useful to
>> say "received some other implementation" or "value wasn't what was
>> expected".  It's much more helpful to actually put the problem value
>> into the exception.... In this case it only takes an extra moment to code
>>
>>    "but received " + reason.getClass() + "."
> 
> 
> 1000 appologies for this code written by me some time back. Won't happen
> again :(.

Its not about the code you wrote at all .. its about a pattern of 
development that *EVERYONE* should follow: when throwing an exception give 
all the potentially useful info to the developer. Do not swallow any of it.

Sanjiva.
-- 
Sanjiva Weerawarana, Ph.D.
Founder & Director; Lanka Software Foundation; http://www.opensource.lk/
Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
Director; Open Source Initiative; http://www.opensource.org/
Member; Apache Software Foundation; http://www.apache.org/
Visiting Lecturer; University of Moratuwa; http://www.cse.mrt.ac.lk/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.