对list列表中文的拼音排序问题

Comparator cmp = Collator.getInstance(java.util.Locale.CHINA);
public int compareTo(Object obj) //方法 
{
if (obj instanceof QuestionModel) {  
QuestionModel _jcr = (QuestionModel) obj;  
            String arg0 = this.qsName;  
            String arg1 = _jcr.getQsName();  
            return cmp.compare(arg0,arg1);    
        }  
return 0;
}

你可能感兴趣的:(java)