在Java中,long类型没法直接使用==去进行直接比较,blog
但可使用equals或者longValue方法进行比较方法
例如:Long a =5L,Long b=5Lim
比较a与b是否相等,使用a.longValue()==b.longValue()db