MCPcopy Create free account
hub / github.com/6tail/lunar-java / getXingZuo

Method getXingZuo

src/main/java/com/nlf/calendar/Solar.java:461–488  ·  view source on GitHub ↗

获取星座 @return 星座

()

Source from the content-addressed store, hash-verified

459 * @return 星座
460 */
461 public String getXingZuo() {
462 int index = 11;
463 int y = month * 100 + day;
464 if (y >= 321 && y <= 419) {
465 index = 0;
466 } else if (y >= 420 && y <= 520) {
467 index = 1;
468 } else if (y >= 521 && y <= 621) {
469 index = 2;
470 } else if (y >= 622 && y <= 722) {
471 index = 3;
472 } else if (y >= 723 && y <= 822) {
473 index = 4;
474 } else if (y >= 823 && y <= 922) {
475 index = 5;
476 } else if (y >= 923 && y <= 1023) {
477 index = 6;
478 } else if (y >= 1024 && y <= 1122) {
479 index = 7;
480 } else if (y >= 1123 && y <= 1221) {
481 index = 8;
482 } else if (y >= 1222 || y <= 119) {
483 index = 9;
484 } else if (y <= 218) {
485 index = 10;
486 }
487 return SolarUtil.XINGZUO[index];
488 }
489
490 /**
491 * 获取年份

Callers 14

test1Method · 0.95
test2Method · 0.95
test3Method · 0.95
test4Method · 0.95
test5Method · 0.95
test6Method · 0.95
test7Method · 0.95
test8Method · 0.95
test9Method · 0.95
test10Method · 0.95
test11Method · 0.95
test12Method · 0.95

Calls

no outgoing calls

Tested by 12

test1Method · 0.76
test2Method · 0.76
test3Method · 0.76
test4Method · 0.76
test5Method · 0.76
test6Method · 0.76
test7Method · 0.76
test8Method · 0.76
test9Method · 0.76
test10Method · 0.76
test11Method · 0.76
test12Method · 0.76