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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
|
/*
* Copyright (C) 2012-2013 Collabora Ltd.
*
* This library is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 2.1 of the License, or
* (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this library. If not, see <http://www.gnu.org/licenses/>.
*
* Authors:
* Arun Raghavan <arun.raghavan@collabora.co.uk>
* Gustavo Padovan <gustavo.padovan@collabora.co.uk>
* Matthieu Bouron <matthieu.bouron@collabora.com>
*/
using GLib;
/* Reference:
* http://git.kernel.org/cgit/bluetooth/bluez.git/tree/doc/device-api.txt */
namespace org
{
namespace bluez
{
[DBus (name = "org.bluez.Error")]
public errordomain Error
{
NOT_READY,
FAILED,
IN_PROGRESS,
ALREADY_CONNECTED,
NOT_CONNECTED,
DOES_NOT_EXIST,
CONNECT_FAILED,
NOT_SUPPORTED,
INVALID_ARGUMENTS,
AUTHENTICATION_CANCELED,
AUTHENTICATION_FAILED,
AUTHENTICATION_REJECTED,
AUTHENTICATION_TIMEOUT,
CONNECTION_ATTEMPT_FAILED
}
[DBus (name = "org.bluez.Device1")]
public interface Device : Object
{
/* Methods. */
[DBus (name = "Connect")]
public abstract void connect ()
throws org.bluez.Error, DBusError, IOError;
[DBus (name = "Disconnect")]
public abstract void disconnect ()
throws org.bluez.Error, DBusError, IOError;
[DBus (name = "DisconnectProfile")]
public abstract void disconnect_profile (string uuid)
throws org.bluez.Error, DBusError, IOError;
[DBus (name = "Pair")]
public abstract void pair ()
throws org.bluez.Error, DBusError, IOError;
[DBus (name = "CancelPairing")]
public abstract void cancel_pairing ()
throws org.bluez.Error, DBusError, IOError;
/* Properties. */
[DBus (name = "Address")]
public abstract string address { owned get; }
[DBus (name = "Name")]
public abstract string name { owned get; }
[DBus (name = "Icon")]
public abstract string icon { owned get; }
[DBus (name = "Class")]
public abstract uint32 bluetooth_class { get; }
[DBus (name = "Appearance")]
public abstract uint16 appearance { get; }
[DBus (name = "UUIDs")]
public abstract string[] uuids { owned get; }
[DBus (name = "Paired")]
public abstract bool paired { get; }
[DBus (name = "Connected")]
public abstract bool connected { get; }
[DBus (name = "Trusted")]
public abstract bool trusted { get; set; }
[DBus (name = "Blocked")]
public abstract bool blocked { get; set; }
[DBus (name = "Alias")]
public abstract string alias { owned get; set; }
[DBus (name = "Adapter")]
public abstract ObjectPath adapter { owned get; }
[DBus (name = "LegacyPairing")]
public abstract bool legacy_pairing { get; }
[DBus (name = "Modalias")]
public abstract string mod_alias { owned get; }
[DBus (name = "RSSI")]
public abstract int16 rssi { get; }
}
}
}
|