aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy/empathy-log-manager.h
diff options
context:
space:
mode:
authorJonny Lamb <jonny.lamb@collabora.co.uk>2009-03-06 19:51:17 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2009-03-06 19:51:17 +0800
commit51b836484f5eef122ffb1b364caec38cb3973fde (patch)
treef04b5aee325ed2c6ec83303d792252bffad1323c /libempathy/empathy-log-manager.h
parent4ee8934f3b36bc72b0c1ba257c6082b56c6d1702 (diff)
downloadgsoc2013-empathy-51b836484f5eef122ffb1b364caec38cb3973fde.tar
gsoc2013-empathy-51b836484f5eef122ffb1b364caec38cb3973fde.tar.gz
gsoc2013-empathy-51b836484f5eef122ffb1b364caec38cb3973fde.tar.bz2
gsoc2013-empathy-51b836484f5eef122ffb1b364caec38cb3973fde.tar.lz
gsoc2013-empathy-51b836484f5eef122ffb1b364caec38cb3973fde.tar.xz
gsoc2013-empathy-51b836484f5eef122ffb1b364caec38cb3973fde.tar.zst
gsoc2013-empathy-51b836484f5eef122ffb1b364caec38cb3973fde.zip
Converted log code to Collabora coding style. (Jonny Lamb)
Signed-off-by: Jonny Lamb <jonny.lamb@collabora.co.uk> svn path=/trunk/; revision=2578
Diffstat (limited to 'libempathy/empathy-log-manager.h')
-rw-r--r--libempathy/empathy-log-manager.h121
1 files changed, 69 insertions, 52 deletions
diff --git a/libempathy/empathy-log-manager.h b/libempathy/empathy-log-manager.h
index bad014000..b8f86efd7 100644
--- a/libempathy/empathy-log-manager.h
+++ b/libempathy/empathy-log-manager.h
@@ -32,67 +32,84 @@
G_BEGIN_DECLS
-#define EMPATHY_TYPE_LOG_MANAGER (empathy_log_manager_get_type ())
-#define EMPATHY_LOG_MANAGER(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), EMPATHY_TYPE_LOG_MANAGER, EmpathyLogManager))
-#define EMPATHY_LOG_MANAGER_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), EMPATHY_TYPE_LOG_MANAGER, EmpathyLogManagerClass))
-#define EMPATHY_IS_LOG_MANAGER(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), EMPATHY_TYPE_LOG_MANAGER))
-#define EMPATHY_IS_LOG_MANAGER_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), EMPATHY_TYPE_LOG_MANAGER))
-#define EMPATHY_LOG_MANAGER_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), EMPATHY_TYPE_LOG_MANAGER, EmpathyLogManagerClass))
+#define EMPATHY_TYPE_LOG_MANAGER (empathy_log_manager_get_type ())
+#define EMPATHY_LOG_MANAGER(o) \
+ (G_TYPE_CHECK_INSTANCE_CAST ((o), EMPATHY_TYPE_LOG_MANAGER, \
+ EmpathyLogManager))
+#define EMPATHY_LOG_MANAGER_CLASS(k) \
+ (G_TYPE_CHECK_CLASS_CAST ((k), EMPATHY_TYPE_LOG_MANAGER, \
+ EmpathyLogManagerClass))
+#define EMPATHY_IS_LOG_MANAGER(o) \
+ (G_TYPE_CHECK_INSTANCE_TYPE ((o), EMPATHY_TYPE_LOG_MANAGER))
+#define EMPATHY_IS_LOG_MANAGER_CLASS(k) \
+ (G_TYPE_CHECK_CLASS_TYPE ((k), EMPATHY_TYPE_LOG_MANAGER))
+#define EMPATHY_LOG_MANAGER_GET_CLASS(o) \
+ (G_TYPE_INSTANCE_GET_CLASS ((o), EMPATHY_TYPE_LOG_MANAGER, \
+ EmpathyLogManagerClass))
-typedef struct _EmpathyLogManager EmpathyLogManager;
+typedef struct _EmpathyLogManager EmpathyLogManager;
typedef struct _EmpathyLogManagerClass EmpathyLogManagerClass;
-typedef struct _EmpathyLogSearchHit EmpathyLogSearchHit;
+typedef struct _EmpathyLogSearchHit EmpathyLogSearchHit;
+typedef struct _EmpathyLogSource EmpathyLogSource;
-struct _EmpathyLogManager {
- GObject parent;
- gpointer priv;
+struct _EmpathyLogManager
+{
+ GObject parent;
+ gpointer priv;
};
-struct _EmpathyLogManagerClass {
- GObjectClass parent_class;
+struct _EmpathyLogManagerClass
+{
+ GObjectClass parent_class;
};
-struct _EmpathyLogSearchHit {
- McAccount *account;
- gchar *chat_id;
- gboolean is_chatroom;
- gchar *filename;
- gchar *date;
+struct _EmpathyLogSearchHit
+{
+ McAccount *account;
+ gchar *chat_id;
+ gboolean is_chatroom;
+ gchar *filename;
+ gchar *date;
};
-GType empathy_log_manager_get_type (void) G_GNUC_CONST;
-EmpathyLogManager *empathy_log_manager_dup_singleton (void);
-void empathy_log_manager_add_message (EmpathyLogManager *manager,
- const gchar *chat_id,
- gboolean chatroom,
- EmpathyMessage *message);
-gboolean empathy_log_manager_exists (EmpathyLogManager *manager,
- McAccount *account,
- const gchar *chat_id,
- gboolean chatroom);
-GList * empathy_log_manager_get_dates (EmpathyLogManager *manager,
- McAccount *account,
- const gchar *chat_id,
- gboolean chatroom);
-GList * empathy_log_manager_get_messages_for_file (EmpathyLogManager *manager,
- const gchar *filename);
-GList * empathy_log_manager_get_messages_for_date (EmpathyLogManager *manager,
- McAccount *account,
- const gchar *chat_id,
- gboolean chatroom,
- const gchar *date);
-GList * empathy_log_manager_get_last_messages (EmpathyLogManager *manager,
- McAccount *account,
- const gchar *chat_id,
- gboolean chatroom);
-GList * empathy_log_manager_get_messages_for_file (EmpathyLogManager *manager,
- const gchar *filename);
-GList * empathy_log_manager_get_chats (EmpathyLogManager *manager,
- McAccount *account);
-GList * empathy_log_manager_search_new (EmpathyLogManager *manager,
- const gchar *text);
-void empathy_log_manager_search_free (GList *hits);
-gchar * empathy_log_manager_get_date_readable (const gchar *date);
+struct _EmpathyLogSource
+{
+ gboolean (*exists) (EmpathyLogManager *manager, McAccount *account,
+ const gchar *chat_id, gboolean chatroom);
+ void (*add_message) (EmpathyLogManager *manager, const gchar *chat_id,
+ gboolean chatroom, EmpathyMessage *message);
+ GList * (*get_dates) (EmpathyLogManager *manager, McAccount *account,
+ const gchar *chat_id, gboolean chatroom);
+ GList * (*get_messages_for_date) (EmpathyLogManager *manager,
+ McAccount *account, const gchar *chat_id, gboolean chatroom,
+ const gchar *date);
+ GList * (*get_last_messages) (EmpathyLogManager *manager, McAccount *account,
+ const gchar *chat_id, gboolean chatroom);
+ GList * (*get_chats) (EmpathyLogManager *manager,
+ McAccount *account);
+ GList * (*search_new) (EmpathyLogManager *manager, const gchar *text);
+};
+
+GType empathy_log_manager_get_type (void) G_GNUC_CONST;
+EmpathyLogManager *empathy_log_manager_dup_singleton (void);
+void empathy_log_manager_add_message (EmpathyLogManager *manager,
+ const gchar *chat_id, gboolean chatroom, EmpathyMessage *message);
+gboolean empathy_log_manager_exists (EmpathyLogManager *manager,
+ McAccount *account, const gchar *chat_id, gboolean chatroom);
+GList *empathy_log_manager_get_dates (EmpathyLogManager *manager,
+ McAccount *account, const gchar *chat_id, gboolean chatroom);
+GList *empathy_log_manager_get_messages_for_date (EmpathyLogManager *manager,
+ McAccount *account, const gchar *chat_id, gboolean chatroom,
+ const gchar *date);
+GList *empathy_log_manager_get_last_messages (EmpathyLogManager *manager,
+ McAccount *account, const gchar *chat_id, gboolean chatroom);
+GList *empathy_log_manager_get_chats (EmpathyLogManager *manager,
+ McAccount *account);
+GList *empathy_log_manager_search_new (EmpathyLogManager *manager,
+ const gchar *text);
+void empathy_log_manager_search_free (GList *hits);
+gchar *empathy_log_manager_get_date_readable (const gchar *date);
+void empathy_log_manager_search_hit_free (EmpathyLogSearchHit *hit);
G_END_DECLS