public class Zodiac extends Object
| Constructor and Description |
|---|
Zodiac() |
| Modifier and Type | Method and Description |
|---|---|
static String |
getChineseZodiac(Calendar calendar)
通过生日计算生肖,只计算1900年后出生的人
|
static String |
getChineseZodiac(Date date)
通过生日计算生肖,只计算1900年后出生的人
|
static String |
getChineseZodiac(int year)
计算生肖,只计算1900年后出生的人
|
static String |
getZodiac(Calendar calendar)
通过生日计算星座
|
static String |
getZodiac(Date date)
通过生日计算星座
|
static String |
getZodiac(int month,
int day)
通过生日计算星座
|
static String |
getZodiac(Month month,
int day)
通过生日计算星座
|
public static String getZodiac(Calendar calendar)
calendar - 出生日期public static String getZodiac(Month month, int day)
month - 月,从0开始计数day - 天public static String getZodiac(int month, int day)
month - 月,从0开始计数,见Month.getValue()day - 天public static String getChineseZodiac(Date date)
date - 出生日期(年需农历)public static String getChineseZodiac(Calendar calendar)
calendar - 出生日期(年需农历)public static String getChineseZodiac(int year)
year - 农历年Copyright © 2025. All rights reserved.