public class CalendarSelectionManager extends Object
Constructor and Description |
---|
CalendarSelectionManager(RadCalendarView owner)
Creates a new instance of the
CalendarSelectionManager class. |
Modifier and Type | Method and Description |
---|---|
RadCalendarView.OnSelectedDatesChangedListener |
getOnSelectedDatesChangedListener()
Gets the current listener for date selection change.
|
List<Long> |
getSelectedDates()
Returns a list of dates that are currently selected.
|
DateRange |
getSelectedRange()
Returns an instance of type
DateRange
that represent the current selection if the current
CalendarSelectionMode is Range . |
void |
handleTapGesture(CalendarDayCell calendarCell)
Handles the tap gesture associated with the passed cell.
|
List<CalendarDayCell> |
selectedCells()
The current collection of selected cells.
|
void |
setOnSelectedDatesChangedListener(RadCalendarView.OnSelectedDatesChangedListener listener)
Sets the current listener for date selection change.
|
void |
setSelectedDates(List<Long> selectedDates)
Sets a list of dates as selected.
|
void |
setSelectedRange(DateRange range)
Sets the selection to the range passed as a parameter if the current
CalendarSelectionMode is Range . |
void |
syncSelectedCellsWithDates()
Used to sync the selected dates with the corresponding cells.
|
public CalendarSelectionManager(RadCalendarView owner)
CalendarSelectionManager
class.owner
- the calendar owning this instance.public List<Long> getSelectedDates()
public void setSelectedDates(List<Long> selectedDates)
CalendarSelectionMode
.selectedDates
- a list of dates that will be selectedgetSelectionMode()
public DateRange getSelectedRange()
DateRange
that represent the current selection if the current
CalendarSelectionMode
is Range
.IllegalStateException
- If the current selection mode is not Range
public void setSelectedRange(DateRange range)
CalendarSelectionMode
is Range
.range
- date range to be selectedIllegalStateException
- If the current selection mode is not Range
public RadCalendarView.OnSelectedDatesChangedListener getOnSelectedDatesChangedListener()
public void setOnSelectedDatesChangedListener(RadCalendarView.OnSelectedDatesChangedListener listener)
listener
- the new listener.public List<CalendarDayCell> selectedCells()
public void handleTapGesture(CalendarDayCell calendarCell)
calendarCell
- the cell that was affected by the gesturepublic void syncSelectedCellsWithDates()