use objc::{msg_send, sel, sel_impl};
use crate::{
foundation::NSDate,
object,
objective_c_runtime::{
macros::interface_impl,
traits::{FromId, PNSObject},
},
};
use super::UNNotificationRequest;
object! {
unsafe pub struct UNNotification;
}
#[interface_impl(NSObject)]
impl UNNotification {
#[property]
pub fn request(&self) -> UNNotificationRequest {
unsafe { UNNotificationRequest::from_id(msg_send![self.m_self(), request]) }
}
#[property]
pub fn date(&self) -> NSDate {
unsafe { NSDate::from_id(msg_send![self.m_self(), date]) }
}
}