CalendarController class

利用controller来控制视图

Constructors

CalendarController({CalendarSelectedMode selectMode = CalendarSelectedMode.singleSelect, int showMode = CalendarConstants.MODE_SHOW_ONLY_MONTH, int minYear = 1971, int maxYear = 2055, int minYearMonth = 1, int maxYearMonth = 12, int nowYear, int nowMonth, int minSelectYear = 1971, int minSelectMonth = 1, int minSelectDay = 1, int maxSelectYear = 2055, int maxSelectMonth = 12, int maxSelectDay = 30, Set<DateTime> selectedDateTimeList = EMPTY_SET, DateModel selectDateModel, int maxMultiSelectCount = 9999, Map<DateModel, Object> extraDataMap = EMPTY_MAP, int offset = 0})

Properties

calendarConfiguration CalendarConfiguration
read / write
calendarProvider CalendarProvider
read / write
hashCode int
The hash code for this object. [...]
read-only, inherited
monthController PageController
read / write
monthList List<DateModel>
下面的信息不是配置的
read / write
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
weekController PageController
read / write
weekList List<DateModel>
read / write

Methods

addExpandChangeListener(ValueChanged<bool> expandChange) → void
addMonthChangeListener(OnMonthChange listener) → void
addOnCalendarSelectListener(OnCalendarSelect listener) → void
addOnCalendarUnSelectListener(OnCalendarUnSelect listener) → void
addOnMultiSelectOutOfRangeListener(OnMultiSelectOutOfRange listener) → void
addOnMultiSelectOutOfSizeListener(OnMultiSelectOutOfSize listener) → void
addWeekChangeListener(OnWeekChange listener) → void
changeDefaultSelectedDateList(Set<DateModel> defaultSelectedDateList) → void
changeDefaultSelectedDateModel(DateModel dateModel) → void
changeExtraData(Map<DateModel, Object> newMap) → void
clearData() → void
getCurrentMonth() DateModel
getMultiSelectCalendar() Set<DateModel>
getSingleSelectCalendar() DateModel
moveToCalendar(int year, int month, int day, {bool needAnimation = false, Duration duration = const Duration(milliseconds: 500), Curve curve = Curves.ease}) → void
moveToNextMonth({bool needAnimation = false, Duration duration = const Duration(milliseconds: 500), Curve curve = Curves.ease}) → void
moveToNextYear({bool needAnimation = false, Duration duration = const Duration(milliseconds: 500), Curve curve = Curves.ease}) → void
moveToPreviousMonth({bool needAnimation = false, Duration duration = const Duration(milliseconds: 500), Curve curve = Curves.ease}) → void
moveToPreviousYear({bool needAnimation = false, Duration duration = const Duration(milliseconds: 500), Curve curve = Curves.ease}) → void
nextPage() Future<bool>
月份或者星期的下一页 true:成功 false:是最后一页
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
previousPage() Future<bool>
月份或者星期的上一页
toggleExpandStatus() → void
toString() String
A string representation of this object. [...]
inherited
weekAndMonthViewChange(int showMode) → void

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited

Constants

DEFAULT_DURATION → const Duration
const Duration(milliseconds: 500)
EMPTY_MAP → const Map<DateModel, Object>
{}
EMPTY_SET → const Set<DateTime>
{}