aboutsummaryrefslogtreecommitdiffstats
path: root/camel/camel-folder.c
diff options
context:
space:
mode:
authorbertrand <Bertrand.Guiheneuf@aful.org>1999-08-07 01:28:26 +0800
committerBertrand Guiheneuf <bertrand@src.gnome.org>1999-08-07 01:28:26 +0800
commitdb89b1a62fb0fa1ed57a9cdd275c0a977630a56a (patch)
treea6e43ba18be9f88e70b9cc8dd9441085d322049e /camel/camel-folder.c
parent85067acb32a4992410e337352f8c54b61b78709b (diff)
downloadgsoc2013-evolution-db89b1a62fb0fa1ed57a9cdd275c0a977630a56a.tar
gsoc2013-evolution-db89b1a62fb0fa1ed57a9cdd275c0a977630a56a.tar.gz
gsoc2013-evolution-db89b1a62fb0fa1ed57a9cdd275c0a977630a56a.tar.bz2
gsoc2013-evolution-db89b1a62fb0fa1ed57a9cdd275c0a977630a56a.tar.lz
gsoc2013-evolution-db89b1a62fb0fa1ed57a9cdd275c0a977630a56a.tar.xz
gsoc2013-evolution-db89b1a62fb0fa1ed57a9cdd275c0a977630a56a.tar.zst
gsoc2013-evolution-db89b1a62fb0fa1ed57a9cdd275c0a977630a56a.zip
updated some autogen doc stuff. Still don't understand warnings :(
1999-08-06 bertrand <Bertrand.Guiheneuf@aful.org> * devel-docs/camel/: updated some autogen doc stuff. Still don't understand warnings :( * camel/camel-data-wrapper.c: * camel/providers/MH/camel-mh-store.c: * camel/url-util.c: * camel/gmime-content-field.c: * camel/camel-store.c: various inline doc corrections. * camel/camel-folder.c (get_message_count): new method. Returns the number of message in the folder. svn path=/trunk/; revision=1092
Diffstat (limited to 'camel/camel-folder.c')
-rw-r--r--camel/camel-folder.c42
1 files changed, 34 insertions, 8 deletions
diff --git a/camel/camel-folder.c b/camel/camel-folder.c
index bdd1a75a17..5fa22a5b72 100644
--- a/camel/camel-folder.c
+++ b/camel/camel-folder.c
@@ -50,6 +50,7 @@ static CamelFolderOpenMode _get_mode (CamelFolder *folder);
static GList *_list_subfolders (CamelFolder *folder);
static GList *_expunge (CamelFolder *folder);
static CamelMimeMessage *_get_message (CamelFolder *folder, gint number);
+static gint _get_message_count (CamelFolder *folder);
static void
camel_folder_class_init (CamelFolderClass *camel_folder_class)
@@ -76,6 +77,8 @@ camel_folder_class_init (CamelFolderClass *camel_folder_class)
camel_folder_class->list_subfolders = _list_subfolders;
camel_folder_class->expunge = _expunge;
camel_folder_class->get_message = _get_message;
+ camel_folder_class->get_message_count = _get_message_count;
+
/* virtual method overload */
}
@@ -383,19 +386,19 @@ _get_folder (CamelFolder *folder, const gchar *folder_name)
return new_folder;
}
-/**
- * camel_folder_get_folder: return the (sub)folder object that is specified.
- *
- * @folder : the folder
- * @folder_name: subfolder path.
- *
+
+
+/**
+ * camel_folder_get_folder: return the (sub)folder object that is specified
+ * @folder: the folder
+ * @folder_name: subfolder path
+ *
* This method returns a folder objects. This folder
* is necessarily a subfolder of the current folder.
* It is an error to ask a folder begining with the
* folder separator character.
*
- * Return value: Required folder. NULL if the subfolder object
- * could not be obtained
+ * Return value: Required folder. NULL if the subfolder object could not be obtained
**/
CamelFolder *
camel_folder_get_folder (CamelFolder *folder, gchar *folder_name)
@@ -758,3 +761,26 @@ camel_folder_get_message (CamelFolder *folder, gint number)
return CF_CLASS (folder)->get_message (folder, number);
}
+
+static gint
+_get_message_count (CamelFolder *folder)
+{
+ return -1;
+}
+
+
+
+/**
+ * camel_folder_get_message_count: get the number of messages in the folder
+ * @folder: A CamelFolder object
+ *
+ * Returns the number of messages in the folder.
+ *
+ * Return value: the number of messages or -1 if unknown.
+ **/
+gint
+camel_folder_get_message_count (CamelFolder *folder)
+{
+ return CF_CLASS (folder)->get_message_count (folder);
+}
+