Solar class

阳历日期 @author 6tail

Constructors

Solar()
Solar.fromDate(DateTime date)
Solar.fromJulianDay(double julianDay)
Solar.fromYmd(int year, int month, int day)
Solar.fromYmdHms(int year, int month, int day, int hour, int minute, int second)

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

getDay() int
getFestivals() List<String>
获取节日,有可能一天会有多个节日 @return 劳动节等
getHour() int
getJulianDay() double
获取儒略日 @return 儒略日
getLunar() Lunar
getMinute() int
getMonth() int
getOtherFestivals() List<String>
获取非正式的节日,有可能一天会有多个节日 @return 非正式的节日列表,如中元节
getSecond() int
getWeek() int
获取星期,0代表周日,1代表周一 @return 0123456
getWeekInChinese() String
获取星期的中文 @return 日一二三四五六
getXingZuo() String
获取星座 @return 星座
getYear() int
isAfter(Solar solar) bool
isBefore(Solar solar) bool
isLeapYear() bool
next(int days, [bool onlyWorkday = false]) Solar
获取往后推几天的阳历日期,如果要往前推,则天数用负数 @param days 天数 @param onlyWorkday 是否仅限工作日 @return 阳历日期
nextDay(int days) Solar
nextHour(int hours) Solar
nextMonth(int months) Solar
nextYear(int years) Solar
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
subtract(Solar solar) int
subtractMinute(Solar solar) int
toFullString() String
toString() String
A string representation of this object.
override
toYmd() String
toYmdHms() String

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

fromBaZi(String yearGanZhi, String monthGanZhi, String dayGanZhi, String timeGanZhi, {int sect = 2, int baseYear = 1900}) List<Solar>

Constants

J2000 → const double