Descriptor
public class Descriptor
extension Descriptor: Equatable
                Descriptor is a class implementing ReactiveX which wraps CoreBluetooth functions related to interaction with CBDescriptor Descriptors provide more information about a characteristic’s value.
- 
                  
                  
Intance of CoreBluetooth descriptor class
Declaration
Swift
public let descriptor: CBDescriptor - 
                  
                  
Characteristic to which this descriptor belongs.
Declaration
Swift
public let characteristic: Characteristic - 
                  
                  
The Bluetooth UUID of the
Descriptorinstance.Declaration
Swift
public var uuid: CBUUID { get } - 
                  
                  
The value of the descriptor. It can be written and read through functions on
Descriptorinstance.Declaration
Swift
public var value: Any? { get } - 
                  
                  
Function that allow to observe writes that happened for descriptor.
Observable can ends with following errors:
BluetoothError.descriptorWriteFailedBluetoothError.peripheralDisconnectedBluetoothError.destroyedBluetoothError.bluetoothUnsupportedBluetoothError.bluetoothUnauthorizedBluetoothError.bluetoothPoweredOffBluetoothError.bluetoothInUnknownStateBluetoothError.bluetoothResetting
Declaration
Swift
public func observeWrite() -> Observable<Descriptor>Return Value
Observable that emits
nextwithDescriptorinstance every time when write has happened. It’s infinite stream, so.completeis never called. - 
                  
                  
Function that triggers write of data to descriptor. Write is called after subscribtion to
Observableis made.Observable can ends with following errors:
BluetoothError.descriptorWriteFailedBluetoothError.peripheralDisconnectedBluetoothError.destroyedBluetoothError.bluetoothUnsupportedBluetoothError.bluetoothUnauthorizedBluetoothError.bluetoothPoweredOffBluetoothError.bluetoothInUnknownStateBluetoothError.bluetoothResetting
Declaration
Swift
public func writeValue(_ data: Data) -> Single<Descriptor>Parameters
dataDatathat’ll be written toDescriptorinstanceReturn Value
Singlethat emitsNextwithDescriptorinstance, once value is written successfully. - 
                  
                  
Function that allow to observe value updates for
Descriptorinstance.Observable can ends with following errors:
BluetoothError.descriptorReadFailedBluetoothError.peripheralDisconnectedBluetoothError.destroyedBluetoothError.bluetoothUnsupportedBluetoothError.bluetoothUnauthorizedBluetoothError.bluetoothPoweredOffBluetoothError.bluetoothInUnknownStateBluetoothError.bluetoothResetting
Declaration
Swift
public func observeValueUpdate() -> Observable<Descriptor>Return Value
Observable that emits
nextwithDescriptorinstance every time when value has changed. It’s infinite stream, so.completeis never called. - 
                  
                  
Function that triggers read of current value of the
Descriptorinstance. Read is called after subscription toObservableis made.Observable can ends with following errors:
BluetoothError.descriptorReadFailedBluetoothError.peripheralDisconnectedBluetoothError.destroyedBluetoothError.bluetoothUnsupportedBluetoothError.bluetoothUnauthorizedBluetoothError.bluetoothPoweredOffBluetoothError.bluetoothInUnknownStateBluetoothError.bluetoothResetting
Declaration
Swift
public func readValue() -> Single<Descriptor>Return Value
Singlewhich emitsnextwith given descriptor when value is ready to read. 
View on GitHub
        Descriptor Class Reference