dbus: Change BSS, Network and some errors interface names

Remove ".Interface" part from BSS and Network objects and some
error names.
This commit is contained in:
Witold Sowa 2010-01-09 11:40:15 +02:00 committed by Jouni Malinen
parent c610dba137
commit 8e5568f874
6 changed files with 36 additions and 36 deletions

View File

@ -202,7 +202,7 @@ fi.w1.wpa_supplicant1.CreateInterface.
<p>Disassociates the interface from current network.</p>
<h4>Possible errors</h4>
<dl>
<dt>fi.w1.wpa_supplicant1.Interface.NotConnected</dt>
<dt>fi.w1.wpa_supplicant1.NotConnected</dt>
<dd>Interface is not connected to any network.</dd>
</dl>
</li>
@ -239,7 +239,7 @@ fi.w1.wpa_supplicant1.CreateInterface.
</dl>
<h4>Possible errors</h4>
<dl>
<dt>fi.w1.wpa_supplicant1.Interface.NetworkUnknown</dt>
<dt>fi.w1.wpa_supplicant1.NetworkUnknown</dt>
<dd>A passed path doesn't point to any network object.</dd>
<dt>fi.w1.wpa_supplicant1.InvalidArgs</dt>
<dd>A passed path doesn't point to any network object.</dd>
@ -258,7 +258,7 @@ fi.w1.wpa_supplicant1.CreateInterface.
</dl>
<h4>Possible errors</h4>
<dl>
<dt>fi.w1.wpa_supplicant1.Interface.NetworkUnknown</dt>
<dt>fi.w1.wpa_supplicant1.NetworkUnknown</dt>
<dd>A passed path doesn't point to any network object.</dd>
<dt>fi.w1.wpa_supplicant1.InvalidArgs</dt>
<dd>A passed path doesn't point to any network object.</dd>
@ -277,7 +277,7 @@ fi.w1.wpa_supplicant1.CreateInterface.
</dl>
<h4>Possible errors</h4>
<dl>
<dt>fi.w1.wpa_supplicant1.Interface.BlobExists</dt>
<dt>fi.w1.wpa_supplicant1.BlobExists</dt>
<dd>A blob with the specified name already exists.</dd>
</dl>
</li>
@ -292,7 +292,7 @@ fi.w1.wpa_supplicant1.CreateInterface.
</dl>
<h4>Possible errors</h4>
<dl>
<dt>fi.w1.wpa_supplicant1.Interface.BlobUnknown</dt>
<dt>fi.w1.wpa_supplicant1.BlobUnknown</dt>
<dd>A blob with the specified name doesn't exist.</dd>
</dl>
</li>
@ -312,7 +312,7 @@ fi.w1.wpa_supplicant1.CreateInterface.
</dl>
<h4>Possible errors</h4>
<dl>
<dt>fi.w1.wpa_supplicant1.Interface.BlobUnknown</dt>
<dt>fi.w1.wpa_supplicant1.BlobUnknown</dt>
<dd>A blob with the specified name doesn't exist.</dd>
</dl>
</li>
@ -603,7 +603,7 @@ Interface implemented by objects related to network interface added to
</ul>
\section dbus_bss fi.w1.wpa_supplicant1.Interface.BSS
\section dbus_bss fi.w1.wpa_supplicant1.BSS
Interface implemented by objects representing a scanned BSSs, i.e.,
scan results.
@ -668,7 +668,7 @@ scan results.
</ul>
\section dbus_network fi.w1.wpa_supplicant1.Interface.Network
\section dbus_network fi.w1.wpa_supplicant1.Network
Interface implemented by objects representing configured networks,
i.e., returned by fi.w1.wpa_supplicant1.Interface.AddNetwork.

View File

@ -1,7 +1,7 @@
/*
* WPA Supplicant / dbus-based control interface
* Copyright (c) 2006, Dan Williams <dcbw@redhat.com> and Red Hat, Inc.
* Copyright (c) 2009, Witold Sowa <witold.sowa@gmail.com>
* Copyright (c) 2009-2010, Witold Sowa <witold.sowa@gmail.com>
* Copyright (c) 2009, Jouni Malinen <j@w1.fi>
*
* This program is free software; you can redistribute it and/or modify
@ -181,7 +181,7 @@ static void wpas_dbus_signal_bss(struct wpa_supplicant *wpa_s,
goto err;
wpa_dbus_get_object_properties(iface, bss_obj_path,
WPAS_DBUS_NEW_IFACE_BSSID,
WPAS_DBUS_NEW_IFACE_BSS,
&iter_dict);
if (!wpa_dbus_dict_close_write(&iter, &iter_dict))
@ -752,7 +752,7 @@ void wpas_dbus_bss_signal_prop_changed(struct wpa_supplicant *wpa_s,
wpa_s->dbus_new_path, id);
wpa_dbus_mark_property_changed(wpa_s->global->dbus, path,
WPAS_DBUS_NEW_IFACE_BSSID, prop);
WPAS_DBUS_NEW_IFACE_BSS, prop);
}
@ -1096,52 +1096,52 @@ int wpas_dbus_unregister_network(struct wpa_supplicant *wpa_s, int nid)
static const struct wpa_dbus_property_desc wpas_dbus_bss_properties[] = {
{ "SSID", WPAS_DBUS_NEW_IFACE_BSSID, "ay",
{ "SSID", WPAS_DBUS_NEW_IFACE_BSS, "ay",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_ssid,
NULL,
R
},
{ "BSSID", WPAS_DBUS_NEW_IFACE_BSSID, "ay",
{ "BSSID", WPAS_DBUS_NEW_IFACE_BSS, "ay",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_bssid,
NULL,
R
},
{ "Privacy", WPAS_DBUS_NEW_IFACE_BSSID, "b",
{ "Privacy", WPAS_DBUS_NEW_IFACE_BSS, "b",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_privacy,
NULL,
R
},
{ "Mode", WPAS_DBUS_NEW_IFACE_BSSID, "s",
{ "Mode", WPAS_DBUS_NEW_IFACE_BSS, "s",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_mode,
NULL,
R
},
{ "Signal", WPAS_DBUS_NEW_IFACE_BSSID, "n",
{ "Signal", WPAS_DBUS_NEW_IFACE_BSS, "n",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_signal,
NULL,
R
},
{ "Frequency", WPAS_DBUS_NEW_IFACE_BSSID, "q",
{ "Frequency", WPAS_DBUS_NEW_IFACE_BSS, "q",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_frequency,
NULL,
R
},
{ "Rates", WPAS_DBUS_NEW_IFACE_BSSID, "au",
{ "Rates", WPAS_DBUS_NEW_IFACE_BSS, "au",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_rates,
NULL,
R
},
{ "WPAIE", WPAS_DBUS_NEW_IFACE_BSSID, "ay",
{ "WPAIE", WPAS_DBUS_NEW_IFACE_BSS, "ay",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_wpaie,
NULL,
R
},
{ "RSNIE", WPAS_DBUS_NEW_IFACE_BSSID, "ay",
{ "RSNIE", WPAS_DBUS_NEW_IFACE_BSS, "ay",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_rsnie,
NULL,
R
},
{ "WPSIE", WPAS_DBUS_NEW_IFACE_BSSID, "ay",
{ "WPSIE", WPAS_DBUS_NEW_IFACE_BSS, "ay",
(WPADBusPropertyAccessor) wpas_dbus_getter_bss_wpsie,
NULL,
R
@ -1151,7 +1151,7 @@ static const struct wpa_dbus_property_desc wpas_dbus_bss_properties[] = {
static const struct wpa_dbus_signal_desc wpas_dbus_bss_signals[] = {
{ "PropertiesChanged", WPAS_DBUS_NEW_IFACE_BSSID,
{ "PropertiesChanged", WPAS_DBUS_NEW_IFACE_BSS,
{
{ "properties", "a{sv}", ARG_OUT },
END_ARGS

View File

@ -1,7 +1,7 @@
/*
* WPA Supplicant / dbus-based control interface
* Copyright (c) 2006, Dan Williams <dcbw@redhat.com> and Red Hat, Inc.
* Copyright (c) 2009, Witold Sowa <witold.sowa@gmail.com>
* Copyright (c) 2009-2010, Witold Sowa <witold.sowa@gmail.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
@ -54,10 +54,10 @@ enum wpas_dbus_bss_prop {
#define WPAS_DBUS_NEW_IFACE_WPS WPAS_DBUS_NEW_IFACE_INTERFACE ".WPS"
#define WPAS_DBUS_NEW_NETWORKS_PART "Networks"
#define WPAS_DBUS_NEW_IFACE_NETWORK WPAS_DBUS_NEW_IFACE_INTERFACE ".Network"
#define WPAS_DBUS_NEW_IFACE_NETWORK WPAS_DBUS_NEW_INTERFACE ".Network"
#define WPAS_DBUS_NEW_BSSIDS_PART "BSSs"
#define WPAS_DBUS_NEW_IFACE_BSSID WPAS_DBUS_NEW_IFACE_INTERFACE ".BSS"
#define WPAS_DBUS_NEW_IFACE_BSS WPAS_DBUS_NEW_INTERFACE ".BSS"
/* Errors */
@ -72,14 +72,14 @@ enum wpas_dbus_bss_prop {
WPAS_DBUS_NEW_INTERFACE ".InterfaceUnknown"
#define WPAS_DBUS_ERROR_NOT_CONNECTED \
WPAS_DBUS_NEW_IFACE_INTERFACE ".NotConnected"
WPAS_DBUS_NEW_INTERFACE ".NotConnected"
#define WPAS_DBUS_ERROR_NETWORK_UNKNOWN \
WPAS_DBUS_NEW_IFACE_INTERFACE ".NetworkUnknown"
WPAS_DBUS_NEW_INTERFACE ".NetworkUnknown"
#define WPAS_DBUS_ERROR_BLOB_EXISTS \
WPAS_DBUS_NEW_IFACE_INTERFACE ".BlobExists"
WPAS_DBUS_NEW_INTERFACE ".BlobExists"
#define WPAS_DBUS_ERROR_BLOB_UNKNOWN \
WPAS_DBUS_NEW_IFACE_INTERFACE ".BlobUnknown"
WPAS_DBUS_NEW_INTERFACE ".BlobUnknown"
#ifdef CONFIG_CTRL_IFACE_DBUS_NEW

View File

@ -38,20 +38,20 @@ def main():
dbus_interface=dbus.PROPERTIES_IFACE)
if len(res) > 0:
bss_obj = bus.get_object("fi.w1.wpa_supplicant1", res[0])
props = bss_obj.GetAll("fi.w1.wpa_supplicant1.Interface.BSS",
props = bss_obj.GetAll("fi.w1.wpa_supplicant1.BSS",
dbus_interface=dbus.PROPERTIES_IFACE)
print
print "GetAll(fi.w1.wpa_supplicant1.Interface.BSS, %s):" % (res[0])
print "GetAll(fi.w1.wpa_supplicant1.BSS, %s):" % (res[0])
print props
res = if_obj.Get("fi.w1.wpa_supplicant1.Interface", 'Networks',
dbus_interface=dbus.PROPERTIES_IFACE)
if len(res) > 0:
net_obj = bus.get_object("fi.w1.wpa_supplicant1", res[0])
props = net_obj.GetAll("fi.w1.wpa_supplicant1.Interface.Network",
props = net_obj.GetAll("fi.w1.wpa_supplicant1.Network",
dbus_interface=dbus.PROPERTIES_IFACE)
print
print "GetAll(fi.w1.wpa_supplicant1.Interface.Network, %s):" % (res[0])
print "GetAll(fi.w1.wpa_supplicant1.Network, %s):" % (res[0])
print props
if __name__ == "__main__":

View File

@ -12,8 +12,8 @@ WPAS_DBUS_OPATH = "/fi/w1/wpa_supplicant1"
WPAS_DBUS_INTERFACES_INTERFACE = "fi.w1.wpa_supplicant1.Interface"
WPAS_DBUS_INTERFACES_OPATH = "/fi/w1/wpa_supplicant1/Interfaces"
WPAS_DBUS_BSS_INTERFACE = "fi.w1.wpa_supplicant1.Interface.BSS"
WPAS_DBUS_NETWORK_INTERFACE = "fi.w1.wpa_supplicant1.Interface.Network"
WPAS_DBUS_BSS_INTERFACE = "fi.w1.wpa_supplicant1.BSS"
WPAS_DBUS_NETWORK_INTERFACE = "fi.w1.wpa_supplicant1.Network"
def byte_array_to_string(s):
import urllib

View File

@ -12,7 +12,7 @@ WPAS_DBUS_OPATH = "/fi/w1/wpa_supplicant1"
WPAS_DBUS_INTERFACES_INTERFACE = "fi.w1.wpa_supplicant1.Interface"
WPAS_DBUS_INTERFACES_OPATH = "/fi/w1/wpa_supplicant1/Interfaces"
WPAS_DBUS_BSS_INTERFACE = "fi.w1.wpa_supplicant1.Interface.BSS"
WPAS_DBUS_BSS_INTERFACE = "fi.w1.wpa_supplicant1.BSS"
def byte_array_to_string(s):
import urllib