List of utility methods to do Month
boolean | isNumMonth(int m) is Num Month return m >= 1 && m <= 12;
|
boolean | isQuarterMonth(String[] types) is Quarter Month for (int i = 0; i < types.length; i++) { if (DATE_TIME_LEVEL_TYPE_QUARTER.equals(types[i])) return true; return false; |
boolean | isSameMonth(String preMonth, String month) is Same Month return preMonth.substring(4, 6).equals(month.substring(4, 6));
|
int[] | issueMonth(int issue1, int issue2) issue Month int k = issue1; issue1 = k >= issue2 ? k : issue2; issue2 = k < issue2 ? k : issue2; int months = issueMonthNum(issue1, issue2); int[] intArray = new int[months + 1]; intArray[0] = issue2; intArray[months] = issue1; int year = issue2 / 100; ... |
int | issueMonthNum(int issue1, int issue2) issue Month Num int k = issue1; issue1 = k >= issue2 ? k : issue2; issue2 = k < issue2 ? k : issue2; int yearnum = issue1 / 100 - issue2 / 100; int monthnum = issue1 % 100 - issue2 % 100; if (monthnum < 0) return 12 * (yearnum - 1) + (12 + monthnum); else if (monthnum > 0) ... |
boolean | isValidMonth(int month) is Valid Month return month > 0 && month < 13;
|
boolean | isValidObjectModelMonth(int aMonth) is Valid Object Model Month boolean result = false; if (aMonth > 0 && aMonth < 13) { result = true; } else { result = false; return result; |
boolean | isWeekOfMonth(int num) is Week Of Month return isNumBetween(1, num, 4);
|
int | leapMonth(int y) leap Month return (int) (lunarInfo[y - 1900] & 0xf); |
boolean | lineStartsWithMonthString(String line) line Starts With Month String if (line.length() <= 10) return false; String ll = line.substring(0, 3).toUpperCase(); for (String mm : monthString) { if (ll.startsWith(mm)) return true; return false; ... |