arrayList,
分享于 点击 14380 次 点评:175
arrayList,
1、各种排序:
</pre><pre name="code" class="html">@Override
public int compareTo(ResourceInfo o) {
if(o.rid>=this.rid){
return 1;
}
return -1;
}
Collections.sort(list);//顺序排列
System.out.println(list);
Collections.shuffle(list);//混乱的意思
System.out.println(list);
Collections.reverse(list);//倒序排列
System.out.println(list);
相关文章
- 暂无相关文章
用户点评