| 程序包 | 说明 |
|---|---|
| com.xkzhangsan.time |
xk-time 是时间转换,时间计算,时间格式化,时间解析,日历,时间cron表达式和时间NLP等的工具,使用Java8,线程安全,简单易用,多达70几种常用日期格式化模板,支持Java8时间类和Date,轻量级,无第三方依赖。
|
| com.xkzhangsan.time.calendar |
日历工具类: CalendarUtil
|
| 限定符和类型 | 方法和说明 |
|---|---|
static LunarDate |
LunarDate.from(Date date)
通过Date创建LunarDate
|
static LunarDate |
LunarDate.from(Instant instant)
通过Instant创建LunarDate
|
static LunarDate |
LunarDate.from(LocalDate localDate)
通过LocalDate创建LunarDate
|
static LunarDate |
LunarDate.from(LocalDateTime localDateTime)
通过LocalDateTime创建LunarDate
|
static LunarDate |
LunarDate.from(Temporal temporal) |
static LunarDate |
LunarDate.now()
以当前时间创建农历日期LunarDate
|
static LunarDate |
LunarDate.of(int lYear,
int lMonth,
int lDay)
根据农历年月日生成农历日期
|
static LunarDate |
LunarDate.of(int lYear,
int lMonth,
int lDay,
boolean isLeapMonth)
根据农历年月日生成农历日期
|
| 限定符和类型 | 方法和说明 |
|---|---|
LunarDate |
DayWrapper.getLunarDate() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
DayWrapper.setLunarDate(LunarDate lunarDate) |
Copyright © 2021. All rights reserved.