将此 DateTimeOffset 对象与其他 DateTimeOffset 对象基于采用 GMT 的时间进行比较。
语法
返回值
下表介绍了此方法的返回值:
返回值 | 说明 |
---|---|
0 |
两个 DateTimeOffset 对象都表示相同的时间点。 |
负数 |
此 DateTimeOffset 对象表示在 other 之前的时间点。 |
正数 |
此 DateTimeOffset 对象表示在 other 之后的时间点。 |
备注
当两个 DateTimeOffset 对象具有相同的按照 GMT 的时间时,没有基于偏移量的对象的附加排序。