# multiplatform

Mathis [Off The Grid]

11/08/2023, 4:13 PM
I'm trying to implement a Bluetooth solution using platform specific logic. When creating a
centralManagerDelegate = object : NSObject(), CBCentralManagerDelegateProtocol
, I'm trying to implement some of its functions. However, because they all have the same function name and only vary in the parameter types, and names, I have two functions which have exactly the same parameter types required and this creates a conflicting overload. The two conflicting functions are defined below :
override fun centralManager(central: CBCentralManager, didDisconnectPeripheral: CBPeripheral, error: NSError?) {
override fun centralManager(central: CBCentralManager, didFailToConnectPeripheral: CBPeripheral, error: NSError?) {
I have tried renaming the functions but it doesn't work with overriding, and annotations such as
don't seem to work for overriding functions. Has anyone encountered a similar issue? I am using Kotlin Multiplatform plugin version 0.6.1 and Kotlin version 1.9.0

Sebastian Sellmair [JB]

11/13/2023, 2:08 PM
See this example: You are required to
cc @etolstoy