cancel Bluetooth Bond Process - Android Bluetooth

Android examples for Bluetooth:Bluetooth Bond

Description

cancel Bluetooth Bond Process

Demo Code


//package com.java2s;

import java.lang.reflect.Method;

import android.bluetooth.BluetoothDevice;

public class Main {
    static public boolean cancelBondProcess(Class btClass,
            BluetoothDevice device) throws Exception {
        Method createBondMethod = btClass.getMethod("cancelBondProcess");
        Boolean returnValue = (Boolean) createBondMethod.invoke(device);
        return returnValue.booleanValue();
    }/* ww  w  .  ja v a2s  .co  m*/
}

Related Tutorials