本文整理汇总了Java中java.time.chrono.ChronoZonedDateTime.toEpochSecond方法的典型用法代码示例。如果您正苦于以下问题:Java ChronoZonedDateTime.toEpochSecond方法的具体用法?Java ChronoZonedDateTime.toEpochSecond怎么用?Java ChronoZonedDateTime.toEpochSecond使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类java.time.chrono.ChronoZonedDateTime
的用法示例。
在下文中一共展示了ChronoZonedDateTime.toEpochSecond方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: isAfter
import java.time.chrono.ChronoZonedDateTime; //导入方法依赖的package包/类
@Override
public boolean isAfter(ChronoZonedDateTime<?> other) {
long thisEpochSec = toEpochSecond();
long otherEpochSec = other.toEpochSecond();
return thisEpochSec > otherEpochSec
|| (thisEpochSec == otherEpochSec && getTime().getNano() > other.getTime().getNano());
}
开发者ID:kiegroup,项目名称:optashift-employee-rostering,代码行数:9,代码来源:DefaultInterfaceChronoZonedDateTime.java
示例2: isBefore
import java.time.chrono.ChronoZonedDateTime; //导入方法依赖的package包/类
@Override
public boolean isBefore(ChronoZonedDateTime<?> other) {
long thisEpochSec = toEpochSecond();
long otherEpochSec = other.toEpochSecond();
return thisEpochSec < otherEpochSec
|| (thisEpochSec == otherEpochSec && getTime().getNano() < other.getTime().getNano());
}
开发者ID:kiegroup,项目名称:optashift-employee-rostering,代码行数:9,代码来源:DefaultInterfaceChronoZonedDateTime.java
示例3: mockTagValue
import java.time.chrono.ChronoZonedDateTime; //导入方法依赖的package包/类
private TagValue mockTagValue(
final ChronoZonedDateTime<?> min,
final ChronoZonedDateTime<?> max,
final int count
) {
final String value = min.toEpochSecond() * 1000 + "," + max.toEpochSecond() * 1000;
return mockTagValue(value, min, max, count);
}
示例4: isEqual
import java.time.chrono.ChronoZonedDateTime; //导入方法依赖的package包/类
@Override
public boolean isEqual(ChronoZonedDateTime<?> other) {
return toEpochSecond() == other.toEpochSecond() && getTime().getNano() == other.getTime().getNano();
}
开发者ID:kiegroup,项目名称:optashift-employee-rostering,代码行数:6,代码来源:DefaultInterfaceChronoZonedDateTime.java