Skip to main content

UICalendarSelectionSingleDateDelegate

Trait UICalendarSelectionSingleDateDelegate 

Source
pub unsafe trait UICalendarSelectionSingleDateDelegate: NSObjectProtocol + MainThreadOnly {
    // Provided methods
    fn dateSelection_didSelectDate(
        &self,
        selection: &UICalendarSelectionSingleDate,
        date_components: Option<&NSDateComponents>,
    )
       where Self: Sized + Message { ... }
    fn dateSelection_canSelectDate(
        &self,
        selection: &UICalendarSelectionSingleDate,
        date_components: Option<&NSDateComponents>,
    ) -> bool
       where Self: Sized + Message { ... }
}
Available on crate feature UICalendarSelectionSingleDate only.
Expand description

Provided Methods§

Source

fn dateSelection_didSelectDate( &self, selection: &UICalendarSelectionSingleDate, date_components: Option<&NSDateComponents>, )
where Self: Sized + Message,

Available on crate feature UICalendarSelection only.

Called after the user selects a date in the calendar view.

Parameter selection: The UICalendarSelectionMultiDate Parameter dateComponents: The date that was selected by the user. dateComponentscan be nilwhen the selected date is deselected by the user.

Source

fn dateSelection_canSelectDate( &self, selection: &UICalendarSelectionSingleDate, date_components: Option<&NSDateComponents>, ) -> bool
where Self: Sized + Message,

Available on crate feature UICalendarSelection only.

Determines if a date is selectable. Dates that are not selectable will be disabled in the calendar view. By default, dateSelection:canSelectDate:returns YES if dateComponents is non-nil.

Parameter selection: The UICalendarSelectionMultiDate Parameter dateComponents: The date to be checked by selection; a nildate represents a deselected date.

Returns: YES if the date can be selected, NO otherwise.

Trait Implementations§

Source§

impl<T> ImplementedBy<T> for dyn UICalendarSelectionSingleDateDelegate

Source§

impl ProtocolType for dyn UICalendarSelectionSingleDateDelegate

Source§

const NAME: &'static str = "UICalendarSelectionSingleDateDelegate"

The name of the Objective-C protocol that this type represents. Read more
Source§

fn protocol() -> Option<&'static AnyProtocol>

Get a reference to the Objective-C protocol object that this type represents. Read more

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<T> UICalendarSelectionSingleDateDelegate for ProtocolObject<T>

Implementors§