You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by Trustin Lee <tr...@gmail.com> on 2005/12/28 06:46:26 UTC
Re: svn commit: r359403 - in /directory/trunk/mina-core: ./ src/main/java/org/apache/mina/filter/ src/main/java/org/apache/mina/filter/codec/textline/ src/main/java/org/apache/mina/util/ src/test/java/org/apache/mina/util/
2005/12/28, akarasulu@apache.org <ak...@apache.org>:
>
> - throw new IllegalArgumentException(
> - "Collection of addresses must contain only " +
> - "InetAddress instances", ase );
> + String msg = "Collection of addresses must contain only
> InetAddress instances";
> + log.error( msg, ase );
> + throw new IllegalArgumentException( msg );
What about this?
throw ( IllegalArgumentException ) new IllegalArgumentException( ...
).initCause( ase );
Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/
PGP Key ID: 0x854B996C
Re: svn commit: r359403 - in /directory/trunk/mina-core: ./ src/main/java/org/apache/mina/filter/
src/main/java/org/apache/mina/filter/codec/textline/ src/main/java/org/apache/mina/util/
src/test/java/org/apache/mina/util/
Posted by Alex Karasulu <ao...@bellsouth.net>.
Trustin Lee wrote:
> 2005/12/28, akarasulu@apache.org <ma...@apache.org>
> <akarasulu@apache.org <ma...@apache.org>>:
>
> - throw new IllegalArgumentException(
> - "Collection of addresses must contain only " +
> - "InetAddress instances", ase );
> + String msg = "Collection of addresses must contain
> only InetAddress instances";
> + log.error( msg, ase );
> + throw new IllegalArgumentException( msg );
>
>
> What about this?
>
> throw ( IllegalArgumentException ) new IllegalArgumentException( ...
> ).initCause( ase );
Much better ... did not know it existed and was available in 1.3. Will
add it.
Thanks,
Alex