5 Interface net.connman.Manager
8 Methods dict GetProperties()
10 Returns all global system properties. See the
11 properties section for available properties.
13 Possible Errors: [service].Error.InvalidArguments
15 void SetProperty(string name, variant value)
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
22 Possible Errors: [service].Error.InvalidArguments
23 [service].Error.InvalidProperty
25 void RequestScan(string type)
27 Request to trigger a scan for the specified
28 technology. The empty string "" triggers scanning
31 Possible Errors: [service].Error.InvalidArguments
33 void EnableTechnology(string type)
35 Enable specified type of technologies.
37 Possible Errors: [service].Error.InvalidArguments
39 void DisableTechnology(string type)
41 Disable specified type of technologies.
43 Possible Errors: [service].Error.InvalidArguments
45 array{object,dict} GetServices()
47 Returns a sorted list of tuples with service
48 object path and dictionary of service properties.
50 This list will not contain sensitive information
53 Possible Errors: [service].Error.InvalidArguments
55 object LookupService(string pattern)
57 Lookup a service matching the specific pattern.
59 Examples are interface names like "eth0", "wlan0"
60 etc. or service names like "hotspot" etc.
62 In case of multiple services match the the pattern
65 Possible Errors: [service].Error.InvalidArguments
66 [service].Error.NotUnique
67 [service].Error.NotFound
69 object ConnectService(dict network)
71 Connect to a network specified by the given
74 For connecting to a hidden WiFi network for example
75 it is required that Type = "wifi" and the SSID
76 properties are provided.
78 When successful this method will return object
79 path of the service object.
81 This method can also be used to connect to an
82 already existing service. It works exactly the
83 same as executing the Connect method from the
86 This method call will only return in case of an
87 error or when the service is fully connected. So
88 setting a longer D-Bus timeout might be a really
91 When 'SessionMode' property is enabled, this method
94 Possible Errors: [service].Error.InvalidArguments
96 void ProvisionService(string configuration)
98 Provide a configuration for services.
100 Service configuration is provided as a single string
101 that follows the same format as configuration files,
102 see config-format.txt. An exception to this format
103 is that only one service can be provisioned per call.
105 Possible Errors: [service].Error.InvalidArguments
107 object ConnectProvider(dict provider)
109 Connect to a VPN specified by the given provider
112 When successful this method will return the object
113 path of the VPN service object.
115 This method can also be used to connect to an
116 already existing VPN.
118 This method call will only return in case of an
119 error or when the service is fully connected. So
120 setting a longer D-Bus timeout might be a really
123 When 'SessionMode' property is enabled, this method
126 Possible Errors: [service].Error.InvalidArguments
128 void RegisterAgent(object path)
130 Register new agent for handling user requests.
132 Possible Errors: [service].Error.InvalidArguments
134 void UnregisterAgent(object path)
136 Unregister an existing agent.
138 Possible Errors: [service].Error.InvalidArguments
140 void RegisterCounter(object path, uint32 accuracy, uint32 period) [experimental]
142 Register a new counter for user notifications.
144 The accuracy is specified in kilo-bytes and defines
145 a threshold for counter updates. Together with the
146 period value it defines how often user space needs
147 to be updated. The period value is in seconds.
149 This interface is not meant for time tracking. If
150 the time needs to be tracked down to the second, it
151 is better to have a real timer running inside the
152 application than using this interface.
154 Also getting notified for every kilo-byte is a bad
155 choice (even if the interface supports it). Something
156 like 10 kilo-byte units or better 1 mega-byte seems
157 to be a lot more reasonable and better for the user.
159 Possible Errors: [service].Error.InvalidArguments
161 void UnregisterCounter(object path) [experimental]
163 Unregister an existing counter.
165 Possible Errors: [service].Error.InvalidArguments
167 object CreateSession(dict settings, object notifier)
169 Create a new session for the application. Every
170 application can create multiple session with
171 different settings. The settings are described
172 as part of the session interface.
174 The notifier allows asynchronous notification about
175 session specific changes. These changes can be
176 for online/offline state or IP address changes or
177 similar things the application is required to
180 Every application should at least create one session
181 to inform about its requirements and it purpose.
183 void DestroySession(object session)
185 Remove the previously created session.
187 If an application exits unexpectatly the session
188 will be automatically destroyed.
190 object path, dict, fd RequestPrivateNetwork(dict options)
193 Request a new Private Network, which includes the
194 creation of a tun/tap interface, and IP
195 configuration, NAT and IP forwarding on that
197 An object path, a dictionnary and a file descriptor
198 with IP settings are returned.
200 Possible Errors: [service].Error.InvalidArguments
201 [service].Error.NotSupported
203 void ReleasePrivateNetwork(object path) [experimental]
205 Releases a private network.
207 Possible Errors: [service].Error.InvalidArguments
209 Signals PropertyChanged(string name, variant value)
211 This signal indicates a changed value of the given
214 Properties string State [readonly]
216 The global connection state of a system. Possible
217 values are "online" if at least one connection exists
218 and "offline" if no device is connected.
220 In certain situations the state might change to
221 the value "connected". This can only be seen if
222 previously no connection was present.
224 array{string} AvailableTechnologies [readonly]
226 The list of available technologies. The strings
227 are the same as the ones from the service types.
229 array{string} EnabledTechnologies [readonly]
231 The list of enabled technologies. The strings
232 are the same as the ones from the service types.
234 array{string} ConnectedTechnologies [readonly]
236 The list of connected technologies. The strings
237 are the same as the ones from the service type.
239 string DefaultTechnology [readonly]
241 The current connected technology which holds the
244 boolean OfflineMode [readwrite]
246 The offline mode indicates the global setting for
247 switching all radios on or off. Changing offline mode
248 to true results in powering down all devices. When
249 leaving offline mode the individual policy of each
250 device decides to switch the radio back on or not.
252 During offline mode, it is still possible to switch
253 certain technologies manually back on. For example
254 the limited usage of WiFi or Bluetooth devices might
255 be allowed in some situations.
257 array{object} Technologies [readonly]
259 List of technology object paths.
261 array{object} Services [readonly]
263 List of service object paths. The list is sorted
264 internally to have the service with the default
265 route always first and then the favorite services
266 followed by scan results.
268 This list represents the available services for the
269 current selected profile. If the profile gets changed
270 then this list will be updated.
272 The same list is available via the profile object
273 itself. It is just provided here for convenience of
274 applications only dealing with the current active
277 boolean SessionMode [readwrite] [experminental]
279 This disables the auto connect feature. It should be
280 enabled when the Session API is used. When SessionMode
281 is enabled, 'ConnectService' and 'ConnectProvider'
282 method calls are disallowed.
284 The default value is false.