aboutsummaryrefslogtreecommitdiffstats
path: root/camel/providers/imap/camel-imap-summary.h
Commit message (Collapse)AuthorAgeFilesLines
* This commit was manufactured by cvs2svn to create tagGNOME_SYSTEM_MONITOR_2_6_0nobody2003-12-091-79/+0
| | | | | | 'GNOME_SYSTEM_MONITOR_2_6_0'. svn path=/tags/GNOME_SYSTEM_MONITOR_2_6_0/; revision=23789
* Prototype.Peter Williams2002-07-261-0/+4
| | | | | | | | | | | | | | | | | | | | | | 2002-07-25 Peter Williams <peterw@ximian.com> * providers/imap/camel-imap-summary.h (camel_imap_summary_add_offline_uncached): Prototype. * providers/imap/camel-imap-summary.c (camel_imap_summary_add_offline_uncached): New function to add an uncached message to the summary while offline. * providers/imap/camel-imap-store.c (imap_connect_online): Only refresh the folders if the disco diary is empty (ie, we're not resyncing.) * providers/imap/camel-imap-folder.c (imap_transfer_offline): Emit an event for the source if deleting its originals. Also, if we can't load the message, still process it, using the new imap summary function. svn path=/trunk/; revision=17596
* Check for LOGIN xxxx as well if debug is on, so we dont print passwords toNot Zed2002-05-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-05-07 Not Zed <NotZed@Ximian.com> * camel-remote-store.c (remote_send_string): Check for LOGIN xxxx as well if debug is on, so we dont print passwords to evolution logs. * providers/imap/camel-imap-utils.c (imap_is_atom_char): This was really broken. 1. isprint() is locale dependent, and 2. it looked up an 8 bit value in a 7 bit table without truncating it. I've removed the isprint() stuff and just put it directly into the special table, which i've expanded to the right size too. * providers/imap/*: Applied patch from Preston Elder <prez@magick.tm> to make camel only use literals if it needs to for simple strings. Changed slightly to use imap_is_atom() and more consistent formatting. providers/imap/camel-imap-utils.c (imap_is_atom): Chagned from imap_needs_quoting(). ** Merged in camel-object2 branch. Simpler camelobject implementation + object args interface. * camel.c (camel_init): Call camel_object_get_type() to make sure camel_object_type is initialised. * camel-object.h (CAMEL_OBJECT_TYPE): Changed to return global camel_object_type pointer, not call camel_object_get_type. svn path=/trunk/; revision=16701
* More fixing of the license texts.Ettore Perazzoli2001-10-281-12/+11
| | | | svn path=/trunk/; revision=14217
* new method to get an application-initialized filter driver.Dan Winship2001-07-021-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * camel-session.c (camel_session_get_filter_driver): new method to get an application-initialized filter driver. * camel-filter-driver.c (camel_filter_driver_new): Remove the get_folder function and data args from here... (camel_filter_driver_set_folder_func): ...and add this function to set/change them. * providers/imap/camel-imap-folder.c (camel_imap_folder_new): If this folder is INBOX and we're filtering INBOX, set a flag on the folder for later. (imap_update_summary): Add another argument (GPtrArray *recents), and if it's non-NULL, add the uids of any \Recent new messages to it. (camel_imap_folder_changed): If doing filtering in this folder, create a recents array and pass it to imap_update_summary. Then get a filter driver and use it to filter the recent messages. * providers/imap/camel-imap-summary.h: * providers/imap/camel-imap-utils.c (imap_parse_flag_list): Add support for the \Recent flag. * providers/imap/camel-imap-provider.c (imap_conf_entries): enable the "filter" option. * camel-types.h: add CamelFilterDriver typedef here svn path=/trunk/; revision=10681
* Update the copyrights, replacing Helix Code with Ximian andEttore Perazzoli2001-06-231-3/+3
| | | | | | helixcode.com with ximian.com all over the place. svn path=/trunk/; revision=10440
* Create a CamelDiscoDiary. (imap_disconnect_offline): And free it.Dan Winship2001-05-301-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-store.c (imap_connect_online, imap_connect_offline): Create a CamelDiscoDiary. (imap_disconnect_offline): And free it. * providers/imap/camel-imap-folder.c (camel_imap_folder_selected): If RESYNCING, don't do any sort of checking that the remote folder matches the summary, beyond making sure that the UIDVALIDITY is correct. (imap_rescan): Add a missing camel_folder_summary_info_free when removing a UID from the summary. (imap_expunge_uids_offline): Implement. Fairly simple. (imap_expunge_uids_resyncing): Implement. If the store supports UIDPLUS, we can just use imap_expunge_uids_online. If not, we need to temporarily undelete any messages marked deleted on the server that aren't supposed to get expunged. (imap_append_offline): Implement, using cache and summary operations, and triggering the folder_changed event by hand. (imap_append_resyncing): Implement. Redo imap_append_online a bit in the process to make them able to share more code. (imap_copy_offline): Implement. (imap_copy_online): Move parts of this out into a helper. (imap_copy_resyncing): Implement. In most cases this is just like imap_copy_online, but if you are copying a message that was itself copied or appended into the folder, and the server doesn't do UIDPLUS, it will be necessary to replace at least part of the copy operation with one or more appends. * providers/imap/camel-imap-command.c (imap_read_response): Don't record the current folder in the response when in RESYNCING mode. (This means that EXISTS and EXPUNGE responses won't be processed, which is needed because the summary may not match the folder at this point.) (imap_read_response): On error, call camel_imap_response_free_without_processing, not camel_imap_response_free. * providers/imap/camel-imap-utils.c (imap_uid_array_to_set): Make this work better when operating on UIDs that aren't in the summary. * providers/imap/camel-imap-summary.c (camel_imap_summary_add_offline): New routine used by imap_append_offline and imap_copy_offline to create new summary entries. svn path=/trunk/; revision=10041
* Function to check if the store is online and set an exception if not.Dan Winship2001-03-211-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-store.c (camel_imap_store_check_online): Function to check if the store is online and set an exception if not. Currently controlled by an environment variable, but eventually there will be both a global (session-level) setting and a per-store setting. (construct): Set up storage_path and base_url here rather than at connect-time. (imap_auth_loop): Split out from imap_connect. (imap_setup_online): Split out from imap_connect. Do the post-authentication connection setup, and cache the results to disk. (imap_setup_offline): Set up a CamelImapStore with information saved from a previous imap_setup_online. (imap_connect): If online, do connect_to_server(), imap_auth_loop(), and imap_setup_online(). Otherwise, do imap_setup_offline(). (get_folder, get_folder_info): Add offline support. (create_folder, subscribe_folder, unsubscribe_folder): Disable these when offline (for now). * providers/imap/camel-imap-folder.c (camel_imap_folder_new): Remove the sync'ing-with-server stuff... it's done by camel_imap_folder_selected now, which only gets called if the store is online. (camel_imap_folder_selected): add the code removed from camel_imap_folder_new. Besides simplifying the folder_new and summary_new code, this also means now that we'll DTRT if a folder's UIDVALIDITY changes while we're connected. Also, when that happens, clear the message cache explicitly. (imap_refresh_info, imap_sync): These are no-ops when offline. (imap_expunge, imap_append_message, imap_copy_message_to, imap_search_by_expression): These don't yet work offline. (imap_get_message, camel_imap_folder_fetch_data): Return an error when trying to fetch a non-cached body part when we're offline. * providers/imap/camel-imap-summary.c (camel_imap_summary_new): Rewrite to not check the validity here. (We'll do it from camel_imap_folder_selected instead.) * providers/imap/camel-imap-command.c (camel_imap_command): Call camel_imap_folder_selected even when the selection is all we're doing, to match the changes in camel-imap-folder.c. * providers/imap/camel-imap-message-cache.c (camel_imap_message_cache_clear): New function to clear out a message cache. svn path=/trunk/; revision=8851
* #define this as the set of all IMAP system flagsDan Winship2001-02-221-0/+6
| | | | | | | | | | | | | * providers/imap/camel-imap-summary.h (CAMEL_IMAP_SERVER_FLAGS): #define this as the set of all IMAP system flags * providers/imap/camel-imap-folder.c (sync_message): after syncing flags, set server_flags to (flags & CAMEL_IMAP_SERVER_FLAGS) rather than just "flags", since any other flags won't have been synced. Prevents the CAMEL_MESSAGE_ATTACHMENTS flag from getting lost. svn path=/trunk/; revision=8344
* New header to prevent recursive #include problemsDan Winship2001-01-111-1/+1
| | | | | | | | | | | | | | | | | * providers/imap/camel-imap-types.h: New header to prevent recursive #include problems * providers/imap/*.h: Replace some #includes with #include "camel-imap-types.h", remove typedefs that were moved to camel-imap-types.h * providers/imap/*.c: Add #includes to make up for #includes removed from .h files * providers/imap/Makefile.am (libcamelimapinclude_HEADERS): Add camel-imap-types.h svn path=/trunk/; revision=7367
* Add "guint32 server_flags" to CamelImapMessageInfo to keep track of theDan Winship2000-12-201-0/+1
| | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-summary.c: Add "guint32 server_flags" to CamelImapMessageInfo to keep track of the last known message flag state on the server. (message_info_save, message_info_load): Save/load the server_flags. * providers/imap/camel-imap-folder.c: Make this use CamelFolderChangeInfo and emit folder_changed notifications as it gets them rather than only on refresh_info. (imap_refresh_info): Notice flags that get cleared on the server as well as flags that get set. (imap_update_summary): Remove a comment that never actually applied to the committed code. svn path=/trunk/; revision=7086
* Simple subclass of CamelFolderSummary that also keeps a UIDVALIDITY valueDan Winship2000-10-131-0/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * providers/imap/camel-imap-summary.c: Simple subclass of CamelFolderSummary that also keeps a UIDVALIDITY value (and doesn't, for the moment, build content info). * providers/imap/camel-imap-folder.c: (various): Use a CamelImapSummary to store/fetch summary info. (camel_imap_folder_new): Take a path to a file to use for the summary. Set the folder's permanent_flags correctly according to the server response. Read in the summary (checking the UIDVALIDITY) and update it if it's out of date. (imap_refresh_info): Just fetch UIDs and flags. If the UIDs all match, update the flags as needed and be done with it. Otherwise, delete messages that have been expunged from the server and fetch full summary info for any new messages. (imap_sync): Save the summary to disk. (imap_update_summary): Renamed from imap_get_summary_internal. Can now be told to get summary for only a subset of messages. Use camel-mime-utils functions rather than rolling our own header parsing. (imap_get_message_info_internal): Merged into imap_update_summary. (imap_set_message_flags): Don't marked the message FOLDER_FLAGGED if we're not actually changing the value of any of the flags. (camel_imap_folder_changed): Deal with EXISTS rather than RECENT. * providers/imap/camel-imap-store.c (imap_connect): Call camel_session_get_storage_path and save the value. (get_folder): Create a local directory to store summary information and pass a summary file name to camel_imap_folder_new. Don't call camel_folder_refresh_info from here any more since camel_imap_folder_new does it again. * providers/imap/camel-imap-command.c (camel_imap_command): Add a special case to this to make it possible to get the repsonses from a SELECT and still have store->current_folder be updated correctly. (imap_read_response): parse EXISTS rather than RECENT * camel-session.c (camel_session_get_storage_path): Use e_mkdir_hier. * camel-folder-summary.c (camel_folder_summary_remove_index): New function. * camel-mime-utils.c (header_raw_append_parse): fix this. (camel-mime-parser.c doesn't use this code because of the MEMPOOL optimization, so nothing was ever actually calling it before.) svn path=/trunk/; revision=5891
* Added code to expunge if called for (still need to finish coding this).Jeffrey Stedfast2000-06-171-82/+0
| | | | | | | | | | | | | | | | | | 2000-06-16 Jeffrey Stedfast <fejj@helixcode.com> * providers/imap/camel-imap-folder.c (imap_sync): Added code to expunge if called for (still need to finish coding this). (imap_get_uids): Implemented. (imap_get_summary): Found a way to get the date (imap_summary_get_by_uid): Same. (imap_free_summary): Implemented. * string-utils.c (strstrcase): Fixed a compile warning * providers/imap/camel-imap-summary.c: Removed - we don't need a CamelImapSummary structure. svn path=/trunk/; revision=3606
* worked on getting providers/imap/* to build cleanly, fixed a number of ↵Jeffrey Stedfast2000-06-071-3/+4
| | | | | | | | stupid errors and things like that am commit'ing code since there are some volunteers that would like to work on imap svn path=/trunk/; revision=3440
* Added more files to the imap provider to use as an outline - will likely ↵Jeffrey Stedfast2000-05-251-0/+81
need heavy editing later in development This is mostly meant as guidance to both me and any volunteers that start working on imap svn path=/trunk/; revision=3192