Package org.miaixz.bus.core.center.date
Class Zodiac
java.lang.Object
org.miaixz.bus.core.center.date.Zodiac
- Since:
- Java 17+
- Author:
- Kimi Liu
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringgetChineseZodiac(int year) 计算生肖,只计算1900年后出生的人static StringgetChineseZodiac(Calendar calendar) 通过生日计算生肖,只计算1900年后出生的人static StringgetChineseZodiac(Date date) 通过生日计算生肖,只计算1900年后出生的人static StringgetZodiac(int month, int day) 通过生日计算星座static String通过生日计算星座static String通过生日计算星座static StringgetZodiac(Fields.Month month, int day) 通过生日计算星座
-
Constructor Details
-
Zodiac
public Zodiac()
-
-
Method Details
-
getZodiac
通过生日计算星座- Parameters:
date- 出生日期- Returns:
- 星座名
-
getZodiac
通过生日计算星座- Parameters:
calendar- 出生日期- Returns:
- 星座名
-
getZodiac
通过生日计算星座- Parameters:
month- 月,从0开始计数day- 天- Returns:
- 星座名
-
getZodiac
通过生日计算星座- Parameters:
month- 月,从0开始计数,见Fields.Month.getValue()day- 天- Returns:
- 星座名
-
getChineseZodiac
通过生日计算生肖,只计算1900年后出生的人- Parameters:
date- 出生日期(年需农历)- Returns:
- 星座名
-
getChineseZodiac
通过生日计算生肖,只计算1900年后出生的人- Parameters:
calendar- 出生日期(年需农历)- Returns:
- 星座名
-
getChineseZodiac
计算生肖,只计算1900年后出生的人- Parameters:
year- 农历年- Returns:
- 生肖名
-