objc2-ui-kit 0.2.2

Bindings to the UIKit framework
Documentation
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use objc2::__framework_prelude::*;
#[cfg(feature = "objc2-core-location")]
use objc2_core_location::*;
use objc2_foundation::*;

use crate::*;

extern_class!(
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
    pub struct UILocalNotification;

    unsafe impl ClassType for UILocalNotification {
        type Super = NSObject;
        type Mutability = MainThreadOnly;
    }
);

unsafe impl NSCoding for UILocalNotification {}

unsafe impl NSCopying for UILocalNotification {}

unsafe impl NSObjectProtocol for UILocalNotification {}

extern_methods!(
    unsafe impl UILocalNotification {
        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Init init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Init initWithCoder:)]
        pub unsafe fn initWithCoder(
            this: Allocated<Self>,
            coder: &NSCoder,
        ) -> Option<Retained<Self>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Other fireDate)]
        pub unsafe fn fireDate(&self) -> Option<Retained<NSDate>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setFireDate:)]
        pub unsafe fn setFireDate(&self, fire_date: Option<&NSDate>);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Other timeZone)]
        pub unsafe fn timeZone(&self) -> Option<Retained<NSTimeZone>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setTimeZone:)]
        pub unsafe fn setTimeZone(&self, time_zone: Option<&NSTimeZone>);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(repeatInterval)]
        pub unsafe fn repeatInterval(&self) -> NSCalendarUnit;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setRepeatInterval:)]
        pub unsafe fn setRepeatInterval(&self, repeat_interval: NSCalendarUnit);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Other repeatCalendar)]
        pub unsafe fn repeatCalendar(&self) -> Option<Retained<NSCalendar>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setRepeatCalendar:)]
        pub unsafe fn setRepeatCalendar(&self, repeat_calendar: Option<&NSCalendar>);

        #[cfg(feature = "objc2-core-location")]
        #[method_id(@__retain_semantics Other region)]
        pub unsafe fn region(&self) -> Option<Retained<CLRegion>>;

        #[cfg(feature = "objc2-core-location")]
        #[method(setRegion:)]
        pub unsafe fn setRegion(&self, region: Option<&CLRegion>);

        #[method(regionTriggersOnce)]
        pub unsafe fn regionTriggersOnce(&self) -> bool;

        #[method(setRegionTriggersOnce:)]
        pub unsafe fn setRegionTriggersOnce(&self, region_triggers_once: bool);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Other alertBody)]
        pub unsafe fn alertBody(&self) -> Option<Retained<NSString>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setAlertBody:)]
        pub unsafe fn setAlertBody(&self, alert_body: Option<&NSString>);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(hasAction)]
        pub unsafe fn hasAction(&self) -> bool;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setHasAction:)]
        pub unsafe fn setHasAction(&self, has_action: bool);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Other alertAction)]
        pub unsafe fn alertAction(&self) -> Option<Retained<NSString>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setAlertAction:)]
        pub unsafe fn setAlertAction(&self, alert_action: Option<&NSString>);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Other alertLaunchImage)]
        pub unsafe fn alertLaunchImage(&self) -> Option<Retained<NSString>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setAlertLaunchImage:)]
        pub unsafe fn setAlertLaunchImage(&self, alert_launch_image: Option<&NSString>);

        #[method_id(@__retain_semantics Other alertTitle)]
        pub unsafe fn alertTitle(&self) -> Option<Retained<NSString>>;

        #[method(setAlertTitle:)]
        pub unsafe fn setAlertTitle(&self, alert_title: Option<&NSString>);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Other soundName)]
        pub unsafe fn soundName(&self) -> Option<Retained<NSString>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setSoundName:)]
        pub unsafe fn setSoundName(&self, sound_name: Option<&NSString>);

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(applicationIconBadgeNumber)]
        pub unsafe fn applicationIconBadgeNumber(&self) -> NSInteger;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setApplicationIconBadgeNumber:)]
        pub unsafe fn setApplicationIconBadgeNumber(
            &self,
            application_icon_badge_number: NSInteger,
        );

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method_id(@__retain_semantics Other userInfo)]
        pub unsafe fn userInfo(&self) -> Option<Retained<NSDictionary>>;

        #[deprecated = "Use UserNotifications Framework's UNNotificationRequest"]
        #[method(setUserInfo:)]
        pub unsafe fn setUserInfo(&self, user_info: Option<&NSDictionary>);

        #[method_id(@__retain_semantics Other category)]
        pub unsafe fn category(&self) -> Option<Retained<NSString>>;

        #[method(setCategory:)]
        pub unsafe fn setCategory(&self, category: Option<&NSString>);
    }
);

extern_methods!(
    /// Methods declared on superclass `NSObject`
    unsafe impl UILocalNotification {
        #[method_id(@__retain_semantics New new)]
        pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
    }
);

extern "C" {
    pub static UILocalNotificationDefaultSoundName: &'static NSString;
}