use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use objc2_foundation::*;
use crate::*;
extern "C" {
pub static PKPassKitErrorDomain: &'static NSString;
}
#[repr(transparent)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub struct PKPassKitErrorCode(pub NSInteger);
impl PKPassKitErrorCode {
#[doc(alias = "PKUnknownError")]
pub const UnknownError: Self = Self(-1);
#[doc(alias = "PKInvalidDataError")]
pub const InvalidDataError: Self = Self(1);
#[doc(alias = "PKUnsupportedVersionError")]
pub const UnsupportedVersionError: Self = Self(2);
#[doc(alias = "PKInvalidSignature")]
pub const InvalidSignature: Self = Self(3);
#[doc(alias = "PKNotEntitledError")]
pub const NotEntitledError: Self = Self(4);
}
unsafe impl Encode for PKPassKitErrorCode {
const ENCODING: Encoding = NSInteger::ENCODING;
}
unsafe impl RefEncode for PKPassKitErrorCode {
const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}
extern "C" {
pub static PKPaymentErrorDomain: &'static NSString;
}
#[repr(transparent)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub struct PKPaymentErrorCode(pub NSInteger);
impl PKPaymentErrorCode {
#[doc(alias = "PKPaymentUnknownError")]
pub const UnknownError: Self = Self(-1);
#[doc(alias = "PKPaymentShippingContactInvalidError")]
pub const ShippingContactInvalidError: Self = Self(1);
#[doc(alias = "PKPaymentBillingContactInvalidError")]
pub const BillingContactInvalidError: Self = Self(2);
#[doc(alias = "PKPaymentShippingAddressUnserviceableError")]
pub const ShippingAddressUnserviceableError: Self = Self(3);
#[doc(alias = "PKPaymentCouponCodeInvalidError")]
pub const CouponCodeInvalidError: Self = Self(4);
#[doc(alias = "PKPaymentCouponCodeExpiredError")]
pub const CouponCodeExpiredError: Self = Self(5);
}
unsafe impl Encode for PKPaymentErrorCode {
const ENCODING: Encoding = NSInteger::ENCODING;
}
unsafe impl RefEncode for PKPaymentErrorCode {
const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}
pub type PKPaymentErrorKey = NSString;
extern "C" {
pub static PKPaymentErrorContactFieldUserInfoKey: &'static PKPaymentErrorKey;
}
extern "C" {
pub static PKPaymentErrorPostalAddressUserInfoKey: &'static PKPaymentErrorKey;
}
extern "C" {
pub static PKDisbursementErrorDomain: &'static NSString;
}
#[repr(transparent)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub struct PKDisbursementErrorCode(pub NSInteger);
impl PKDisbursementErrorCode {
#[doc(alias = "PKDisbursementUnknownError")]
pub const UnknownError: Self = Self(-1);
#[doc(alias = "PKDisbursementUnsupportedCardError")]
pub const UnsupportedCardError: Self = Self(1);
#[doc(alias = "PKDisbursementRecipientContactInvalidError")]
pub const RecipientContactInvalidError: Self = Self(2);
}
unsafe impl Encode for PKDisbursementErrorCode {
const ENCODING: Encoding = NSInteger::ENCODING;
}
unsafe impl RefEncode for PKDisbursementErrorCode {
const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}
pub type PKDisbursementErrorKey = NSString;
extern "C" {
pub static PKDisbursementErrorContactFieldUserInfoKey: &'static PKDisbursementErrorKey;
}
#[repr(transparent)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub struct PKAddPaymentPassError(pub NSInteger);
impl PKAddPaymentPassError {
#[doc(alias = "PKAddPaymentPassErrorUnsupported")]
pub const Unsupported: Self = Self(0);
#[doc(alias = "PKAddPaymentPassErrorUserCancelled")]
pub const UserCancelled: Self = Self(1);
#[doc(alias = "PKAddPaymentPassErrorSystemCancelled")]
pub const SystemCancelled: Self = Self(2);
}
unsafe impl Encode for PKAddPaymentPassError {
const ENCODING: Encoding = NSInteger::ENCODING;
}
unsafe impl RefEncode for PKAddPaymentPassError {
const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}
extern "C" {
pub static PKAddSecureElementPassErrorDomain: &'static NSString;
}
#[repr(transparent)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub struct PKAddSecureElementPassErrorCode(pub NSInteger);
impl PKAddSecureElementPassErrorCode {
#[doc(alias = "PKAddSecureElementPassGenericError")]
pub const GenericError: Self = Self(0);
#[doc(alias = "PKAddSecureElementPassUnknownError")]
#[deprecated = "Use PKAddSecureElementPassGenericError instead."]
pub const UnknownError: Self = Self(PKAddSecureElementPassErrorCode::GenericError.0);
#[doc(alias = "PKAddSecureElementPassUserCanceledError")]
pub const UserCanceledError: Self = Self(1);
#[doc(alias = "PKAddSecureElementPassUnavailableError")]
pub const UnavailableError: Self = Self(2);
#[doc(alias = "PKAddSecureElementPassInvalidConfigurationError")]
pub const InvalidConfigurationError: Self = Self(3);
#[doc(alias = "PKAddSecureElementPassDeviceNotSupportedError")]
pub const DeviceNotSupportedError: Self = Self(4);
#[doc(alias = "PKAddSecureElementPassDeviceNotReadyError")]
pub const DeviceNotReadyError: Self = Self(5);
#[doc(alias = "PKAddSecureElementPassOSVersionNotSupportedError")]
pub const OSVersionNotSupportedError: Self = Self(6);
}
unsafe impl Encode for PKAddSecureElementPassErrorCode {
const ENCODING: Encoding = NSInteger::ENCODING;
}
unsafe impl RefEncode for PKAddSecureElementPassErrorCode {
const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}
extern "C" {
pub static PKShareSecureElementPassErrorDomain: &'static NSString;
}
#[repr(transparent)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub struct PKShareSecureElementPassErrorCode(pub NSInteger);
impl PKShareSecureElementPassErrorCode {
#[doc(alias = "PKShareSecureElementPassUnknownError")]
pub const UnknownError: Self = Self(0);
#[doc(alias = "PKShareSecureElementPassSetupError")]
pub const SetupError: Self = Self(1);
}
unsafe impl Encode for PKShareSecureElementPassErrorCode {
const ENCODING: Encoding = NSInteger::ENCODING;
}
unsafe impl RefEncode for PKShareSecureElementPassErrorCode {
const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}