commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Lowe <mel...@gmail.com>
Subject Re: DO NOT REPLY [Bug 32094] - [email] All exceptions seem to be thrown as messagingExceptions
Date Sun, 14 Nov 2004 21:26:54 GMT
I wanted to add a new exception or group of exception for handling
stuff, but didn't want to start submitting patches that would have no
chance of getting commited.

I agree throwing an addressing exception is good (at least use it as a
validation measure). I started playing with having the
UnSupportedexception only when setting the Charset. I don't think i
got around to submitting it.

I think an EmailException would be just the thing, but if one did want
just to wrap the javamail api and use what it provides then setting
the charset to a default and then throwing UnSupportedCharSetexception
only when setCharSet is called.

Then even if catching the UnSupportedCharSetexception it would never be thrown. 

Mark

On 14 Nov 2004 18:29:59 -0000, bugzilla@apache.org <bugzilla@apache.org> wrote:
> DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
> RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
> <http://issues.apache.org/bugzilla/show_bug.cgi?id=32094>.
> ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
> INSERTED IN THE BUG DATABASE.
> 
> http://issues.apache.org/bugzilla/show_bug.cgi?id=32094
> 
> [email] All exceptions seem to be thrown as messagingExceptions
> 
> epugh@upstate.com changed:
> 
>            What    |Removed                     |Added
> ----------------------------------------------------------------------------
>              Status|NEW                         |ASSIGNED
> 
> ------- Additional Comments From epugh@upstate.com  2004-11-14 18:29 -------
> Interesting..  I like the addressexception idea.  However, I don't like that
> adding this starts causing us to throw UnsupportedEncodingException everywhere.
>  The idea of commons-email is to hide the details.
> 
> What do you think of introcucing an org.apache.commons.email.EmailException and
> AddressException extending EmailException?  EmailException could extend
> NestableException, and then anything we need would be put in there.  Regardless
> of wether its an javax.mail.internet.AddressException,
> javax.mail.MessagingException, or UnsupportedEncodingException.
> 
> If you care about what the underlying exception is, then you can dig it out of
> the  NestableException.  Really, the only exceptions I can see most users
> wanting are 1) a bad addresss, 2) some sort of smtp error.  and you could just
> througw EmailException, and then dig the details out if you cared from there..
> 
> ERic
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message