本文整理了Java中org.threeten.bp.LocalDate.lengthOfMonth()
方法的一些代码示例,展示了LocalDate.lengthOfMonth()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。LocalDate.lengthOfMonth()
方法的具体详情如下:
包路径:org.threeten.bp.LocalDate
类名称:LocalDate
方法名:lengthOfMonth
[英]Returns the length of the month represented by this date.
This returns the length of the month in days. For example, a date in January would return 31.
[中]返回此日期表示的月份长度。
这将返回月份的长度(以天为单位)。例如,1月份的日期将返回31。
代码示例来源:origin: prolificinteractive/material-calendarview
private int getWeekCountBasedOnMode() {
int weekCount = calendarMode.visibleWeeksCount;
final boolean isInMonthsMode = calendarMode.equals(CalendarMode.MONTHS);
if (isInMonthsMode && mDynamicHeightEnabled && adapter != null && pager != null) {
final LocalDate cal = adapter.getItem(pager.getCurrentItem()).getDate();
final LocalDate tempLastDay = cal.withDayOfMonth(cal.lengthOfMonth());
weekCount = tempLastDay.get(WeekFields.of(firstDayOfWeek, 1).weekOfMonth());
}
return showWeekDays ? weekCount + DAY_NAMES_ROW : weekCount;
}
代码示例来源:origin: ThreeTen/threetenbp
@Override
public int lengthOfMonth() {
return isoDate.lengthOfMonth();
}
代码示例来源:origin: ThreeTen/threetenbp
@Override
public int lengthOfMonth() {
return isoDate.lengthOfMonth();
}
代码示例来源:origin: org.threeten/threetenbp
@Override
public int lengthOfMonth() {
return isoDate.lengthOfMonth();
}
代码示例来源:origin: org.threeten/threetenbp
@Override
public int lengthOfMonth() {
return isoDate.lengthOfMonth();
}
代码示例来源:origin: org.threeten/threetenbp
@Override
public int lengthOfMonth() {
return isoDate.lengthOfMonth();
}
代码示例来源:origin: ThreeTen/threetenbp
@Override
public int lengthOfMonth() {
return isoDate.lengthOfMonth();
}
代码示例来源:origin: shrikanth7698/Collapsible-Calendar-View-Android
int lastDayOfMonth = mCal.lengthOfMonth();
DayOfWeek firstDayOfWeek = mCal.getDayOfWeek();
numDay = tempCal.lengthOfMonth() + i;
} else if (i > lastDayOfMonth) { // next month
if (month == DECEMBER.getValue()) {
代码示例来源:origin: ThreeTen/threetenbp
} else if (totalMonths < 0 && days > 0) {
totalMonths++;
days -= end.lengthOfMonth();
代码示例来源:origin: org.threeten/threetenbp
} else if (totalMonths < 0 && days > 0) {
totalMonths++;
days -= end.lengthOfMonth();
代码示例来源:origin: ThreeTen/threetenbp
if (f.isDateBased()) {
switch (f) {
case DAY_OF_MONTH: return ValueRange.of(1, lengthOfMonth());
case DAY_OF_YEAR: return ValueRange.of(1, lengthOfYear());
case ALIGNED_WEEK_OF_MONTH: return ValueRange.of(1, getMonth() == Month.FEBRUARY && isLeapYear() == false ? 4 : 5);
代码示例来源:origin: org.threeten/threetenbp
if (f.isDateBased()) {
switch (f) {
case DAY_OF_MONTH: return ValueRange.of(1, lengthOfMonth());
case DAY_OF_YEAR: return ValueRange.of(1, lengthOfYear());
case ALIGNED_WEEK_OF_MONTH: return ValueRange.of(1, getMonth() == Month.FEBRUARY && isLeapYear() == false ? 4 : 5);
内容来源于网络,如有侵权,请联系作者删除!