axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sanjiva Weerawarana <>
Subject Re: [axiom] [axis2] Coding style
Date Wed, 07 Mar 2007 06:04:48 GMT
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 Weerawarana, Ph.D.
Founder & Director; Lanka Software Foundation;
Founder, Chairman & CEO; WSO2, Inc.;
Director; Open Source Initiative;
Member; Apache Software Foundation;
Visiting Lecturer; University of Moratuwa;

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message