java.lang.Object | |
↳ | android.bluetooth.le.ScanRecord |
Represents a scan record from Bluetooth LE scan.
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns the advertising flags indicating the discoverable mode and capability of the device.
| |||||||||||
Returns the local name of the BLE device.
| |||||||||||
Returns the manufacturer identifier, which is a non-negative number assigned by Bluetooth
SIG.
| |||||||||||
Returns the manufacturer specific data which is the content of manufacturer specific data
field.
| |||||||||||
Returns service data.
| |||||||||||
Returns a 16 bit uuid of the service that the service data is associated with.
| |||||||||||
Returns a list of service uuids within the advertisement that are used to identify the
bluetooth gatt services.
| |||||||||||
Returns the transmission power level of the packet in dBm.
| |||||||||||
Parse scan record bytes to
ScanRecord . | |||||||||||
Returns a string containing a concise, human-readable description of this
object.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Returns the advertising flags indicating the discoverable mode and capability of the device. Returns -1 if the flag field is not set.
Returns the local name of the BLE device. The is a UTF-8 encoded string.
Returns the manufacturer identifier, which is a non-negative number assigned by Bluetooth SIG.
Returns the manufacturer specific data which is the content of manufacturer specific data field. The first 2 bytes of the data contain the company id.
Returns service data. The first two bytes should be a 16 bit service uuid associated with the service data.
Returns a 16 bit uuid of the service that the service data is associated with.
Returns a list of service uuids within the advertisement that are used to identify the bluetooth gatt services.
Returns the transmission power level of the packet in dBm. Returns MIN_VALUE
if the field is not set. This value can be used to calculate the path loss of a received
packet using the following equation:
pathloss = txPowerLevel - rssi
Parse scan record bytes to ScanRecord
.
The format is defined in Bluetooth 4.1 specification, Volume 3, Part C, Section 11 and 18.
All numerical multi-byte entities and values shall use little-endian byte order.
scanRecord | The scan record of Bluetooth LE advertisement and/or scan response. |
---|
Returns a string containing a concise, human-readable description of this object. Subclasses are encouraged to override this method and provide an implementation that takes into account the object's type and data. The default implementation is equivalent to the following expression:
getClass().getName() + '@' + Integer.toHexString(hashCode())
See Writing a useful
toString
method
if you intend implementing your own toString
method.