objc2_core_telephony/generated/
CTCarrier.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10    /// [Apple's documentation](https://developer.apple.com/documentation/coretelephony/ctcarrier?language=objc)
11    #[unsafe(super(NSObject))]
12    #[derive(Debug, PartialEq, Eq, Hash)]
13    pub struct CTCarrier;
14);
15
16extern_conformance!(
17    unsafe impl NSObjectProtocol for CTCarrier {}
18);
19
20impl CTCarrier {
21    extern_methods!(
22        #[deprecated = "Deprecated; returns '--' at some point in the future"]
23        #[unsafe(method(carrierName))]
24        #[unsafe(method_family = none)]
25        pub unsafe fn carrierName(&self) -> Option<Retained<NSString>>;
26
27        #[deprecated = "Deprecated; returns '65535' at some point in the future"]
28        #[unsafe(method(mobileCountryCode))]
29        #[unsafe(method_family = none)]
30        pub unsafe fn mobileCountryCode(&self) -> Option<Retained<NSString>>;
31
32        #[deprecated = "Deprecated; returns '65535' at some point in the future"]
33        #[unsafe(method(mobileNetworkCode))]
34        #[unsafe(method_family = none)]
35        pub unsafe fn mobileNetworkCode(&self) -> Option<Retained<NSString>>;
36
37        #[deprecated = "Deprecated; returns '--' at some point in the future"]
38        #[unsafe(method(isoCountryCode))]
39        #[unsafe(method_family = none)]
40        pub unsafe fn isoCountryCode(&self) -> Option<Retained<NSString>>;
41
42        #[deprecated = "Deprecated; returns YES at some point in the future"]
43        #[unsafe(method(allowsVOIP))]
44        #[unsafe(method_family = none)]
45        pub unsafe fn allowsVOIP(&self) -> bool;
46    );
47}
48
49/// Methods declared on superclass `NSObject`.
50impl CTCarrier {
51    extern_methods!(
52        #[unsafe(method(init))]
53        #[unsafe(method_family = init)]
54        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
55
56        #[unsafe(method(new))]
57        #[unsafe(method_family = new)]
58        pub unsafe fn new() -> Retained<Self>;
59    );
60}