You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
615 B
17 lines
615 B
package com.fr.plugin.teshe.beans; |
|
|
|
import java.util.Comparator; |
|
|
|
public class OrganUserFullPathComparator implements Comparator { |
|
@Override |
|
public int compare(Object o1, Object o2) { |
|
if (o1 instanceof OrganUserModel && o2 instanceof OrganUserModel) { |
|
OrganUserModel s1 = (OrganUserModel) o1; |
|
OrganUserModel s2 = (OrganUserModel) o2; |
|
if (s1.getFullPathOrder().compareTo(s2.getFullPathOrder()) > 0) return 1; |
|
else if (s1.getFullPathOrder().compareTo(s2.getFullPathOrder()) < 0) return -1; |
|
else return 0; |
|
} |
|
return 0; |
|
} |
|
}
|
|
|