Instance Method

readValue(completionHandler:)

Reads the value for the characteristic.

Declaration

func readValue(completionHandler completion: @escaping (Error?) -> Void)

Parameters

completion

The block executed after the request is processed.

error

nil on success; otherwise, error object indicating the reason for failure.

Discussion

The value is available from the value property after completion of the request.

See Also

Controlling a Characteristic

var value: Any?

The current value of the characteristic.

func writeValue(Any?, completionHandler: (Error?) -> Void)

Modifies the value of the characteristic.

func updateAuthorizationData(Data?, completionHandler: (Error?) -> Void)

Sets or clears authorization data used when writing to the characteristic.