本文整理汇总了Java中java.time.temporal.ChronoField.EPOCH_DAY属性的典型用法代码示例。如果您正苦于以下问题:Java ChronoField.EPOCH_DAY属性的具体用法?Java ChronoField.EPOCH_DAY怎么用?Java ChronoField.EPOCH_DAY使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类java.time.temporal.ChronoField
的用法示例。
在下文中一共展示了ChronoField.EPOCH_DAY属性的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: data_samples
@DataProvider(name="samples")
Object[][] data_samples() {
return new Object[][] {
{ChronoField.EPOCH_DAY, JAN01_1970, 0L},
{JulianFields.JULIAN_DAY, JAN01_1970, 2400001L + 40587L},
{JulianFields.MODIFIED_JULIAN_DAY, JAN01_1970, 40587L},
{JulianFields.RATA_DIE, JAN01_1970, 710347L + (40587L - 31771L)},
{ChronoField.EPOCH_DAY, DEC31_1969, -1L},
{JulianFields.JULIAN_DAY, DEC31_1969, 2400001L + 40586L},
{JulianFields.MODIFIED_JULIAN_DAY, DEC31_1969, 40586L},
{JulianFields.RATA_DIE, DEC31_1969, 710347L + (40586L - 31771L)},
{ChronoField.EPOCH_DAY, NOV12_1945, (-24 * 365 - 6) - 31 - 30 + 11},
{JulianFields.JULIAN_DAY, NOV12_1945, 2431772L},
{JulianFields.MODIFIED_JULIAN_DAY, NOV12_1945, 31771L},
{JulianFields.RATA_DIE, NOV12_1945, 710347L},
{ChronoField.EPOCH_DAY, JAN01_0001, (-24 * 365 - 6) - 31 - 30 + 11 - 710346L},
{JulianFields.JULIAN_DAY, JAN01_0001, 2431772L - 710346L},
{JulianFields.MODIFIED_JULIAN_DAY, JAN01_0001, 31771L - 710346L},
{JulianFields.RATA_DIE, JAN01_0001, 1},
};
}