summaryrefslogtreecommitdiffstats
path: root/java/BluetoothDevice.java
blob: 06f49222afbf8ab931f3b535bd1c7e8c5cfee51b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
import java.util.*;

public class BluetoothDevice extends BluetoothObject
{
    private long nativeInstance;

    public native BluetoothType getBluetoothType();
    public native BluetoothDevice clone();
    public native boolean disconnect();
    public native boolean connect();
    public native boolean connectProfile(String arg_UUID);
    public native boolean disconnectProfile(String arg_UUID);
    public native boolean pair();
    public native boolean cancelPairing();
    public native List<BluetoothGattService> getServices();
    public native String getAddress();
    public native String getName();
    public native String getAlias();
    public native void setAlias(String value);
    public native int getBluetoothClass();
    public native short getAppearance();
    public native String getIcon();
    public native boolean getPaired();
    public native boolean getTrusted();
    public native void setTrusted(boolean value);
    public native boolean getBlocked();
    public native void setBlocked(boolean value);
    public native boolean getLegacyPairing();
    public native short getRssi();
    public native boolean getConnected();
    public native String[] getUuids();
    public native String getModalias();
    public native BluetoothAdapter getAdapter();

    private native void delete();
    /*public BluetoothDevice()
    {
        System.out.println("mda");
    }*/
    private BluetoothDevice(long instance)
    {
        super(instance);
        nativeInstance = instance;
    }

    protected void finalize()
    {
        delete();
    }
}