Package com.zebra.bluetooth.btinsightlib
Class BtBondStateEvent
- java.lang.Object
-
- com.zebra.bluetooth.btinsightlib.BtBondStateEvent
-
- All Implemented Interfaces:
android.os.Parcelable
public class BtBondStateEvent extends java.lang.Object implements android.os.ParcelableClass that provides more information about bond status of remote device
-
-
Field Summary
Fields Modifier and Type Field Description static android.os.Parcelable.Creator<BtBondStateEvent>CREATORprivate intmBondStateprivate java.lang.StringmDeviceMacprivate java.lang.StringmDeviceNameprivate java.lang.StringmLastBondedAtprivate java.lang.StringmLastUnbondedAtprivate intmPeripheralTypeprivate java.lang.StringmSerialNumber
-
Constructor Summary
Constructors Modifier Constructor Description BtBondStateEvent()protectedBtBondStateEvent(android.os.Parcel in)Creates object of this class using serializable data given as input.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intdescribeContents()intgetBondState()Get the bond status of remote device.java.lang.StringgetDeviceMac()Get bluetooth MAC address of remote device.java.lang.StringgetDeviceName()Get the friendly name of remote devicejava.lang.StringgetLastBondedAt()Get the timestamp of bonded state w.r.t remote device during last time.java.lang.StringgetLastUnbondedAt()Get the timestamp of unbonded state w.r.t remote device during last time Remote device is identified viamDeviceMacormDeviceName.intgetPeripheralType()Get the type of remote peripheral connected to DUT.java.lang.StringgetSerialNumber()Get serial number of remote device.voidsetBondState(int bondState)Set the bond status of remote device.voidsetDeviceMac(java.lang.String deviceMac)Set bluetooth MAC address of remote device for reference in local DUTvoidsetDeviceName(java.lang.String deviceName)Set friendly name of remote device for reference in local DUT See alsogetDeviceName()voidsetLastBondedAt(java.lang.String lastBondedAt)Set the timestamp of bonded state w.r.t remote device during last time.voidsetLastUnbondedAt(java.lang.String lastUnbondedAt)Set the timestamp of unbonded state w.r.t remote device during last time.voidsetPeripheralType(int type)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
-
mDeviceName
private java.lang.String mDeviceName
-
mDeviceMac
private java.lang.String mDeviceMac
-
mLastBondedAt
private java.lang.String mLastBondedAt
-
mLastUnbondedAt
private java.lang.String mLastUnbondedAt
-
mBondState
private int mBondState
-
mSerialNumber
private java.lang.String mSerialNumber
-
mPeripheralType
private int mPeripheralType
-
CREATOR
public static final android.os.Parcelable.Creator<BtBondStateEvent> CREATOR
-
-
Method Detail
-
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 type)
Set the type of remote peripheral connected to DUT. SeegetPeripheralType()- Parameters:
type- type of remote peripheral
-
getDeviceName
public java.lang.String getDeviceName()
Get the friendly name of remote device- Returns:
- 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(java.lang.String serialNumber)
Set serial number of remote device. See alsogetSerialNumber()- Parameters:
serialNumber- string format of remote device's serial number
-
setDeviceName
public void setDeviceName(java.lang.String deviceName)
Set friendly name of remote device for reference in local DUT See alsogetDeviceName()- Parameters:
deviceName- name of remote device
-
getDeviceMac
public java.lang.String getDeviceMac()
Get bluetooth MAC address of remote device.- Returns:
- address of remote device
-
setDeviceMac
public void setDeviceMac(java.lang.String deviceMac)
Set bluetooth MAC address of remote device for reference in local DUT- Parameters:
deviceMac- address of remote device
-
getLastBondedAt
public java.lang.String getLastBondedAt()
Get the timestamp of bonded state w.r.t remote device during last time. Remote device is identified viamDeviceMacormDeviceName.- Returns:
- string format of timestamp when remote device bonded last time
-
setLastBondedAt
public void setLastBondedAt(java.lang.String lastBondedAt)
Set the timestamp of bonded state w.r.t remote device during last time. Remote device is identified viamDeviceMacormDeviceName.- Parameters:
lastBondedAt- string format of timestamp when remote device bonded last time
-
getLastUnbondedAt
public java.lang.String getLastUnbondedAt()
Get the timestamp of unbonded state w.r.t remote device during last time Remote device is identified viamDeviceMacormDeviceName.- Returns:
- string format of timestamp when remote device unbonded last time
-
setLastUnbondedAt
public void setLastUnbondedAt(java.lang.String lastUnbondedAt)
Set the timestamp of unbonded state w.r.t remote device during last time. Remote device is identified viamDeviceMacormDeviceName.- Parameters:
lastUnbondedAt- string format of timestamp when remote device unbonded last time
-
getBondState
public int getBondState()
Get the bond status of remote device. See alsoBtInsightConstants.BondState- Returns:
- bond status of remote device
-
setBondState
public void setBondState(int bondState)
Set the bond status of remote device. See alsoBtInsightConstants.BondState- Parameters:
bondState- bond status of remote device
-
writeToParcel
public void writeToParcel(android.os.Parcel dest, int flags)- Specified by:
writeToParcelin interfaceandroid.os.Parcelable
-
toString
@NonNull public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
describeContents
public int describeContents()
- Specified by:
describeContentsin interfaceandroid.os.Parcelable
-
-