mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-16 15:50:44 +01:00
* src/NetworkManager.c: - Set up all the shiny new managers. * src/NetworkManagerPolicy.c: - Add the beginnings of new NMPolicy code. Instead of requireing all classes to call into policy code, make the policy code kind of like a supervisor that monitors what's going on and drives the whole NM. * src/nm-hal-manager.c: * src/nm-hal-manager.h: - Collect all libhal code scattered around NM to this one class. - Listen libhal and NMManager events and add/remove devices to NMManager. * src/nm-manager.c: * src/nm-manager.h: - Implment a replacement for NMData. NMData is now officially deprecated. git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2291 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
77 lines
2.6 KiB
C
77 lines
2.6 KiB
C
/* NetworkManager -- Network link manager
|
|
*
|
|
* Dan Williams <dcbw@redhat.com>
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as published by
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
* (at your option) any later version.
|
|
*
|
|
* This program 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 General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program; if not, write to the Free Software
|
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
*
|
|
* (C) Copyright 2004 Red Hat, Inc.
|
|
*/
|
|
|
|
#ifndef NETWORK_MANAGER_DBUS_H
|
|
#define NETWORK_MANAGER_DBUS_H
|
|
|
|
#include <glib.h>
|
|
#include <dbus/dbus.h>
|
|
#include <dbus/dbus-glib.h>
|
|
#include "NetworkManager.h"
|
|
#include "NetworkManagerMain.h"
|
|
#include "nm-device.h"
|
|
#include "nm-device-802-11-wireless.h"
|
|
#include "NetworkManagerAPList.h"
|
|
|
|
|
|
typedef enum
|
|
{
|
|
DEVICE_STATUS_INVALID,
|
|
DEVICE_NOW_ACTIVE,
|
|
DEVICE_NO_LONGER_ACTIVE,
|
|
DEVICE_ACTIVATING,
|
|
DEVICE_ACTIVATION_FAILED,
|
|
DEVICE_ACTIVATION_CANCELED,
|
|
DEVICE_ADDED,
|
|
DEVICE_REMOVED,
|
|
DEVICE_CARRIER_ON,
|
|
DEVICE_CARRIER_OFF
|
|
} DeviceStatus;
|
|
|
|
|
|
static inline gboolean message_is_error (DBusMessage *msg)
|
|
{
|
|
g_return_val_if_fail (msg != NULL, FALSE);
|
|
|
|
return (dbus_message_get_type (msg) == DBUS_MESSAGE_TYPE_ERROR);
|
|
}
|
|
|
|
char * nm_dbus_get_object_path_for_device (NMDevice *dev);
|
|
char * nm_dbus_get_object_path_for_network (NMDevice *dev, NMAccessPoint *ap);
|
|
|
|
void nm_dbus_schedule_device_status_change_signal (NMData *data, NMDevice *dev, NMAccessPoint *ap, DeviceStatus status);
|
|
|
|
void nm_dbus_signal_state_change (DBusConnection *connection, NMState state);
|
|
|
|
void nm_dbus_signal_wireless_network_change (NMDevice80211Wireless *dev, NMAccessPoint *ap, NMNetworkStatus status, gint strength);
|
|
void nm_dbus_signal_device_strength_change (NMDevice80211Wireless *dev, gint strength);
|
|
|
|
NMDevice * nm_dbus_get_device_from_escaped_object_path (NMData *data, const char *path);
|
|
|
|
DBusMessage * nm_dbus_create_error_message (DBusMessage *message, const char *exception_namespace, const char *exception, const char *format, ...);
|
|
|
|
DBusMessage * nm_dbus_new_invalid_args_error (DBusMessage *replyto, const char *namespace);
|
|
|
|
gboolean nm_dbus_nmi_signal_handler (DBusConnection *connection,
|
|
DBusMessage *message,
|
|
gpointer user_data);
|
|
|
|
#endif
|