summaryrefslogtreecommitdiff
path: root/src/vpn-manager/nm-vpn-manager.h
diff options
context:
space:
mode:
authorDan Williams <dcbw@redhat.com>2008-03-26 13:43:01 +0000
committerDan Williams <dcbw@redhat.com>2008-03-26 13:43:01 +0000
commitec89663e7da344f54e11dbd5848c2828fa258b92 (patch)
treebc34dd46bf2e93a142a8a414e2fd9cc6f324278c /src/vpn-manager/nm-vpn-manager.h
parent7d694073be91c000ff02f55704f687390213d83f (diff)
downloadNetworkManager-ec89663e7da344f54e11dbd5848c2828fa258b92.tar.gz
2008-03-26 Dan Williams <dcbw@redhat.com>
Rework VPN connection handling for a more consistent D-Bus API. The VPNManager object has been removed, and active VPN connections are now the same as any other active connection. The Manager object's ActivateConnection and DeactivateConnection methods are used to start and stop a VPN connection, and the VPNConnection objects are subclasses of the ActiveConnection objects. When activating a VPN connection, pass the path of the active connection to which the VPN connection is tied in the 'specific_object' argument. Consequently, the libnm-glib API has been reworked to match this arrangement, with the VPNManager object removed, and the NMVPNConnection objects now being subclasses of NMActiveConnection. git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3504 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Diffstat (limited to 'src/vpn-manager/nm-vpn-manager.h')
-rw-r--r--src/vpn-manager/nm-vpn-manager.h24
1 files changed, 18 insertions, 6 deletions
diff --git a/src/vpn-manager/nm-vpn-manager.h b/src/vpn-manager/nm-vpn-manager.h
index a5e506c20a..3d064b2dd6 100644
--- a/src/vpn-manager/nm-vpn-manager.h
+++ b/src/vpn-manager/nm-vpn-manager.h
@@ -5,8 +5,8 @@
#include <glib/gtypes.h>
#include <glib-object.h>
-#include "nm-manager.h"
#include "nm-vpn-connection.h"
+#include "nm-activation-request.h"
#define NM_TYPE_VPN_MANAGER (nm_vpn_manager_get_type ())
#define NM_VPN_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), NM_TYPE_VPN_MANAGER, NMVPNManager))
@@ -21,17 +21,29 @@ typedef struct {
typedef struct {
GObjectClass parent;
+
+ /* Signals */
+ void (*connection_deactivated) (NMVPNManager *manager,
+ NMVPNConnection *connection,
+ NMVPNConnectionState state,
+ NMVPNConnectionStateReason reason);
} NMVPNManagerClass;
GType nm_vpn_manager_get_type (void);
-NMVPNManager *nm_vpn_manager_new (NMManager *nm_manager);
+NMVPNManager *nm_vpn_manager_get (void);
-NMVPNConnection *nm_vpn_manager_connect (NMVPNManager *manager,
- NMConnection *connection,
- NMDevice *device);
+const char *nm_vpn_manager_activate_connection (NMVPNManager *manager,
+ NMConnection *connection,
+ NMActRequest *act_request,
+ NMDevice *device,
+ GError **error);
-GSList *nm_vpn_manager_get_connections (NMVPNManager *manager);
+gboolean nm_vpn_manager_deactivate_connection (NMVPNManager *manager,
+ const char *path);
+void nm_vpn_manager_add_active_connections (NMVPNManager *manager,
+ NMConnection *filter,
+ GPtrArray *list);
#endif /* NM_VPN_VPN_MANAGER_H */