doc: Document the deprecated RemoveProvider method call
[platform/upstream/connman.git] / doc / manager-api.txt
1 Manager hierarchy
2 =================
3
4 Service         net.connman
5 Interface       net.connman.Manager
6 Object path     /
7
8 Methods         dict GetProperties()
9
10                         Returns all global system properties. See the
11                         properties section for available properties.
12
13                         Possible Errors: [service].Error.InvalidArguments
14
15                 void SetProperty(string name, variant value)
16
17                         Changes the value of the specified property. Only
18                         properties that are listed as read-write are
19                         changeable. On success a PropertyChanged signal
20                         will be emitted.
21
22                         Possible Errors: [service].Error.InvalidArguments
23                                          [service].Error.InvalidProperty
24
25                 array{object,dict} GetTechnologies()
26
27                         Returns a list of tuples with technology object
28                         path and dictionary of technology properties.
29
30                         Possible Errors: [service].Error.InvalidArguments
31
32                 array{object,dict} GetServices()
33
34                         Returns a sorted list of tuples with service
35                         object path and dictionary of service properties.
36
37                         This list will not contain sensitive information
38                         like passphrases etc.
39
40                         Possible Errors: [service].Error.InvalidArguments
41
42                 object ConnectProvider(dict provider)   [deprecated]
43
44                         Connect to a VPN specified by the given provider
45                         properties.
46
47                         When successful this method will return the object
48                         path of the VPN service object.
49
50                         This method can also be used to connect to an
51                         already existing VPN.
52
53                         This method call will only return in case of an
54                         error or when the service is fully connected. So
55                         setting a longer D-Bus timeout might be a really
56                         good idea.
57
58                         When 'SessionMode' property is enabled, this method
59                         call is disallowed.
60
61                         This API is deprecated and should not be used.
62                         The VPN configuration API is provided by ConnMan
63                         VPN daemon and user should use that one instead.
64
65                         Possible Errors: [service].Error.InvalidArguments
66
67                 void RemoveProvider(object path)        [deprecated]
68
69                         Remove a VPN specified by the object path.
70
71                 void RegisterAgent(object path)
72
73                         Register new agent for handling user requests.
74
75                         Possible Errors: [service].Error.InvalidArguments
76
77                 void UnregisterAgent(object path)
78
79                         Unregister an existing agent.
80
81                         Possible Errors: [service].Error.InvalidArguments
82
83                 void RegisterCounter(object path, uint32 accuracy, uint32 period)  [experimental]
84
85                         Register a new counter for user notifications.
86
87                         The accuracy is specified in kilo-bytes and defines
88                         a threshold for counter updates. Together with the
89                         period value it defines how often user space needs
90                         to be updated. The period value is in seconds.
91
92                         This interface is not meant for time tracking. If
93                         the time needs to be tracked down to the second, it
94                         is better to have a real timer running inside the
95                         application than using this interface.
96
97                         Also getting notified for every kilo-byte is a bad
98                         choice (even if the interface supports it). Something
99                         like 10 kilo-byte units or better 1 mega-byte seems
100                         to be a lot more reasonable and better for the user.
101
102                         Possible Errors: [service].Error.InvalidArguments
103
104                 void UnregisterCounter(object path)  [experimental]
105
106                         Unregister an existing counter.
107
108                         Possible Errors: [service].Error.InvalidArguments
109
110                 object CreateSession(dict settings, object notifier)  [experimental]
111
112                         Create a new session for the application. Every
113                         application can create multiple session with
114                         different settings. The settings are described
115                         as part of the session interface.
116
117                         The notifier allows asynchronous notification about
118                         session specific changes. These changes can be
119                         for online/offline state or IP address changes or
120                         similar things the application is required to
121                         handle.
122
123                         Every application should at least create one session
124                         to inform about its requirements and it purpose.
125
126                 void DestroySession(object session)  [experimental]
127
128                         Remove the previously created session.
129
130                         If an application exits unexpectatly the session
131                         will be automatically destroyed.
132
133                 object path, dict, fd RequestPrivateNetwork(dict options)
134                                                                 [experimental]
135
136                         Request a new Private Network, which includes the
137                         creation of a tun/tap interface, and IP
138                         configuration, NAT and IP forwarding on that
139                         interface.
140                         An object path, a dictionnary and a file descriptor
141                         with IP settings are returned.
142
143                         Possible Errors: [service].Error.InvalidArguments
144                                          [service].Error.NotSupported
145
146                 void ReleasePrivateNetwork(object path) [experimental]
147
148                         Releases a private network.
149
150                         Possible Errors: [service].Error.InvalidArguments
151
152 Signals         TechnologyAdded(object path, dict properties)
153
154                         Signal that is sent when a new technology is added.
155
156                         It contains the object path of the technology and
157                         also its properties.
158
159                 TechnologyRemoved(object path)
160
161                         Signal that is sent when a technology has been removed.
162
163                         The object path is no longer accessible after this
164                         signal and only emitted for reference.
165
166                 ServicesChanged(array{object, dict}, array{object})
167
168                         Signals a list of services that have been changed
169                         via the first array. And a list of service that
170                         have been removed via the second array.
171
172                         The list of added services is sorted. The dictionary
173                         with the properties might be empty in case none of
174                         the properties have changed. Or only contains the
175                         properties that have changed.
176
177                         For newly added services the whole set of properties
178                         will be present.
179
180                         The list of removed services can be empty.
181
182                         This signal will only be triggered when the sort
183                         order of the service list or the number of services
184                         changes. It will not be emitted if only a property
185                         of the service object changes. For that it is
186                         required to watch the PropertyChanged signal of
187                         the service object.
188
189                 PropertyChanged(string name, variant value)
190
191                         This signal indicates a changed value of the given
192                         property.
193
194 Properties      string State [readonly]
195
196                         The global connection state of a system. Possible
197                         values are "offline", "idle", "ready" and "online".
198
199                         If the device is in offline mode, the value "offline"
200                         indicates this special global state. It can also be
201                         retrieved via the OfflineMode property, but is kept
202                         here for consistency and to differentiate from "idle".
203
204                         However when OfflineMode property is true, the State
205                         property can still be "idle", "ready" or "online"
206                         since it is possible by the end user to re-enable
207                         individual technologies like WiFi and Bluetooth while
208                         in offline mode.
209
210                         The states "idle", "ready" and "online" match to
211                         states from the services. If no service is in
212                         either "ready" or "online" state it will indicate
213                         the "idle" state.
214
215                         If at least one service is in "ready" state and no
216                         service is in "online" state, then it will indicate
217                         the "ready" state.
218
219                         When at least one service is in "online" state,
220                         this property will indicate "online" as well.
221
222                 boolean OfflineMode [readwrite]
223
224                         The offline mode indicates the global setting for
225                         switching all radios on or off. Changing offline mode
226                         to true results in powering down all devices. When
227                         leaving offline mode the individual policy of each
228                         device decides to switch the radio back on or not.
229
230                         During offline mode, it is still possible to switch
231                         certain technologies manually back on. For example
232                         the limited usage of WiFi or Bluetooth devices might
233                         be allowed in some situations.
234
235                 boolean SessionMode [readwrite]  [experminental]
236
237                         This disables the auto connect feature. It should be
238                         enabled when the Session API is used. When SessionMode
239                         is enabled, 'ConnectService' and 'ConnectProvider'
240                         method calls are disallowed.
241
242                         The default value is false.