public int get(long instant) { return iChronology.getDayOfMonth(instant); }
public int get(long instant) { return iChronology.getDayOfMonth(instant); }
/** * @param millis from 1970-01-01T00:00:00Z * @param year precalculated year of millis */ int getDayOfMonth(long millis, int year) { int month = getMonthOfYear(millis, year); return getDayOfMonth(millis, year, month); }
/** * @param millis from 1970-01-01T00:00:00Z * @param year precalculated year of millis */ int getDayOfMonth(long millis, int year) { int month = getMonthOfYear(millis, year); return getDayOfMonth(millis, year, month); }
/** * @param millis from 1970-01-01T00:00:00Z */ int getDayOfMonth(long millis) { int year = getYear(millis); int month = getMonthOfYear(millis, year); return getDayOfMonth(millis, year, month); }
/** * @param millis from 1970-01-01T00:00:00Z */ int getDayOfMonth(long millis) { int year = getYear(millis); int month = getMonthOfYear(millis, year); return getDayOfMonth(millis, year, month); }
int dayToUse = iChronology.getDayOfMonth(instant, thisYear, thisMonth); int maxDay = iChronology.getDaysInYearMonth(yearToUse, monthToUse); if (dayToUse > maxDay) {
int dayToUse = iChronology.getDayOfMonth(instant, thisYear, thisMonth); int maxDay = iChronology.getDaysInYearMonth(yearToUse, monthToUse); if (dayToUse > maxDay) {
/** * Set the Month component of the specified time instant.<p> * If the new month has less total days than the specified * day of the month, this value is coerced to the nearest * sane value. e.g.<p> * 07-31 to month 6 = 06-30<p> * 03-31 to month 2 = 02-28 or 02-29 depending<p> * * @param instant the time instant in millis to update. * @param month the month (1,12) to update the time to. * @return the updated time instant. * @throws IllegalArgumentException if month is invalid */ public long set(long instant, int month) { FieldUtils.verifyValueBounds(this, month, MIN, iMax); // int thisYear = iChronology.getYear(instant); // int thisDom = iChronology.getDayOfMonth(instant, thisYear); int maxDom = iChronology.getDaysInYearMonth(thisYear, month); if (thisDom > maxDom) { // Quietly force DOM to nearest sane value. thisDom = maxDom; } // Return newly calculated millis value return iChronology.getYearMonthDayMillis(thisYear, month, thisDom) + iChronology.getMillisOfDay(instant); }
int i_monthToUse = (int)monthToUse; int dayToUse = iChronology.getDayOfMonth(instant, thisYear, thisMonth); int maxDay = iChronology.getDaysInYearMonth(i_yearToUse, i_monthToUse); if (dayToUse > maxDay) {
int minuendDom = iChronology.getDayOfMonth (minuendInstant, minuendYear, minuendMonth); if (minuendDom == iChronology.getDaysInYearMonth(minuendYear, minuendMonth)) { int subtrahendDom = iChronology.getDayOfMonth (subtrahendInstant, subtrahendYear, subtrahendMonth); if (subtrahendDom > minuendDom) {
/** * Set the Month component of the specified time instant.<p> * If the new month has less total days than the specified * day of the month, this value is coerced to the nearest * sane value. e.g.<p> * 07-31 to month 6 = 06-30<p> * 03-31 to month 2 = 02-28 or 02-29 depending<p> * * @param instant the time instant in millis to update. * @param month the month (1,12) to update the time to. * @return the updated time instant. * @throws IllegalArgumentException if month is invalid */ public long set(long instant, int month) { FieldUtils.verifyValueBounds(this, month, MIN, iMax); // int thisYear = iChronology.getYear(instant); // int thisDom = iChronology.getDayOfMonth(instant, thisYear); int maxDom = iChronology.getDaysInYearMonth(thisYear, month); if (thisDom > maxDom) { // Quietly force DOM to nearest sane value. thisDom = maxDom; } // Return newly calculated millis value return iChronology.getYearMonthDayMillis(thisYear, month, thisDom) + iChronology.getMillisOfDay(instant); }
int i_monthToUse = (int)monthToUse; int dayToUse = iChronology.getDayOfMonth(instant, thisYear, thisMonth); int maxDay = iChronology.getDaysInYearMonth(i_yearToUse, i_monthToUse); if (dayToUse > maxDay) {
int minuendDom = iChronology.getDayOfMonth (minuendInstant, minuendYear, minuendMonth); if (minuendDom == iChronology.getDaysInYearMonth(minuendYear, minuendMonth)) { int subtrahendDom = iChronology.getDayOfMonth (subtrahendInstant, subtrahendYear, subtrahendMonth); if (subtrahendDom > minuendDom) {
public int get(long instant) { return iChronology.getDayOfMonth(instant); }
/** * @param millis from 1970-01-01T00:00:00Z * @param year precalculated year of millis */ int getDayOfMonth(long millis, int year) { int month = getMonthOfYear(millis, year); return getDayOfMonth(millis, year, month); }
/** * @param millis from 1970-01-01T00:00:00Z */ int getDayOfMonth(long millis) { int year = getYear(millis); int month = getMonthOfYear(millis, year); return getDayOfMonth(millis, year, month); }
/** * Set the Month component of the specified time instant.<p> * If the new month has less total days than the specified * day of the month, this value is coerced to the nearest * sane value. e.g.<p> * 07-31 to month 6 = 06-30<p> * 03-31 to month 2 = 02-28 or 02-29 depending<p> * * @param instant the time instant in millis to update. * @param month the month (1,12) to update the time to. * @return the updated time instant. * @throws IllegalArgumentException if month is invalid */ public long set(long instant, int month) { FieldUtils.verifyValueBounds(this, month, MIN, iMax); // int thisYear = iChronology.getYear(instant); // int thisDom = iChronology.getDayOfMonth(instant, thisYear); int maxDom = iChronology.getDaysInYearMonth(thisYear, month); if (thisDom > maxDom) { // Quietly force DOM to nearest sane value. thisDom = maxDom; } // Return newly calculated millis value return iChronology.getYearMonthDayMillis(thisYear, month, thisDom) + iChronology.getMillisOfDay(instant); }
int i_monthToUse = (int)monthToUse; int dayToUse = iChronology.getDayOfMonth(instant, thisYear, thisMonth); int maxDay = iChronology.getDaysInYearMonth(i_yearToUse, i_monthToUse); if (dayToUse > maxDay) {
int minuendDom = iChronology.getDayOfMonth (minuendInstant, minuendYear, minuendMonth); if (minuendDom == iChronology.getDaysInYearMonth(minuendYear, minuendMonth)) { int subtrahendDom = iChronology.getDayOfMonth (subtrahendInstant, subtrahendYear, subtrahendMonth); if (subtrahendDom > minuendDom) {