4 Replies Latest reply on Jan 4, 2013 1:53 PM by 806469

    problem to Collections.sort() in jdk1.7.0_06 & jdk1.7.0_09

      Hello friends,
      I just migrated to latest jdk. Before now, I was using jdk1.6.0_04 and now switched to jdk1.7.0_09.
      Here I'm facing a problem with Collections.sort(). I have implemented my comparator and accordingly trying to sort my object list. My object list is not getting sorted with latest jdk.
      Some of you may know this thing, can you help me in the regard.
      some part of code is as shown below

      java.util.Collections.sort(list, mycom);

      class MyComplinkid extends SortDtls implements Comparator{
           public int compare(Object a ,Object b){
                sortdtsale t1 = (sortdtsale) a;
                sortdtsale t2 = (sortdtsale) b;
                double aint,bint;
                aint = t1.LinkID;
                bint = t2.LinkID;
                return (aint < bint ?1:0);