Interface MeshManagerCallbacks
- All Known Implementing Classes:
BluetoothMeshNetwork
public interface MeshManagerCallbacks
Implement this class in order to get the transport callbacks from the
MeshManagerApi-
Method Summary
Modifier and TypeMethodDescriptionintgetMtu()Get mtu size supported by the peripheral nodevoidonMeshPduCreated(byte[] pdu) Send mesh pduvoidonNetworkImported(MeshNetwork meshNetwork) Callbacks notifying the network was importedvoidonNetworkImportFailed(String error) Callback that notifies in case the mesh network was unable to importedvoidonNetworkLoaded(MeshNetwork meshNetwork) Returns the network that was loadedvoidonNetworkLoadFailed(String error) Callback that notifies in case the mesh network was unable to loadvoidonNetworkUpdated(MeshNetwork meshNetwork) Returns the network that was updatedvoidsendProvisioningPdu(UnprovisionedMeshNode meshNode, byte[] pdu) Send mesh pdu
-
Method Details
-
onNetworkLoaded
Returns the network that was loaded- Parameters:
meshNetwork-that was loaded
-
onNetworkUpdated
Returns the network that was updatedThis callback is invoked for every message that was sent or received as it changes the contents of the network
- Parameters:
meshNetwork-that was loaded
-
onNetworkLoadFailed
Callback that notifies in case the mesh network was unable to load- Parameters:
error- error
-
onNetworkImported
Callbacks notifying the network was imported- Parameters:
meshNetwork-that was loaded
-
onNetworkImportFailed
Callback that notifies in case the mesh network was unable to imported- Parameters:
error- error
-
sendProvisioningPdu
Send mesh pdu- Parameters:
meshNode-UnprovisionedMeshNodepdu- mesh pdu to be sent
-
onMeshPduCreated
void onMeshPduCreated(byte[] pdu) Send mesh pdu- Parameters:
pdu- mesh pdu to be sent
-
getMtu
int getMtu()Get mtu size supported by the peripheral nodeThis is used to get the supported mtu size from the ble module, so that the messages that are larger than the supported mtu size could be segmented
- Returns:
- mtu size
-