objc2_accessibility/generated/
AXBrailleTranslator.rs1use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10 #[unsafe(super(NSObject))]
14 #[derive(Debug, PartialEq, Eq, Hash)]
15 pub struct AXBrailleTable;
16);
17
18extern_conformance!(
19 unsafe impl NSCoding for AXBrailleTable {}
20);
21
22extern_conformance!(
23 unsafe impl NSCopying for AXBrailleTable {}
24);
25
26unsafe impl CopyingHelper for AXBrailleTable {
27 type Result = Self;
28}
29
30extern_conformance!(
31 unsafe impl NSObjectProtocol for AXBrailleTable {}
32);
33
34impl AXBrailleTable {
35 extern_methods!(
36 #[unsafe(method(identifier))]
38 #[unsafe(method_family = none)]
39 pub unsafe fn identifier(&self) -> Retained<NSString>;
40
41 #[unsafe(method(localizedName))]
43 #[unsafe(method_family = none)]
44 pub unsafe fn localizedName(&self) -> Retained<NSString>;
45
46 #[unsafe(method(providerIdentifier))]
48 #[unsafe(method_family = none)]
49 pub unsafe fn providerIdentifier(&self) -> Retained<NSString>;
50
51 #[unsafe(method(localizedProviderName))]
53 #[unsafe(method_family = none)]
54 pub unsafe fn localizedProviderName(&self) -> Retained<NSString>;
55
56 #[unsafe(method(language))]
58 #[unsafe(method_family = none)]
59 pub unsafe fn language(&self) -> Retained<NSString>;
60
61 #[unsafe(method(locales))]
63 #[unsafe(method_family = none)]
64 pub unsafe fn locales(&self) -> Retained<NSSet<NSLocale>>;
65
66 #[unsafe(method(isEightDot))]
68 #[unsafe(method_family = none)]
69 pub unsafe fn isEightDot(&self) -> bool;
70
71 #[unsafe(method(supportedLocales))]
73 #[unsafe(method_family = none)]
74 pub unsafe fn supportedLocales() -> Retained<NSSet<NSLocale>>;
75
76 #[unsafe(method(defaultTableForLocale:))]
78 #[unsafe(method_family = none)]
79 pub unsafe fn defaultTableForLocale(locale: &NSLocale) -> Option<Retained<AXBrailleTable>>;
80
81 #[unsafe(method(tablesForLocale:))]
83 #[unsafe(method_family = none)]
84 pub unsafe fn tablesForLocale(locale: &NSLocale) -> Retained<NSSet<AXBrailleTable>>;
85
86 #[unsafe(method(languageAgnosticTables))]
88 #[unsafe(method_family = none)]
89 pub unsafe fn languageAgnosticTables() -> Retained<NSSet<AXBrailleTable>>;
90
91 #[unsafe(method(initWithIdentifier:))]
93 #[unsafe(method_family = init)]
94 pub unsafe fn initWithIdentifier(
95 this: Allocated<Self>,
96 identifier: &NSString,
97 ) -> Option<Retained<Self>>;
98
99 #[unsafe(method(init))]
100 #[unsafe(method_family = init)]
101 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
102
103 #[unsafe(method(new))]
104 #[unsafe(method_family = new)]
105 pub unsafe fn new() -> Retained<Self>;
106 );
107}
108
109extern_class!(
110 #[unsafe(super(NSObject))]
114 #[derive(Debug, PartialEq, Eq, Hash)]
115 pub struct AXBrailleTranslationResult;
116);
117
118extern_conformance!(
119 unsafe impl NSCoding for AXBrailleTranslationResult {}
120);
121
122extern_conformance!(
123 unsafe impl NSCopying for AXBrailleTranslationResult {}
124);
125
126unsafe impl CopyingHelper for AXBrailleTranslationResult {
127 type Result = Self;
128}
129
130extern_conformance!(
131 unsafe impl NSObjectProtocol for AXBrailleTranslationResult {}
132);
133
134impl AXBrailleTranslationResult {
135 extern_methods!(
136 #[unsafe(method(resultString))]
138 #[unsafe(method_family = none)]
139 pub unsafe fn resultString(&self) -> Retained<NSString>;
140
141 #[unsafe(method(locationMap))]
144 #[unsafe(method_family = none)]
145 pub unsafe fn locationMap(&self) -> Retained<NSArray<NSNumber>>;
146
147 #[unsafe(method(init))]
148 #[unsafe(method_family = init)]
149 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
150
151 #[unsafe(method(new))]
152 #[unsafe(method_family = new)]
153 pub unsafe fn new() -> Retained<Self>;
154 );
155}
156
157extern_class!(
158 #[unsafe(super(NSObject))]
162 #[derive(Debug, PartialEq, Eq, Hash)]
163 pub struct AXBrailleTranslator;
164);
165
166extern_conformance!(
167 unsafe impl NSObjectProtocol for AXBrailleTranslator {}
168);
169
170impl AXBrailleTranslator {
171 extern_methods!(
172 #[unsafe(method(initWithBrailleTable:))]
173 #[unsafe(method_family = init)]
174 pub unsafe fn initWithBrailleTable(
175 this: Allocated<Self>,
176 braille_table: &AXBrailleTable,
177 ) -> Retained<Self>;
178
179 #[unsafe(method(translatePrintText:))]
181 #[unsafe(method_family = none)]
182 pub unsafe fn translatePrintText(
183 &self,
184 print_text: &NSString,
185 ) -> Retained<AXBrailleTranslationResult>;
186
187 #[unsafe(method(backTranslateBraille:))]
189 #[unsafe(method_family = none)]
190 pub unsafe fn backTranslateBraille(
191 &self,
192 braille: &NSString,
193 ) -> Retained<AXBrailleTranslationResult>;
194
195 #[unsafe(method(init))]
196 #[unsafe(method_family = init)]
197 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
198
199 #[unsafe(method(new))]
200 #[unsafe(method_family = new)]
201 pub unsafe fn new() -> Retained<Self>;
202 );
203}