diff options
author | Dan Winship <danw@src.gnome.org> | 2000-05-19 08:47:36 +0800 |
---|---|---|
committer | Dan Winship <danw@src.gnome.org> | 2000-05-19 08:47:36 +0800 |
commit | a909e956daf6879cd5a4bcc1ed8f5d09ea173563 (patch) | |
tree | 8f8d55f79112de99d9224fc2e4999872b7bb7890 /camel/providers/nntp/camel-nntp-folder.c | |
parent | e46d64caa7b900342b1f1823aad7938b0f90cbbe (diff) | |
download | gsoc2013-evolution-a909e956daf6879cd5a4bcc1ed8f5d09ea173563.tar gsoc2013-evolution-a909e956daf6879cd5a4bcc1ed8f5d09ea173563.tar.gz gsoc2013-evolution-a909e956daf6879cd5a4bcc1ed8f5d09ea173563.tar.bz2 gsoc2013-evolution-a909e956daf6879cd5a4bcc1ed8f5d09ea173563.tar.lz gsoc2013-evolution-a909e956daf6879cd5a4bcc1ed8f5d09ea173563.tar.xz gsoc2013-evolution-a909e956daf6879cd5a4bcc1ed8f5d09ea173563.tar.zst gsoc2013-evolution-a909e956daf6879cd5a4bcc1ed8f5d09ea173563.zip |
remove message_number_capability and require uid capatibility.
* camel-folder.c: remove message_number_capability and require uid
capatibility.
(camel_folder_list_subfolders, camel_folder_get_uid_list,
camel_folder_get_subfolder_info, camel_folder_get_message_info):
removed
(camel_folder_get_subfolder_names,
camel_folder_free_subfolder_names): new subfolder interfaces.
(camel_folder_get_uids, camel_folder_free_uids): new uid
interfaces
(camel_folder_get_summary, camel_folder_free_summary): new summary
interfaces
* providers/mbox/camel-mbox-folder.c,
* providers/nntp/camel-nntp-folder.c:
* providers/vee/camel-vee-folder.c: Update for changes
* providers/pop3/camel-pop3-folder.c: Implement get_uids, update
for other changes.
svn path=/trunk/; revision=3126
Diffstat (limited to 'camel/providers/nntp/camel-nntp-folder.c')
-rw-r--r-- | camel/providers/nntp/camel-nntp-folder.c | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/camel/providers/nntp/camel-nntp-folder.c b/camel/providers/nntp/camel-nntp-folder.c index 067849712c..8bc623add7 100644 --- a/camel/providers/nntp/camel-nntp-folder.c +++ b/camel/providers/nntp/camel-nntp-folder.c @@ -71,7 +71,7 @@ static GList *_list_subfolders (CamelFolder *folder, CamelException *ex); static CamelMimeMessage *_get_message_by_number (CamelFolder *folder, gint number, CamelException *ex); static gint _get_message_count (CamelFolder *folder, CamelException *ex); static void _append_message (CamelFolder *folder, CamelMimeMessage *message, CamelException *ex); -static GList *_get_uid_list (CamelFolder *folder, CamelException *ex); +static GPtrArray *_get_uid_array (CamelFolder *folder, CamelException *ex); static CamelMimeMessage *_get_message_by_uid (CamelFolder *folder, const gchar *uid, CamelException *ex); #if 0 static void _expunge (CamelFolder *folder, CamelException *ex); @@ -101,7 +101,7 @@ camel_nntp_folder_class_init (CamelNNTPFolderClass *camel_nntp_folder_class) camel_folder_class->delete_messages = _delete_messages; camel_folder_class->list_subfolders = _list_subfolders; camel_folder_class->get_message_count = _get_message_count; - camel_folder_class->get_uid_list = _get_uid_list; + camel_folder_class->get_uid_array = _get_uid_array; camel_folder_class->get_message_by_uid = _get_message_by_uid; #if 0 camel_folder_class->append_message = _append_message; @@ -487,23 +487,25 @@ _append_message (CamelFolder *folder, CamelMimeMessage *message, CamelException -static GList * -_get_uid_list (CamelFolder *folder, CamelException *ex) +static GPtrArray * +_get_uid_array (CamelFolder *folder, CamelException *ex) { CamelNNTPFolder *nntp_folder = CAMEL_NNTP_FOLDER (folder); - GPtrArray *message_info_array; + GPtrArray *message_info_array, *out; CamelMessageInfo *message_info; - GList *uid_list = NULL; int i; message_info_array = nntp_folder->summary->messages; + + out = g_ptr_array_new (); + g_ptr_array_set_size (out, message_info_array->len); for (i=0; i<message_info_array->len; i++) { message_info = (CamelMessageInfo *)(message_info_array->pdata) + i; - uid_list = g_list_prepend (uid_list, g_strdup (message_info->uid)); + out->pdata[i] = g_strdup (message_info->uid); } - return uid_list; + return out; } static CamelMimeMessage * |