seven365-zyprinter 0.0.10 → 0.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -377,7 +377,7 @@ import Network
|
|
|
377
377
|
extension ZywellSDK: POSBLEManagerDelegate {
|
|
378
378
|
|
|
379
379
|
@objc(POSdidUpdatePeripheralList:RSSIList:)
|
|
380
|
-
public func poSdidUpdatePeripheralList(_ peripherals: [Any]
|
|
380
|
+
public func poSdidUpdatePeripheralList(_ peripherals: [Any], rssiList: [Any]) {
|
|
381
381
|
guard let peripherals = peripherals as? [CBPeripheral],
|
|
382
382
|
let rssis = rssiList as? [NSNumber] else { return }
|
|
383
383
|
|
|
@@ -386,7 +386,7 @@ extension ZywellSDK: POSBLEManagerDelegate {
|
|
|
386
386
|
}
|
|
387
387
|
|
|
388
388
|
@objc(POSdidConnectPeripheral:)
|
|
389
|
-
public func poSdidConnectPeripheral(_ peripheral: CBPeripheral
|
|
389
|
+
public func poSdidConnectPeripheral(_ peripheral: CBPeripheral) {
|
|
390
390
|
DispatchQueue.main.async { [weak self] in
|
|
391
391
|
self?.connectionCompletion?(true, nil)
|
|
392
392
|
self?.connectionCompletion = nil
|
|
@@ -394,8 +394,8 @@ extension ZywellSDK: POSBLEManagerDelegate {
|
|
|
394
394
|
}
|
|
395
395
|
|
|
396
396
|
@objc(POSdidFailToConnectPeripheral:error:)
|
|
397
|
-
public func poSdidFailToConnectPeripheral(_ peripheral: CBPeripheral
|
|
398
|
-
let errorMsg = error
|
|
397
|
+
public func poSdidFailToConnectPeripheral(_ peripheral: CBPeripheral, error: Error) {
|
|
398
|
+
let errorMsg = error.localizedDescription
|
|
399
399
|
DispatchQueue.main.async { [weak self] in
|
|
400
400
|
self?.connectionCompletion?(false, errorMsg)
|
|
401
401
|
self?.connectionCompletion = nil
|
|
@@ -403,12 +403,12 @@ extension ZywellSDK: POSBLEManagerDelegate {
|
|
|
403
403
|
}
|
|
404
404
|
|
|
405
405
|
@objc(POSdidDisconnectPeripheral:isAutoDisconnect:)
|
|
406
|
-
public func poSdidDisconnectPeripheral(_ peripheral: CBPeripheral
|
|
406
|
+
public func poSdidDisconnectPeripheral(_ peripheral: CBPeripheral, isAutoDisconnect: Bool) {
|
|
407
407
|
// Handle disconnection
|
|
408
408
|
}
|
|
409
409
|
|
|
410
410
|
@objc(POSdidWriteValueForCharacteristic:error:)
|
|
411
|
-
public func poSdidWriteValueForCharacteristic(_ character: CBCharacteristic
|
|
411
|
+
public func poSdidWriteValueForCharacteristic(_ character: CBCharacteristic, error: Error?) {
|
|
412
412
|
DispatchQueue.main.async { [weak self] in
|
|
413
413
|
if let error = error {
|
|
414
414
|
self?.printCompletion?(false, error.localizedDescription)
|
package/package.json
CHANGED