On Thursday 14 August 2008 08:40, [EMAIL PROTECTED] wrote:
> Author: j16sdiz
> Date: 2008-08-14 07:40:13 +0000 (Thu, 14 Aug 2008)
> New Revision: 21832
>
> Modified:
> trunk/freenet/src/freenet/config/Config.java
> trunk/freenet/src/freenet/config/PersistentConfig.java
> trunk/freenet/src/freenet/config/SubConfig.java
> trunk/freenet/src/freenet/config/WrapperConfig.java
> Log:
> Generic
>
> Modified: trunk/freenet/src/freenet/config/SubConfig.java
> ===================================================================
> --- trunk/freenet/src/freenet/config/SubConfig.java 2008-08-14 07:39:51 UTC
(rev 21831)
> +++ trunk/freenet/src/freenet/config/SubConfig.java 2008-08-14 07:40:13 UTC
(rev 21832)
> @@ -304,15 +304,11 @@
> return prefix;
> }
>
> - public int compareTo(Object o){
> - if((o == null) || !(o instanceof SubConfig)) return 0;
> - else{
> - SubConfig second = (SubConfig) o;
> - if(this.getPrefix().compareTo(second.getPrefix())>0)
> - return 1;
> - else
> - return -1;
> - }
> + public int compareTo(SubConfig second) {
> + if (this.getPrefix().compareTo(second.getPrefix()) > 0)
> + return 1;
> + else
> + return -1;
> }Why doesn't this break Comparable ?
pgpebClAp7Ody.pgp
Description: PGP signature
_______________________________________________ Devl mailing list [email protected] http://emu.freenetproject.org/cgi-bin/mailman/listinfo/devl
