Package com.zebra.bluetooth.btinsightlib
Class BtDeviceInfo
- java.lang.Object
-
- com.zebra.bluetooth.btinsightlib.BtDeviceInfo
-
- All Implemented Interfaces:
android.os.Parcelable
- Direct Known Subclasses:
BtScannerDeviceInfo
public class BtDeviceInfo extends java.lang.Object implements android.os.ParcelableClass that provides more information about Remote device details
-
-
Field Summary
Fields Modifier and Type Field Description static android.os.Parcelable.Creator<BtDeviceInfo>CREATOR
-
Constructor Summary
Constructors Modifier Constructor Description protectedBtDeviceInfo(android.os.Parcel in)BtDeviceInfo(BtDeviceInfo obj)copy constructor of the class that creates object using other BtDeviceInfo objectBtDeviceInfo(java.lang.String identityAddress)constructor of the class that creates object using identityAddress as input.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intdescribeContents()booleanequals(java.lang.Object o)java.lang.StringgetIdentityAddress()Get BT address of remote devicejava.lang.StringgetName()Get the friendly name of remote deviceintgetPeripheralType()Get the type of remote peripheral connected to DUT.java.lang.StringgetSerialNumber()Get serial number of remote device.inthashCode()voidsetName(java.lang.String name)Set friendly name of remote device for reference in local DUT See alsogetName()voidsetPeripheralType(int peripheralType)Set the type of remote peripheral connected to DUT.voidsetSerialNumber(java.lang.String serialNumber)Set serial number of remote device.java.lang.StringtoString()voidwriteToParcel(android.os.Parcel dest, int flags)
-
-
-
Field Detail
-
CREATOR
public static final android.os.Parcelable.Creator<BtDeviceInfo> CREATOR
-
-
Constructor Detail
-
BtDeviceInfo
public BtDeviceInfo(BtDeviceInfo obj)
copy constructor of the class that creates object using other BtDeviceInfo object- Parameters:
obj- object instance of the class or other class derived from the class
-
BtDeviceInfo
public BtDeviceInfo(java.lang.String identityAddress)
constructor of the class that creates object using identityAddress as input.- Parameters:
identityAddress- MAC address of remote device
-
BtDeviceInfo
protected BtDeviceInfo(android.os.Parcel in)
-
-
Method Detail
-
getIdentityAddress
public java.lang.String getIdentityAddress()
Get BT address of remote device- Returns:
- Bluetooth MAC address of remote device
-
toString
@NonNull public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
getName
public java.lang.String getName()
Get the friendly name of remote device- Returns:
- name of remote device
-
setName
public void setName(@NonNull java.lang.String name)Set friendly name of remote device for reference in local DUT See alsogetName()- Parameters:
name- name of remote device
-
getSerialNumber
public java.lang.String getSerialNumber()
Get serial number of remote device. Note: only legacy pairing devices' serial number would be valid and provided.- Returns:
- string format of remote device's serial number
-
setSerialNumber
public void setSerialNumber(@NonNull java.lang.String serialNumber)Set serial number of remote device. See alsogetSerialNumber()- Parameters:
serialNumber- string format of remote device's serial number
-
getPeripheralType
public int getPeripheralType()
Get the type of remote peripheral connected to DUT. This identification will be based on class of device that remote peripheral exhibits during discovery or connection process.- Returns:
- type of remote peripheral that is communicating with DUT.
See
BtInsightConstants.PeripheralType
-
setPeripheralType
public void setPeripheralType(int peripheralType)
Set the type of remote peripheral connected to DUT. SeegetPeripheralType()- Parameters:
peripheralType- type of remote peripheral
-
describeContents
public int describeContents()
- Specified by:
describeContentsin interfaceandroid.os.Parcelable
-
writeToParcel
public void writeToParcel(android.os.Parcel dest, int flags)- Specified by:
writeToParcelin interfaceandroid.os.Parcelable
-
-