Java Code Examples for android.bluetooth.le.ScanRecord#getDeviceName()

The following examples show how to use android.bluetooth.le.ScanRecord#getDeviceName() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
public static ScanRecordCompat from(Object lollipopScanRecord) {
    if (lollipopScanRecord == null) {
        return null;

    sr = (ScanRecord) lollipopScanRecord;
    ScanRecordCompat retVal = new ScanRecordCompat();
    retVal.advertiseFlags = sr.getAdvertiseFlags();
    retVal.bytes = sr.getBytes();
    retVal.deviceName = sr.getDeviceName();
    retVal.manufacturerSpecificData = sr.getManufacturerSpecificData();
    retVal.serviceData = sr.getServiceData();
    retVal.serviceUuids = sr.getServiceUuids();
    retVal.txPowerLevel = sr.getTxPowerLevel();
    return retVal;

Example 2
ScanRecordCompat(ScanRecord record) {
    mServiceUuids = record.getServiceUuids();
    mManufacturerSpecificData = record.getManufacturerSpecificData();
    mServiceData = record.getServiceData();
    mDeviceName = record.getDeviceName();
    mAdvertiseFlags = record.getAdvertiseFlags();
    mTxPowerLevel = record.getTxPowerLevel();
    mBytes = record.getBytes();