今早又查了一遍API,找到了一个toMillis的方法,返回一个long类型的数据,然后就可以用SimpleDateFormate和Date组合使用了。下面是API原话 public long toMillis()Returns the value in milliseconds. Conversion from a coarser granularity that would numerically overflow saturate to Long.MIN_VALUE if negative or Long.MAX_VALUE if positive.Returns: the value in milliseconds, since the epoch (1970-01-01T00:00:00Z)
public long toMillis()Returns the value in milliseconds.
Conversion from a coarser granularity that would numerically overflow saturate to Long.MIN_VALUE if negative or Long.MAX_VALUE if positive.Returns:
the value in milliseconds, since the epoch (1970-01-01T00:00:00Z)