1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ptr::NonNull;
#[cfg(feature = "objc2-core-foundation")]
use objc2_core_foundation::*;
use crate::*;
extern "C-unwind" {
/// Promotes all active CoreBluetooth connections to peripherals' Bluetooth LE MIDI
/// service into online MIDI devices capable of I/O.
///
///
/// Returns: An OSStatus result code.
///
///
/// To programmatically establish a Bluetooth MIDI driver connection to a LE MIDI peripheral,
/// the following steps must be completed in order.
///
/// 1. Using CoreBluetooth API, scan for the peripheral's advertised LE MIDI service.
/// 2. Using CoreBluetooth API, connect to the desired advertised peripheral.
/// 3. Upon successful connection, call MIDIBluetoothDriverActivateAllConnections.
/// 4. Using CoreMIDI API, confirm the peripheral's registration by locating its MIDIDeviceRef.
/// 5. If present, CoreMIDI now owns a connection the peripheral.
/// 6. Using CoreBluetooth API, disconnect from the peripheral now managed by CoreMIDI.
pub fn MIDIBluetoothDriverActivateAllConnections() -> OSStatus;
}
extern "C-unwind" {
/// Disconnects the Bluetooth MIDI driver from a BLE MIDI peripheral.
///
///
/// Parameter `uuid`: A string representation of the CoreBluetooth UUI for a connected peripheral.
///
///
/// Returns: An OSStatus result code.
///
///
/// If a CoreMIDI is connected to a BLE MIDI peripheral with the supplied UUID, it will disconnect.
#[cfg(feature = "objc2-core-foundation")]
pub fn MIDIBluetoothDriverDisconnect(uuid: &CFString) -> OSStatus;
}