telepathy-mission-control: McdProvisioningFactory: remove, unused
Simon McVittie
smcv at kemper.freedesktop.org
Thu May 10 08:15:15 PDT 2012
Module: telepathy-mission-control
Branch: master
Commit: e9495b13221eeecfafe9813c69e14f8734ac604c
URL: http://cgit.freedesktop.org/telepathy/telepathy-mission-control/commit/?id=e9495b13221eeecfafe9813c69e14f8734ac604c
Author: Simon McVittie <simon.mcvittie at collabora.co.uk>
Date: Tue May 8 14:39:51 2012 +0100
McdProvisioningFactory: remove, unused
---
src/Makefile.am | 2 -
src/mcd-connection.c | 1 -
src/mcd-provisioning-factory.c | 137 ----------------------------------------
src/mcd-provisioning-factory.h | 65 -------------------
4 files changed, 0 insertions(+), 205 deletions(-)
diff --git a/src/Makefile.am b/src/Makefile.am
index 2a4ce79..f3c9022 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -37,7 +37,6 @@ mc_headers = \
mcd-service.h \
mcd-transport.h \
mcd-provisioning.h \
- mcd-provisioning-factory.h \
mcd-storage.h
if ENABLE_LIBACCOUNTS_SSO
@@ -168,7 +167,6 @@ libmcd_convenience_la_SOURCES = \
mcd-proxy.c \
mcd-transport.c \
mcd-provisioning.c \
- mcd-provisioning-factory.c \
mcd-storage.c \
mcd-storage.h \
mcd-storage-priv.h \
diff --git a/src/mcd-connection.c b/src/mcd-connection.c
index ea2c41b..97ed737 100644
--- a/src/mcd-connection.c
+++ b/src/mcd-connection.c
@@ -61,7 +61,6 @@
#include "mcd-connection-priv.h"
#include "mcd-dispatcher-priv.h"
#include "mcd-channel.h"
-#include "mcd-provisioning-factory.h"
#include "mcd-misc.h"
#include "mcd-slacker.h"
#include "sp_timestamp.h"
diff --git a/src/mcd-provisioning-factory.c b/src/mcd-provisioning-factory.c
deleted file mode 100644
index 90772b4..0000000
--- a/src/mcd-provisioning-factory.c
+++ /dev/null
@@ -1,137 +0,0 @@
-/* vi: set et sw=4 ts=8 cino=t0,(0: */
-/* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 4; tab-width: 8 -*- */
-/*
-* This file is part of mission-control
-*
-* Copyright (C) 2007 Nokia Corporation.
-*
-* Contact: Naba Kumar <naba.kumar at nokia.com>
-*
-* This library is free software; you can redistribute it and/or
-* modify it under the terms of the GNU Lesser General Public License
-* version 2.1 as published by the Free Software Foundation.
-*
-* This library 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
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this library; if not, write to the Free Software
-* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA
-*
-*/
-
-#include "config.h"
-
-#include "mcd-provisioning-factory.h"
-
-#define MCD_PROVISIONING_FACTORY_GET_PRIV(master) \
- (G_TYPE_INSTANCE_GET_PRIVATE ((master), \
- MCD_TYPE_PROVISIONING_FACTORY, \
- McdProvisioningFactoryPriv))
-
-G_DEFINE_TYPE (McdProvisioningFactory, mcd_provisioning_factory, G_TYPE_OBJECT);
-
-
-struct _McdProvisioningFactoryPriv
-{
- GHashTable *provs;
-};
-
-static void
-mcd_provisioning_factory_init (McdProvisioningFactory *object)
-{
- McdProvisioningFactoryPriv *priv = MCD_PROVISIONING_FACTORY_GET_PRIV (object);
- priv->provs = g_hash_table_new_full (g_str_hash, g_str_equal,
- (GDestroyNotify) g_free,
- (GDestroyNotify) g_object_unref);
-}
-
-static void
-mcd_provisioning_factory_dispose (GObject *object)
-{
- McdProvisioningFactoryPriv *priv = MCD_PROVISIONING_FACTORY_GET_PRIV (object);
- if (priv->provs)
- {
- g_hash_table_unref (priv->provs);
- priv->provs = NULL;
- }
- G_OBJECT_CLASS (mcd_provisioning_factory_parent_class)->dispose (object);
-}
-
-static void
-mcd_provisioning_factory_class_init (McdProvisioningFactoryClass *klass)
-{
- GObjectClass* object_class = G_OBJECT_CLASS (klass);
- g_type_class_add_private (object_class, sizeof (McdProvisioningFactoryPriv));
-
- object_class->dispose = mcd_provisioning_factory_dispose;
-}
-
-/**
- * mcd_provisioning_factory_lookup:
- * @prov_factory: the #McdProvisioningFactory.
- * @service: name of the service for which provisioning will be retrieved.
- *
- * Gets a #McdProvisioning object for @service.
- *
- * Returns: a #McdProvisioning, or %NULL if none found. The reference count
- * will not be incremented.
- */
-McdProvisioning*
-mcd_provisioning_factory_lookup (McdProvisioningFactory* prov_factory,
- const gchar *service)
-{
- McdProvisioningFactoryPriv *priv;
-
- g_return_val_if_fail (service != NULL, NULL);
- g_return_val_if_fail (MCD_IS_PROVISIONING_FACTORY (prov_factory), NULL);
-
- priv = MCD_PROVISIONING_FACTORY_GET_PRIV (prov_factory);
- return g_hash_table_lookup (priv->provs, service);
-}
-
-/**
- * mcd_provisioning_factory_add:
- * @prov_factory: the #McdProvisioningFactory.
- * @service: name of the service for which provisioning will be provided.
- * @provisioning: the #McdProvisioning object to add.
- *
- * Add a new provisioning object to the factory. Note that the factory will
- * take ownership of the @provisioning object.
- */
-void
-mcd_provisioning_factory_add (McdProvisioningFactory* prov_factory,
- const gchar *service,
- McdProvisioning *provisioning)
-{
- McdProvisioningFactoryPriv *priv;
-
- g_return_if_fail (service != NULL);
- g_return_if_fail (MCD_IS_PROVISIONING_FACTORY (prov_factory));
- g_return_if_fail (MCD_IS_PROVISIONING (provisioning));
-
- priv = MCD_PROVISIONING_FACTORY_GET_PRIV (prov_factory);
- g_hash_table_insert (priv->provs, g_strdup (service), provisioning);
-}
-
-/**
- * mcd_provisioning_factory_get:
- *
- * Get the #McdProvisioningFactory. One doesn't have to hold a reference to the
- * returned object: just call this function whenever needed.
- *
- * Returns: a #McdProvisioningFactory.
- */
-McdProvisioningFactory*
-mcd_provisioning_factory_get (void)
-{
- static McdProvisioningFactory *factory = NULL;
- if (!factory)
- {
- factory = g_object_new (MCD_TYPE_PROVISIONING_FACTORY, NULL);
- }
- return factory;
-}
diff --git a/src/mcd-provisioning-factory.h b/src/mcd-provisioning-factory.h
deleted file mode 100644
index f87d793..0000000
--- a/src/mcd-provisioning-factory.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/* vi: set et sw=4 ts=8 cino=t0,(0: */
-/* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 4; tab-width: 8 -*- */
-/*
- * This file is part of mission-control
- *
- * Copyright (C) 2007 Nokia Corporation.
- *
- * Contact: Naba Kumar <naba.kumar at nokia.com>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public License
- * version 2.1 as published by the Free Software Foundation.
- *
- * This library 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
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA
- *
- */
-
-#ifndef _MCD_PROVISIONING_FACTORY_H_
-#define _MCD_PROVISIONING_FACTORY_H_
-
-#include <glib-object.h>
-#include "mcd-provisioning.h"
-
-G_BEGIN_DECLS
-
-#define MCD_TYPE_PROVISIONING_FACTORY (mcd_provisioning_factory_get_type ())
-#define MCD_PROVISIONING_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MCD_TYPE_PROVISIONING_FACTORY, McdProvisioningFactory))
-#define MCD_PROVISIONING_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), MCD_TYPE_PROVISIONING_FACTORY, McdProvisioningFactoryClass))
-#define MCD_IS_PROVISIONING_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MCD_TYPE_PROVISIONING_FACTORY))
-#define MCD_IS_PROVISIONING_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), MCD_TYPE_PROVISIONING_FACTORY))
-#define MCD_PROVISIONING_FACTORY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), MCD_TYPE_PROVISIONING_FACTORY, McdProvisioningFactoryClass))
-
-typedef struct _McdProvisioningFactoryClass McdProvisioningFactoryClass;
-typedef struct _McdProvisioningFactoryPriv McdProvisioningFactoryPriv;
-typedef struct _McdProvisioningFactory McdProvisioningFactory;
-
-struct _McdProvisioningFactoryClass
-{
- GObjectClass parent_class;
-};
-
-struct _McdProvisioningFactory
-{
- GObject parent_instance;
-};
-
-GType mcd_provisioning_factory_get_type (void) G_GNUC_CONST;
-McdProvisioning* mcd_provisioning_factory_lookup (McdProvisioningFactory* prov_factory,
- const gchar *service);
-void mcd_provisioning_factory_add (McdProvisioningFactory* prov_factory,
- const gchar *service,
- McdProvisioning *provisioning);
-McdProvisioningFactory* mcd_provisioning_factory_get (void);
-
-G_END_DECLS
-
-#endif /* _MCD_PROVISIONING_FACTORY_H_ */
More information about the telepathy-commits
mailing list