compareTo比较方法

Java7为所有包装类提供了一个compare方法,比较两个参数值,如果前者大于后者,返回1,等于返回0,小于返回-1

原文地址:https://www.cnblogs.com/huayuxiaoxiang/p/8980863.html