core-bluetooth Setup bluetoooth central manager Declare and instantiate CBCentralManager with options


Example

Swift:

var centralManager:CBCentralManager!

centralManager = CBCentralManager(delegate: self, queue: nil, options: [CBCentralManagerOptionRestoreIdentifierKey : "com.companyname.appname.central"])

Objective C:

@property (nonatomic, strong) CBCentralManager *centralManager;

self.centralManager = [[CBCentralManager alloc] initWithDelegate:self queue:nil options:@{CBCentralManagerOptionRestoreIdentifierKey : @"com.companyname.appname.central"}];