Sort 2-dimensional String array on Android
I want to sort a 2-dimensional String array like this
"xx", "text 1"
"aa", "text 2"
"mm", "text 3"
to look like this
"aa", "text 2"
"mm"开发者_开发知识库, "text 3"
"xx", "text 1"
I have already found a method to do this in Java, but this won't work on Android (at least not with 1.6, which is necessary for me), because columnComparator
is not available.
Does anyone know how to do this?
ColumnComparator is that guy's own class that he's created by extending Comparator. Do the same and it will work for you !
精彩评论