objc2_io_bluetooth_ui/generated/objc2/IOBluetoothServiceBrowserController.rs
1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_app_kit::*;
7use objc2_foundation::*;
8#[cfg(feature = "objc2-io-bluetooth")]
9use objc2_io_bluetooth::*;
10
11use crate::*;
12
13extern_class!(
14 /// A NSWindowController subclass to display a window to search for and perform SDP queries on bluetooth
15 /// devices within range.
16 ///
17 /// This NSWindowController subclass will bring up a generic Bluetooth search and SDP browsing window
18 /// allowing the user to find devices within range, perform SDP queries on a particular device, and
19 /// select a SDP service to connect to. The client application can provide NSArrays of valid service
20 /// UUIDs to allow, and an NSArray of valid device types to allow. The device type filter is not
21 /// yet implemented.
22 ///
23 /// See also [Apple's documentation](https://developer.apple.com/documentation/iobluetoothui/iobluetoothservicebrowsercontroller?language=objc)
24 #[unsafe(super(NSWindowController, NSResponder, NSObject))]
25 #[derive(Debug, PartialEq, Eq, Hash)]
26 pub struct IOBluetoothServiceBrowserController;
27);
28
29extern_conformance!(
30 unsafe impl NSCoding for IOBluetoothServiceBrowserController {}
31);
32
33extern_conformance!(
34 unsafe impl NSObjectProtocol for IOBluetoothServiceBrowserController {}
35);
36
37extern_conformance!(
38 unsafe impl NSSeguePerforming for IOBluetoothServiceBrowserController {}
39);
40
41impl IOBluetoothServiceBrowserController {
42 extern_methods!(
43 #[cfg(feature = "IOBluetoothUIUserLib")]
44 /// Allocator work Bluetooth Service Browser window controller.
45 ///
46 /// Parameter `inOptions`: Bit field for options to set in the newly allocated controller. Currently no options are available.
47 ///
48 /// Returns: a new instance of the IOBluetoothServiceBrowserController Controller, nil if unsuccessful.
49 #[unsafe(method(serviceBrowserController:))]
50 #[unsafe(method_family = none)]
51 pub unsafe fn serviceBrowserController(
52 in_options: IOBluetoothServiceBrowserControllerOptions,
53 mtm: MainThreadMarker,
54 ) -> Option<Retained<IOBluetoothServiceBrowserController>>;
55
56 #[cfg(all(feature = "IOBluetoothUIUserLib", feature = "objc2-io-bluetooth"))]
57 /// ***WARNING*** This method has been deprecated in favor of -setOptions:, -runModal and -getResults.
58 ///
59 /// Parameter `outRecord`: Pointer to a (IOBluetoothSDPServiceRecord *) object. This will get allocated and returned to the client if the user selects a service.
60 ///
61 /// Parameter `inOptions`: For future expansion. Currently no options defined.
62 ///
63 /// Returns: IOReturn -
64 ///
65 /// kIOReturnSuccess - on successful completion.
66 ///
67 /// kCanceledErr - User canceled.
68 ///
69 ///
70 /// This method allocates and runs the browser window as a modal window waiting for the user to either select a
71 /// service, or cancel the browser window.
72 ///
73 /// # Safety
74 ///
75 /// `out_record` might not allow `None`.
76 #[deprecated]
77 #[unsafe(method(browseDevices:options:))]
78 #[unsafe(method_family = none)]
79 pub unsafe fn browseDevices_options(
80 out_record: Option<&mut Option<Retained<IOBluetoothSDPServiceRecord>>>,
81 in_options: IOBluetoothServiceBrowserControllerOptions,
82 mtm: MainThreadMarker,
83 ) -> IOReturn;
84
85 #[cfg(all(feature = "IOBluetoothUIUserLib", feature = "objc2-io-bluetooth"))]
86 /// ***WARNING*** This method has been deprecated in favor of - beginSheetModalForWindow:modalDelegate:didEndSelector:contextInfo:.
87 ///
88 /// Parameter `outRecord`: Pointer to a (IOBluetoothSDPServiceRecord *) object. This will get allocated and returned to the client if the user selects a service.
89 ///
90 /// Parameter `inOptions`: For future expansion. Currently no options defined.
91 ///
92 /// Parameter `inWindow`: The window to be used as the anchor of the sheet.
93 ///
94 /// Returns: IOReturn -
95 /// kIOReturnSuccess - on successful completion.
96 /// kCanceledErr - User canceled.
97 ///
98 /// This method will allocate and run the IOBluetoothServiceBrowserController browser window as a sheet for a window.
99 ///
100 /// # Safety
101 ///
102 /// - `out_record` might not allow `None`.
103 /// - `in_window` might not allow `None`.
104 #[deprecated]
105 #[unsafe(method(browseDevicesAsSheetForWindow:options:window:))]
106 #[unsafe(method_family = none)]
107 pub unsafe fn browseDevicesAsSheetForWindow_options_window(
108 out_record: Option<&mut Option<Retained<IOBluetoothSDPServiceRecord>>>,
109 in_options: IOBluetoothServiceBrowserControllerOptions,
110 in_window: Option<&NSWindow>,
111 mtm: MainThreadMarker,
112 ) -> IOReturn;
113
114 #[cfg(feature = "IOBluetoothUIUserLib")]
115 /// Method call to convert an IOBluetoothServiceBrowserControllerRef into an IOBluetoothServiceBrowserController *.
116 ///
117 /// Parameter `serviceBrowserControllerRef`: IOBluetoothServiceBrowserControllerRef for which an IOBluetoothServiceBrowserController * is desired.
118 ///
119 /// Returns: Returns the IOBluetoothServiceBrowserController * for the given IOBluetoothServiceBrowserControllerRef.
120 ///
121 /// # Safety
122 ///
123 /// `service_browser_controller_ref` might not allow `None`.
124 #[unsafe(method(withServiceBrowserControllerRef:))]
125 #[unsafe(method_family = none)]
126 pub unsafe fn withServiceBrowserControllerRef(
127 service_browser_controller_ref: Option<&IOBluetoothServiceBrowserControllerRef>,
128 mtm: MainThreadMarker,
129 ) -> Option<Retained<IOBluetoothServiceBrowserController>>;
130
131 #[cfg(feature = "IOBluetoothUIUserLib")]
132 /// Returns an IOBluetoothServiceBrowserControllerRef representation of the target IOBluetoothServiceBrowserController object.
133 ///
134 /// Returns: Returns an IOBluetoothServiceBrowserControllerRef representation of the target IOBluetoothServiceBrowserController object.
135 #[unsafe(method(getServiceBrowserControllerRef))]
136 #[unsafe(method_family = none)]
137 pub unsafe fn getServiceBrowserControllerRef(
138 &self,
139 ) -> Option<Retained<IOBluetoothServiceBrowserControllerRef>>;
140
141 #[cfg(feature = "objc2-io-bluetooth")]
142 /// Invoke an already created window controller to display, and run the modal dialog.
143 ///
144 /// ***WARNING*** This method has been deprecated in favor of -runModal and -getResults.
145 ///
146 /// Parameter `outRecord`: Pointer to a (IOBluetoothSDPServiceRecord *) object. This will get allocated and returned to the client if the user selects a service.
147 ///
148 /// Returns: IOReturn -
149 /// kIOReturnSuccess - on successful completion.
150 /// kCanceledErr - User canceled.
151 ///
152 /// This method will run the IOBluetoothServiceBrowserController browser window modally.
153 ///
154 /// # Safety
155 ///
156 /// `out_record` might not allow `None`.
157 #[deprecated]
158 #[unsafe(method(discover:))]
159 #[unsafe(method_family = none)]
160 pub unsafe fn discover(
161 &self,
162 out_record: Option<&mut Option<Retained<IOBluetoothSDPServiceRecord>>>,
163 ) -> IOReturn;
164
165 #[cfg(feature = "objc2-io-bluetooth")]
166 /// Invoke an already created window controller to display, and run the modal dialog.
167 ///
168 /// ***WARNING*** This method has been deprecated in favor of -beginSheetModalForWindow:... and -getResults.
169 ///
170 /// Parameter `sheetWindow`: The window to use for the anchor of the sheet..
171 ///
172 /// Parameter `outRecord`: Pointer to a (IOBluetoothSDPServiceRecord *) object. This will get allocated and returned to the client if the user selects a service.
173 ///
174 /// Returns: IOReturn -
175 /// kIOReturnSuccess - on successful completion.
176 /// kCanceledErr - User canceled.
177 ///
178 /// This method will run the IOBluetoothServiceBrowserController browser window as a sheet for the window passed to it in sheetWindow.
179 ///
180 /// # Safety
181 ///
182 /// - `sheet_window` might not allow `None`.
183 /// - `out_record` might not allow `None`.
184 #[deprecated]
185 #[unsafe(method(discoverAsSheetForWindow:withRecord:))]
186 #[unsafe(method_family = none)]
187 pub unsafe fn discoverAsSheetForWindow_withRecord(
188 &self,
189 sheet_window: Option<&NSWindow>,
190 out_record: Option<&mut Option<Retained<IOBluetoothSDPServiceRecord>>>,
191 ) -> IOReturn;
192
193 #[cfg(feature = "objc2-io-bluetooth")]
194 /// Invoke an already created window controller to display, and run the modal dialog.
195 ///
196 /// ***WARNING*** This method has been deprecated in favor of -setSearchAttributes:, -addAllowedUUID:, -runModal and -getResults.
197 ///
198 /// Parameter `deviceArray`: A NSArray of valid device type objects to allow. Not implemented yet.
199 ///
200 /// Parameter `serviceArray`: A NSArray of valid UUIDs to allow. The array should contain NSData objects
201 /// specifying the UUID to allow. We currently only support 16-bit short UUID forms, but
202 /// will allow for any of the 16, 32 or full 128-bit UUID forms.
203 ///
204 /// Parameter `outRecord`: Pointer to a (IOBluetoothSDPServiceRecord *) object. This will get allocated
205 /// and returned to the client if the user selects a service.
206 ///
207 /// Returns: IOReturn -
208 /// kIOReturnSuccess - on successful completion.
209 /// kCanceledErr - User canceled.
210 ///
211 /// This method will run the IOBluetoothServiceBrowserController browser window as a sheet for the window passed to it in sheetWindow.
212 ///
213 /// # Safety
214 ///
215 /// - `device_attributes` must be a valid pointer.
216 /// - `service_array` generic should be of the correct type.
217 /// - `service_array` might not allow `None`.
218 /// - `out_record` might not allow `None`.
219 #[deprecated]
220 #[unsafe(method(discoverWithDeviceAttributes:serviceList:serviceRecord:))]
221 #[unsafe(method_family = none)]
222 pub unsafe fn discoverWithDeviceAttributes_serviceList_serviceRecord(
223 &self,
224 device_attributes: *mut IOBluetoothDeviceSearchAttributes,
225 service_array: Option<&NSArray>,
226 out_record: Option<&mut Option<Retained<IOBluetoothSDPServiceRecord>>>,
227 ) -> IOReturn;
228
229 #[cfg(feature = "IOBluetoothUIUserLib")]
230 /// Modify the options for the window controller.
231 ///
232 /// Parameter `inOptions`: Bit field to set the options to.
233 ///
234 /// Returns: None.
235 ///
236 /// This method will set the options for the browser to new values.
237 #[unsafe(method(setOptions:))]
238 #[unsafe(method_family = none)]
239 pub unsafe fn setOptions(&self, in_options: IOBluetoothServiceBrowserControllerOptions);
240
241 /// Runs the service browser panel in a modal session to allow the user to select a service on a Bluetooth device.
242 ///
243 /// The controller will use the panel attributes to filter what devices the user sees. The allowed UUIDs
244 /// will be used to validate the selection the user makes. The user will only be able to select services
245 /// that match the allowed UUIDs. Only when a selection has been validated (or
246 /// the panel cancelled), will this method return.
247 ///
248 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
249 ///
250 /// Returns: Returns kIOBluetoothUISuccess if a successful, validated service selection was made by the user.
251 /// Returns kIOBluetoothUIUserCanceledErr if the user cancelled the panel. These return values are the
252 /// same as NSRunStoppedResponse and NSRunAbortedResponse respectively. They are the standard values
253 /// used in a modal session.
254 #[unsafe(method(runModal))]
255 #[unsafe(method_family = none)]
256 pub unsafe fn runModal(&self) -> c_int;
257
258 /// Runs the service browser panel as a sheet on the target window.
259 ///
260 /// This function works the same way as -[NSApplication beginSheet:modalForWindow:modalDelegate:didEndSelector:contextInfo:].
261 /// The didEndSelector has a similar prototype as in NSApplication except that the first argument is the
262 /// IOBluetoothServiceBrowserController object instead of the window:
263 /// -(void)sheetDidEnd:(IOBluetoothServiceBrowserController *)controller returnCode:(int)returnCode contextInfo:(void *)contextInfo.
264 /// The returnCode parameter will either be kIOBluetoothUISuccess or kIOBluetoothUIUserCancelledErr as described in
265 /// -runModal.
266 ///
267 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
268 ///
269 /// Parameter `sheetWindow`: NSWindow to attach the service browser panel to as a sheet.
270 ///
271 /// Parameter `modalDelegate`: Delegate object that gets sent the didEndSelector when the sheet modal session is finished.
272 ///
273 /// Parameter `didEndSelector`: Selector sent to the modalDelegate when the sheet modal session is finished.
274 ///
275 /// Parameter `contextInfo`: User-definied value passed to the modalDelegate in the didEndSelector.
276 ///
277 /// Returns: Returns kIOReturnSuccess if the sheet modal session was started.
278 ///
279 /// # Safety
280 ///
281 /// - `sheet_window` might not allow `None`.
282 /// - `modal_delegate` should be of the correct type.
283 /// - `modal_delegate` might not allow `None`.
284 /// - `did_end_selector` must be a valid selector.
285 /// - `context_info` must be a valid pointer.
286 #[unsafe(method(beginSheetModalForWindow:modalDelegate:didEndSelector:contextInfo:))]
287 #[unsafe(method_family = none)]
288 pub unsafe fn beginSheetModalForWindow_modalDelegate_didEndSelector_contextInfo(
289 &self,
290 sheet_window: Option<&NSWindow>,
291 modal_delegate: Option<&AnyObject>,
292 did_end_selector: Option<Sel>,
293 context_info: *mut c_void,
294 ) -> IOReturn;
295
296 /// Returns the result of the user's selection.
297 ///
298 /// There will only be results if the panel has been run, the user has successfully made a selection and that
299 /// selection has been validated. If kIOBluetoothUISuccess was returned for the session, there should be valid
300 /// results. Currently only a single device is allowed to be selected, so the results array will only contain
301 /// one object. However in the future multiple selection will be supported.
302 ///
303 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
304 ///
305 /// Returns: Returns an NSArray of IOBluetoothSDPServiceRecord objects corresponding to the user's selection. If the user cancelled
306 /// the panel, nil will be returned.
307 #[unsafe(method(getResults))]
308 #[unsafe(method_family = none)]
309 pub unsafe fn getResults(&self) -> Option<Retained<NSArray>>;
310
311 #[cfg(feature = "IOBluetoothUIUserLib")]
312 /// Returns the option bits that control the panel's behavior.
313 ///
314 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
315 ///
316 /// Returns: Returns the option bits set by setOptions:
317 #[unsafe(method(getOptions))]
318 #[unsafe(method_family = none)]
319 pub unsafe fn getOptions(&self) -> IOBluetoothServiceBrowserControllerOptions;
320
321 #[cfg(feature = "objc2-io-bluetooth")]
322 /// Sets the search attributes that control the panel's search/inquiry behavior.
323 ///
324 /// The device search attributes control the inquiry behavior of the panel. They allow only devices
325 /// that match the specified attributes (i.e. class of device) to be displayed to the user. Note that
326 /// this only covers attributes returned in an inquiry result and not actual SDP services on the device.
327 ///
328 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
329 ///
330 /// Parameter `searchAttributes`: Attributes to control the panel's inquiry behavior.
331 ///
332 /// # Safety
333 ///
334 /// `search_attributes` must be a valid pointer.
335 #[unsafe(method(setSearchAttributes:))]
336 #[unsafe(method_family = none)]
337 pub unsafe fn setSearchAttributes(
338 &self,
339 search_attributes: *const IOBluetoothDeviceSearchAttributes,
340 );
341
342 #[cfg(feature = "objc2-io-bluetooth")]
343 /// Returns the search attributes that control the panel's search/inquiry behavior.
344 ///
345 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
346 ///
347 /// Returns: Returns the search attributes set by setSearchAttributes:
348 ///
349 /// # Safety
350 ///
351 /// The returned struct field 4 struct field 2 Array TODO.
352 #[unsafe(method(getSearchAttributes))]
353 #[unsafe(method_family = none)]
354 pub unsafe fn getSearchAttributes(&self) -> *const IOBluetoothDeviceSearchAttributes;
355
356 #[cfg(feature = "objc2-io-bluetooth")]
357 /// Adds a UUID to the list of UUIDs that are used to validate the user's selection.
358 ///
359 /// The user's device selection gets validated against the UUIDs passed to -addAllowedUUID:
360 /// addAllowedUUIDArray:. Each call to those methods essentially adds a filter that the
361 /// selected device gets validated with. If any of the filters match, the device is considered
362 /// valid. If they all fail, the device is not valid and the user is presented with an
363 /// error code that the device does not support the required services. The UUID passed to
364 /// -addAllowedUUID: is the only UUID that must be present in the device's SDP service records.
365 /// Alternatively, all of the UUIDs in the UUID array passed to -addAllowedUUIDArray must be
366 /// present.
367 ///
368 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
369 ///
370 /// Parameter `allowedUUID`: UUID that a device may contain to be selected
371 ///
372 /// # Safety
373 ///
374 /// `allowed_uuid` might not allow `None`.
375 #[unsafe(method(addAllowedUUID:))]
376 #[unsafe(method_family = none)]
377 pub unsafe fn addAllowedUUID(&self, allowed_uuid: Option<&IOBluetoothSDPUUID>);
378
379 /// Adds an array of UUIDs to the list of UUIDs that are used to validate the user's selection.
380 ///
381 /// The user's device selection gets validated against the UUIDs passed to -addAllowedUUID:
382 /// addAllowedUUIDArray:. Each call to those methods essentially adds a filter that the
383 /// selected device gets validated with. If any of the filters match, the device is considered
384 /// valid. If they all fail, the device is not valid and the user is presented with an
385 /// error code that the device does not support the required services. The UUID passed to
386 /// -addAllowedUUID: is the only UUID that must be present in the device's SDP service records.
387 /// Alternatively, all of the UUIDs in the UUID array passed to -addAllowedUUIDArray must be
388 /// present.
389 ///
390 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
391 ///
392 /// Parameter `allowedUUIDArray`: An NSArray of UUIDs that all must be present in a device for it to be selectable.
393 ///
394 /// # Safety
395 ///
396 /// - `allowed_uuid_array` generic should be of the correct type.
397 /// - `allowed_uuid_array` might not allow `None`.
398 #[unsafe(method(addAllowedUUIDArray:))]
399 #[unsafe(method_family = none)]
400 pub unsafe fn addAllowedUUIDArray(&self, allowed_uuid_array: Option<&NSArray>);
401
402 /// Resets the controller back to the default state where it will accept any device the user selects.
403 ///
404 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
405 #[unsafe(method(clearAllowedUUIDs))]
406 #[unsafe(method_family = none)]
407 pub unsafe fn clearAllowedUUIDs(&self);
408
409 /// Sets the title of the panel when not run as a sheet.
410 ///
411 /// The panel title should be localized for best user experience.
412 ///
413 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
414 ///
415 /// Parameter `windowTitle`: Title of the device selector panel.
416 ///
417 /// # Safety
418 ///
419 /// `window_title` might not allow `None`.
420 #[unsafe(method(setTitle:))]
421 #[unsafe(method_family = none)]
422 pub unsafe fn setTitle(&self, window_title: Option<&NSString>);
423
424 /// Returns the title of the device selector panel (i.e. what was set in -setTitle:).
425 ///
426 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
427 ///
428 /// Returns: Returns the title of the device selector panel.
429 #[unsafe(method(getTitle))]
430 #[unsafe(method_family = none)]
431 pub unsafe fn getTitle(&self) -> Option<Retained<NSString>>;
432
433 /// Sets the description text that appears in the device selector panel.
434 ///
435 /// The description text should be localized for best user experience.
436 ///
437 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
438 ///
439 /// Parameter `descriptionText`: String that appears in the description section of the device selector panel.
440 ///
441 /// # Safety
442 ///
443 /// `description_text` might not allow `None`.
444 #[unsafe(method(setDescriptionText:))]
445 #[unsafe(method_family = none)]
446 pub unsafe fn setDescriptionText(&self, description_text: Option<&NSString>);
447
448 /// Returns the description text that appears in the device selector panel (i.e. what was set in -setDescriptionText:).
449 ///
450 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
451 ///
452 /// Returns: Returns the description text of the device selector panel.
453 #[unsafe(method(getDescriptionText))]
454 #[unsafe(method_family = none)]
455 pub unsafe fn getDescriptionText(&self) -> Option<Retained<NSString>>;
456
457 /// Sets the title of the default/select button in the device selector panel.
458 ///
459 /// The prompt text should be localized for best user experience.
460 ///
461 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
462 ///
463 /// Parameter `prompt`: String that appears in the default/select button in the device selector panel.
464 ///
465 /// # Safety
466 ///
467 /// `prompt` might not allow `None`.
468 #[unsafe(method(setPrompt:))]
469 #[unsafe(method_family = none)]
470 pub unsafe fn setPrompt(&self, prompt: Option<&NSString>);
471
472 /// Returns the title of the default/select button in the device selector panel (i.e. what was set in -setPrompt:).
473 ///
474 /// NOTE: This method is only available in Mac OS X 10.2.4 (Bluetooth v1.1) or later.
475 ///
476 /// Returns: Returns the default button title of the device selector panel.
477 #[unsafe(method(getPrompt))]
478 #[unsafe(method_family = none)]
479 pub unsafe fn getPrompt(&self) -> Option<Retained<NSString>>;
480 );
481}
482
483/// Methods declared on superclass `NSWindowController`.
484impl IOBluetoothServiceBrowserController {
485 extern_methods!(
486 #[unsafe(method(initWithWindow:))]
487 #[unsafe(method_family = init)]
488 pub unsafe fn initWithWindow(
489 this: Allocated<Self>,
490 window: Option<&NSWindow>,
491 ) -> Retained<Self>;
492
493 /// # Safety
494 ///
495 /// `coder` possibly has further requirements.
496 #[unsafe(method(initWithCoder:))]
497 #[unsafe(method_family = init)]
498 pub unsafe fn initWithCoder(
499 this: Allocated<Self>,
500 coder: &NSCoder,
501 ) -> Option<Retained<Self>>;
502
503 #[unsafe(method(initWithWindowNibName:))]
504 #[unsafe(method_family = init)]
505 pub unsafe fn initWithWindowNibName(
506 this: Allocated<Self>,
507 window_nib_name: &NSNibName,
508 ) -> Retained<Self>;
509
510 /// # Safety
511 ///
512 /// `owner` should be of the correct type.
513 #[unsafe(method(initWithWindowNibName:owner:))]
514 #[unsafe(method_family = init)]
515 pub unsafe fn initWithWindowNibName_owner(
516 this: Allocated<Self>,
517 window_nib_name: &NSNibName,
518 owner: &AnyObject,
519 ) -> Retained<Self>;
520
521 /// # Safety
522 ///
523 /// `owner` should be of the correct type.
524 #[unsafe(method(initWithWindowNibPath:owner:))]
525 #[unsafe(method_family = init)]
526 pub unsafe fn initWithWindowNibPath_owner(
527 this: Allocated<Self>,
528 window_nib_path: &NSString,
529 owner: &AnyObject,
530 ) -> Retained<Self>;
531 );
532}
533
534/// Methods declared on superclass `NSResponder`.
535impl IOBluetoothServiceBrowserController {
536 extern_methods!(
537 #[unsafe(method(init))]
538 #[unsafe(method_family = init)]
539 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
540 );
541}
542
543/// Methods declared on superclass `NSObject`.
544impl IOBluetoothServiceBrowserController {
545 extern_methods!(
546 #[unsafe(method(new))]
547 #[unsafe(method_family = new)]
548 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
549 );
550}