From 73d3147ba8bae560edda38e72d332595d9fd2b4c Mon Sep 17 00:00:00 2001 From: joonhaengHeo <85541460+joonhaengHeo@users.noreply.github.com> Date: Fri, 15 Mar 2024 11:23:34 +0900 Subject: [PATCH] [Android] Add StopDevicePairing method in Java (#32566) --- .../chip/devicecontroller/ChipDeviceController.java | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/controller/java/src/chip/devicecontroller/ChipDeviceController.java b/src/controller/java/src/chip/devicecontroller/ChipDeviceController.java index 25d300ec1cadc1..d6b31c59dabcd5 100644 --- a/src/controller/java/src/chip/devicecontroller/ChipDeviceController.java +++ b/src/controller/java/src/chip/devicecontroller/ChipDeviceController.java @@ -453,6 +453,15 @@ public void unpairDeviceCallback(long deviceId, UnpairDeviceCallback callback) { unpairDeviceCallback(deviceControllerPtr, deviceId, callback); } + /** + * This function stops a pairing or commissioning process that is in progress. + * + * @param deviceId The remote device Id. + */ + public void stopDevicePairing(long deviceId) { + stopDevicePairing(deviceControllerPtr, deviceId); + } + /** * Returns a pointer to a device currently being commissioned. This should be used before the * device is operationally available. @@ -1474,6 +1483,8 @@ private native void continueCommissioning( private native void unpairDeviceCallback( long deviceControllerPtr, long deviceId, UnpairDeviceCallback callback); + private native void stopDevicePairing(long deviceControllerPtr, long deviceId); + private native long getDeviceBeingCommissionedPointer(long deviceControllerPtr, long nodeId); private native void getConnectedDevicePointer(