[evolution-data-server/imapx-extensible: 8/10] CamelIMAPXServer: exposed command run function in public API



commit 5540937e505453a7ce5dbaa1bdb02f8f04eb0980
Author: Christian Hilberg <chilberg src gnome org>
Date:   Fri Jun 22 17:21:36 2012 +0200

    CamelIMAPXServer: exposed command run function in public API
    
    * in order to actually make use of the untagged response
      handler extensions, CamelIMAPXStore derivatives will
      need to send custom commands to the IMAP server
    * the newly exposed API function provides a means for this

 camel/camel-imapx-server.c |   14 ++++++++++++++
 camel/camel-imapx-server.h |    6 +++++-
 2 files changed, 19 insertions(+), 1 deletions(-)
---
diff --git a/camel/camel-imapx-server.c b/camel/camel-imapx-server.c
index e60d0e9..44d907d 100644
--- a/camel/camel-imapx-server.c
+++ b/camel/camel-imapx-server.c
@@ -7010,3 +7010,17 @@ camel_imapx_server_register_untagged_handler (CamelIMAPXServer *is,
 	                                        desc);
 	return previous;
 }
+
+gboolean
+camel_imapx_server_command_run (CamelIMAPXServer *is,
+                                CamelIMAPXCommand *ic,
+                                GCancellable *cancellable,
+                                GError **error)
+{
+	g_assert (CAMEL_IS_IMAPX_SERVER (is));
+	g_assert (CAMEL_IS_IMAPX_COMMAND (ic));
+	/* cancellable may be NULL */
+	g_return_val_if_fail (error == NULL || *error == NULL, FALSE);
+
+	return imapx_command_run (is, ic, cancellable, error);
+}
diff --git a/camel/camel-imapx-server.h b/camel/camel-imapx-server.h
index 809e9b0..f36a723 100644
--- a/camel/camel-imapx-server.h
+++ b/camel/camel-imapx-server.h
@@ -263,13 +263,17 @@ struct _IMAPXJobQueueInfo *
 		camel_imapx_server_get_job_queue_info
 						(CamelIMAPXServer *is);
 
-
 const CamelIMAPXUntaggedRespHandlerDesc*
 		camel_imapx_server_register_untagged_handler
 						(CamelIMAPXServer *is,
 						 const gchar *untagged_response,
 						 const CamelIMAPXUntaggedRespHandlerDesc *desc);
 
+gboolean	camel_imapx_server_command_run	(CamelIMAPXServer *is,
+						 CamelIMAPXCommand *ic,
+						 GCancellable *cancellable,
+						 GError **error);
+
 G_END_DECLS
 
 #endif /* CAMEL_IMAPX_SERVER_H */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]