objc2_user_notifications/generated/
UNError.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use objc2::__framework_prelude::*;
4use objc2_foundation::*;
5
6use crate::*;
7
8extern "C" {
9    /// [Apple's documentation](https://developer.apple.com/documentation/usernotifications/unerrordomain?language=objc)
10    pub static UNErrorDomain: Option<&'static NSString>;
11}
12
13/// [Apple's documentation](https://developer.apple.com/documentation/usernotifications/unerrorcode?language=objc)
14// NS_ENUM
15#[repr(transparent)]
16#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
17pub struct UNErrorCode(pub NSInteger);
18impl UNErrorCode {
19    #[doc(alias = "UNErrorCodeNotificationsNotAllowed")]
20    pub const NotificationsNotAllowed: Self = Self(1);
21    #[doc(alias = "UNErrorCodeAttachmentInvalidURL")]
22    pub const AttachmentInvalidURL: Self = Self(100);
23    #[doc(alias = "UNErrorCodeAttachmentUnrecognizedType")]
24    pub const AttachmentUnrecognizedType: Self = Self(101);
25    #[doc(alias = "UNErrorCodeAttachmentInvalidFileSize")]
26    pub const AttachmentInvalidFileSize: Self = Self(102);
27    #[doc(alias = "UNErrorCodeAttachmentNotInDataStore")]
28    pub const AttachmentNotInDataStore: Self = Self(103);
29    #[doc(alias = "UNErrorCodeAttachmentMoveIntoDataStoreFailed")]
30    pub const AttachmentMoveIntoDataStoreFailed: Self = Self(104);
31    #[doc(alias = "UNErrorCodeAttachmentCorrupt")]
32    pub const AttachmentCorrupt: Self = Self(105);
33    #[doc(alias = "UNErrorCodeNotificationInvalidNoDate")]
34    pub const NotificationInvalidNoDate: Self = Self(1400);
35    #[doc(alias = "UNErrorCodeNotificationInvalidNoContent")]
36    pub const NotificationInvalidNoContent: Self = Self(1401);
37    #[doc(alias = "UNErrorCodeContentProvidingObjectNotAllowed")]
38    pub const ContentProvidingObjectNotAllowed: Self = Self(1500);
39    #[doc(alias = "UNErrorCodeContentProvidingInvalid")]
40    pub const ContentProvidingInvalid: Self = Self(1501);
41    #[doc(alias = "UNErrorCodeBadgeInputInvalid")]
42    pub const BadgeInputInvalid: Self = Self(1600);
43}
44
45unsafe impl Encode for UNErrorCode {
46    const ENCODING: Encoding = NSInteger::ENCODING;
47}
48
49unsafe impl RefEncode for UNErrorCode {
50    const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
51}