Changeset 2287

Show
Ignore:
Timestamp:
06/27/07 14:53:39
Author:
jdapena
Message:

These changes add support for purging specific attachments
from cache, with an implementation in the IMAP backend. This
is a major API change.

* libtinymail/tny-msg.[ch]:

(tny_msg_rewrite_cache): added new method to rewrite cache
and expunge purged attachments if supported.

* libtinymail/tny-mime-part.[ch]:

(tny_mime_part_is_purged, tny_mime_part_set_purte): added two
methods that mark a mime part to be purged in cache (in
storages that support this).

* libtinymail-camel/tny-camel-folder.c:

(tny_camel_folder_rewrite_cache): new method that calls
the new Camel rewrite cache api for a message.

* libtinymail-camel/tny-camel-mime-part.[ch]:

implementation of tny_mime_part_is_purged and
tny_mime_part_set_purged, to mark parts to be purged
in IMAP.

* libtinymail-camel/camel-lite/camel/providers/camel-imap-folder.c:

(imap_rewrite_cache): new method that rewrites the cache representation
of a message purging attachments marked to be purged.

* libtinymail-camel/camel-lite/camel/providers/camel-imap-message-cache.[ch]

(camel_imap_message_cache_replace_with_wrapper): replaces the cache
entry for a message with a new representation from wrapper. This should
purge attachments marked as purge, in collaboration with mime part.

* libtinymail-camel/camel-lite/camel/camel-folder.[ch]:

(rewrite_cache): added default empty implementation and virtual.

* libtinymail-camel/camel-lite/camel/camel-mime-part.c:

now, if message disposition is "purged", output for the attachment is
disabled. This should let user purge attachments on recaching.

* libtinymail-camel/tny-camel-msg.[ch]:

(tny_camel_msg_rewrite_cache_default, tny_camel_msg_rewrite_cache):
implementation of rewrite method using camel new methods to rewrite
cache.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/ChangeLog

    r2283 r2287  
     12007-06-27  Jose Dapena Paz  <jdapena@igalia.com> 
     2 
     3        These changes add support for purging specific attachments  
     4        from cache, with an implementation in the IMAP backend. This 
     5        is a major API change. 
     6 
     7        * libtinymail/tny-msg.[ch]: 
     8        (tny_msg_rewrite_cache): added new method to rewrite cache 
     9        and expunge purged attachments if supported. 
     10 
     11        * libtinymail/tny-mime-part.[ch]: 
     12        (tny_mime_part_is_purged, tny_mime_part_set_purte): added two 
     13        methods that mark a mime part to be purged in cache (in 
     14        storages that support this). 
     15 
     16        * libtinymail-camel/tny-camel-folder.c: 
     17        (tny_camel_folder_rewrite_cache): new method that calls 
     18        the new Camel rewrite cache api for a message. 
     19 
     20        * libtinymail-camel/tny-camel-mime-part.[ch]: 
     21        implementation of tny_mime_part_is_purged and 
     22        tny_mime_part_set_purged, to mark parts to be purged 
     23        in IMAP. 
     24 
     25        * lintinymail-camel/camel-lite/camel/providers/camel-imap-folder.c: 
     26        (imap_rewrite_cache): new method that rewrites the cache representation 
     27        of a message purging attachments marked to be purged. 
     28 
     29        * libtinymail-camel/camel-lite/camel/providers/camel-imap-message-cache.[ch]: 
     30        (camel_imap_message_cache_replace_with_wrapper): replaces the cache 
     31        entry for a message with a new representation from wrapper. This should 
     32        purge attachments marked as purge, in collaboration with mime part. 
     33 
     34        * libtinymail-camel/camel-lite/camel/camel-folder.[ch]: 
     35        (rewrite_cache): added default empty implementation and virtual. 
     36 
     37        * libtinymail-camel/camel-lite/camel/camel-mime-part.c: 
     38        now, if message disposition is "purged", output for the attachment is 
     39        disabled. This should let user purge attachments on recaching. 
     40 
     41        * libtinymail-camel/tny-camel-msg.[ch]: 
     42        (tny_camel_msg_rewrite_cache_default, tny_camel_msg_rewrite_cache): implementation 
     43        of rewrite method using camel new methods to rewrite cache. 
     44 
    1452007-06-27  Sergio Villar Senin  <svillar@igalia.com> 
    246 
  • trunk/libtinymail-camel/camel-lite/camel/camel-folder.c

    r2267 r2287  
    120120static void  
    121121delete_attachments (CamelFolder *folder, const char *uid) 
     122{ 
     123} 
     124 
     125static void  
     126rewrite_cache (CamelFolder *folder, const char *uid, CamelMimeMessage *msg) 
    122127{ 
    123128} 
     
    178183        camel_folder_class->is_frozen = is_frozen; 
    179184        camel_folder_class->delete_attachments = delete_attachments; 
     185        camel_folder_class->rewrite_cache = rewrite_cache; 
    180186 
    181187        /* virtual method overload */ 
     
    332338 
    333339        return CF_CLASS (folder)->delete_attachments (folder, uid); 
     340} 
     341 
     342void  
     343camel_folder_rewrite_cache (CamelFolder *folder, const char *uid, CamelMimeMessage *msg) 
     344{ 
     345        g_return_if_fail (CAMEL_IS_FOLDER (folder)); 
     346 
     347        return CF_CLASS (folder)->rewrite_cache (folder, uid, msg); 
    334348} 
    335349 
  • trunk/libtinymail-camel/camel-lite/camel/camel-folder.h

    r2268 r2287  
    207207 
    208208        void (*delete_attachments) (CamelFolder *folder, const char *uid); 
     209        void (*rewrite_cache) (CamelFolder *folder, const char *uid, CamelMimeMessage *msg); 
    209210 
    210211} CamelFolderClass; 
     
    365366 
    366367void camel_folder_delete_attachments (CamelFolder *folder, const char *uid); 
     368void camel_folder_rewrite_cache (CamelFolder *folder, const char *uid, CamelMimeMessage *msg); 
    367369 
    368370G_END_DECLS 
  • trunk/libtinymail-camel/camel-lite/camel/camel-mime-part.c

    r2030 r2287  
    780780        ssize_t count; 
    781781        int errnosav; 
     782        const gchar *disposition; 
    782783         
    783784        d(printf("mime_part::write_to_stream\n")); 
     
    816817                return -1; 
    817818        total += count; 
    818          
     819 
     820        disposition = camel_mime_part_get_disposition (mp); 
     821 
     822        if (disposition != NULL && !strcmp (disposition, "purged")) { 
     823                camel_mime_part_set_content (mp, " ", 1, "text/plain"); 
     824        } 
     825 
    819826        content = camel_medium_get_content_object(medium); 
    820827        if (content) { 
  • trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-folder.c

    r2268 r2287  
    163163 
    164164static void imap_delete_attachments (CamelFolder *folder, const char *uid); 
     165static void imap_rewrite_cache (CamelFolder *folder, const char *uid, CamelMimeMessage *msg); 
    165166 
    166167 
     
    195196        camel_folder_class->thaw = imap_thaw; 
    196197        camel_folder_class->delete_attachments = imap_delete_attachments; 
     198        camel_folder_class->rewrite_cache = imap_rewrite_cache; 
    197199 
    198200        camel_disco_folder_class->refresh_info_online = imap_refresh_info; 
     
    344346        CamelImapMessageCache *cache = CAMEL_IMAP_FOLDER (folder)->cache; 
    345347        camel_imap_message_cache_delete_attachments (cache, uid); 
     348        return; 
     349} 
     350 
     351static void 
     352imap_rewrite_cache (CamelFolder *folder, const char *uid, CamelMimeMessage *msg) 
     353{ 
     354        CamelImapMessageCache *cache = CAMEL_IMAP_FOLDER (folder)->cache; 
     355 
     356        camel_imap_message_cache_replace_with_wrapper (cache, uid, CAMEL_DATA_WRAPPER  (msg), NULL); 
     357/*      camel_imap_message_cache_remove (cache, uid); */ 
     358/*      camel_imap_message_cache_replace_cache (cache, uid, NULL, uid, ".purgetmp"); */ 
    346359        return; 
    347360} 
  • trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-message-cache.c

    r2274 r2287  
    449449                insert_finish (cache, uid, path, key, stream); 
    450450                camel_object_unref (CAMEL_OBJECT (stream)); 
     451        } 
     452} 
     453 
     454/** 
     455 * camel_imap_message_cache_replace_with_wrapper: 
     456 * @cache: the cache 
     457 * @uid: UID of the message data to cache 
     458 * @part_spec: the IMAP part_spec of the data 
     459 * @wrapper: the wrapper to cache 
     460 * 
     461 * Caches the provided data into @cache. 
     462 **/ 
     463void 
     464camel_imap_message_cache_replace_with_wrapper (CamelImapMessageCache *cache, 
     465                                               const char *uid, 
     466                                               CamelDataWrapper *wrapper, CamelException *ex) 
     467{ 
     468        char *path, *key; 
     469        CamelStream *stream; 
     470        gchar *real = g_strdup_printf("%s/%s.purgetmp", cache->path, uid); 
     471 
     472        stream = camel_stream_fs_new_with_name (real, O_RDWR|O_CREAT|O_TRUNC, 0600); 
     473        g_free (real); 
     474        if (!stream) 
     475                return; 
     476         
     477        if (camel_data_wrapper_write_to_stream (wrapper, stream) == -1) { 
     478                camel_exception_setv (ex, CAMEL_EXCEPTION_SYSTEM, 
     479                                      _("Failed to cache message %s: %s"), 
     480                                      uid, g_strerror (errno)); 
     481        } else { 
     482                camel_object_unref (CAMEL_OBJECT (stream)); 
     483                camel_imap_message_cache_remove (cache, uid); 
     484                camel_imap_message_cache_replace_cache (cache, uid, NULL, uid, "purgetmp"); 
     485                camel_imap_message_cache_set_partial (cache, uid, TRUE); 
    451486        } 
    452487} 
     
    648683} 
    649684 
     685void camel_imap_message_cache_replace_cache (CamelImapMessageCache *cache, const char *uid, const char *part_spec, 
     686                                          const char *dest_uid, const char *dest_part_spec) 
     687{ 
     688        gchar *real = g_strdup_printf ("%s/%s.%s", cache->path, uid, (part_spec)?part_spec:""); 
     689        gchar *dest_real = g_strdup_printf ("%s/%s.%s", cache->path, dest_uid, (dest_part_spec)?dest_part_spec:""); 
     690 
     691        rename (dest_real, real); 
     692 
     693        g_free (real); 
     694        g_free (dest_real); 
     695 
     696} 
    650697void 
    651698camel_imap_message_cache_delete_attachments (CamelImapMessageCache *cache, const char *uid) 
  • trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-message-cache.h

    r2267 r2287  
    108108void camel_imap_message_cache_delete_attachments (CamelImapMessageCache *cache, const char *uid); 
    109109 
     110void camel_imap_message_cache_replace_cache (CamelImapMessageCache *cache, const char *uid, const char *part_spec, 
     111                                             const char *dest_uid, const char *dest_part_spec); 
     112 
    110113 
    111114/* Standard Camel function */ 
  • trunk/libtinymail-camel/tny-camel-folder-priv.h

    r2276 r2287  
    7474 
    7575void _tny_camel_folder_uncache_attachments (TnyCamelFolder *self, const gchar *uid); 
     76void _tny_camel_folder_rewrite_cache (TnyCamelFolder *self, const gchar *uid, CamelMimeMessage *msg); 
    7677 
    7778void _tny_camel_folder_remove_folder_actual (TnyFolderStore *self, TnyFolder *folder, GError **err); 
  • trunk/libtinymail-camel/tny-camel-folder.c

    r2286 r2287  
    453453 
    454454        camel_folder_delete_attachments (priv->folder, uid); 
     455 
     456        g_static_rec_mutex_unlock (priv->folder_lock); 
     457} 
     458 
     459void  
     460_tny_camel_folder_rewrite_cache (TnyCamelFolder *self, const gchar *uid, CamelMimeMessage *msg) 
     461{ 
     462        TnyCamelFolderPriv *priv = TNY_CAMEL_FOLDER_GET_PRIVATE (self); 
     463 
     464        g_static_rec_mutex_lock (priv->folder_lock); 
     465 
     466        if (!priv->folder || !priv->loaded || !CAMEL_IS_FOLDER (priv->folder)) 
     467                if (!load_folder_no_lock (priv)) 
     468                { 
     469                        g_static_rec_mutex_unlock (priv->folder_lock); 
     470                        return; 
     471                } 
     472 
     473        camel_folder_rewrite_cache (priv->folder, uid, msg); 
    455474 
    456475        g_static_rec_mutex_unlock (priv->folder_lock); 
  • trunk/libtinymail-camel/tny-camel-mime-part.c

    r2225 r2287  
    589589} 
    590590 
     591static gboolean 
     592tny_camel_mime_part_is_purged (TnyMimePart *self) 
     593{ 
     594        return TNY_CAMEL_MIME_PART_GET_CLASS (self)->is_purged_func (self); 
     595} 
     596 
     597static gboolean 
     598tny_camel_mime_part_is_purged_default (TnyMimePart *self) 
     599{ 
     600        TnyCamelMimePartPriv *priv = TNY_CAMEL_MIME_PART_GET_PRIVATE (self); 
     601        const gchar *disposition; 
     602 
     603        disposition = camel_mime_part_get_disposition (priv->part); 
     604        return (disposition != NULL) && (!strcmp (disposition, "purged")); 
     605} 
     606 
    591607static gboolean  
    592608tny_camel_mime_part_content_type_is (TnyMimePart *self, const gchar *type) 
     
    835851} 
    836852 
     853static void 
     854tny_camel_mime_part_set_purged_default (TnyMimePart *self) 
     855{ 
     856        TnyCamelMimePartPriv *priv = TNY_CAMEL_MIME_PART_GET_PRIVATE (self); 
     857 
     858        g_mutex_lock (priv->part_lock); 
     859        camel_mime_part_set_disposition (priv->part, "purged"); 
     860        g_mutex_unlock (priv->part_lock); 
     861} 
     862 
     863static void 
     864tny_camel_mime_part_set_purged (TnyMimePart *self) 
     865{ 
     866        TNY_CAMEL_MIME_PART_GET_CLASS (self)->set_purged_func (self); 
     867        return; 
     868} 
     869 
    837870static void  
    838871tny_camel_mime_part_set_content_type_default (TnyMimePart *self, const gchar *content_type) 
     
    934967        klass->get_description_func = tny_camel_mime_part_get_description; 
    935968        klass->get_content_location_func = tny_camel_mime_part_get_content_location; 
     969        klass->is_purged_func = tny_camel_mime_part_is_purged; 
    936970        klass->set_content_location_func = tny_camel_mime_part_set_content_location; 
    937971        klass->set_description_func = tny_camel_mime_part_set_description; 
     972        klass->set_purged_func = tny_camel_mime_part_set_purged; 
    938973        klass->set_content_id_func = tny_camel_mime_part_set_content_id; 
    939974        klass->set_filename_func = tny_camel_mime_part_set_filename; 
     
    9681003        class->get_description_func = tny_camel_mime_part_get_description_default; 
    9691004        class->get_content_location_func = tny_camel_mime_part_get_content_location_default; 
     1005        class->is_purged_func = tny_camel_mime_part_is_purged_default; 
     1006        class->set_purged_func = tny_camel_mime_part_set_purged_default; 
    9701007        class->set_content_location_func = tny_camel_mime_part_set_content_location_default; 
    9711008        class->set_description_func = tny_camel_mime_part_set_description_default; 
  • trunk/libtinymail-camel/tny-camel-mime-part.h

    r2129 r2287  
    6060        const gchar* (*get_description_func) (TnyMimePart *self); 
    6161        const gchar* (*get_content_location_func) (TnyMimePart *self); 
     62        gboolean (*is_purged_func) (TnyMimePart *self); 
    6263        void (*set_content_location_func) (TnyMimePart *self, const gchar *content_location);  
    6364        void (*set_description_func) (TnyMimePart *self, const gchar *description);  
     
    6566        void (*set_filename_func) (TnyMimePart *self, const gchar *filename); 
    6667        void (*set_content_type_func) (TnyMimePart *self, const gchar *contenttype); 
     68        void (*set_purged_func) (TnyMimePart *self); 
    6769        gboolean (*is_attachment_func) (TnyMimePart *self); 
    6870        void (*get_parts_func) (TnyMimePart *self, TnyList *list); 
  • trunk/libtinymail-camel/tny-camel-msg.c

    r2285 r2287  
    202202} 
    203203 
     204static void 
     205tny_camel_msg_rewrite_cache_default (TnyMsg *self) 
     206{ 
     207        TnyCamelMsgPriv *priv = TNY_CAMEL_MSG_GET_PRIVATE (self); 
     208        CamelMimeMessage *msg; 
     209         
     210        if (priv->folder && priv->header) { 
     211                msg = _tny_camel_msg_get_camel_mime_message (TNY_CAMEL_MSG (self)); 
     212                _tny_camel_folder_rewrite_cache (TNY_CAMEL_FOLDER(priv->folder), 
     213                                                 tny_header_get_uid (priv->header), 
     214                                                 msg); 
     215        } 
     216        return; 
     217} 
     218 
     219static void 
     220tny_camel_msg_rewrite_cache (TnyMsg *self) 
     221{ 
     222        TNY_CAMEL_MSG_GET_CLASS (self)->rewrite_cache_func (self); 
     223        return; 
     224} 
     225 
    204226static TnyHeader* 
    205227tny_camel_msg_get_header_default (TnyMsg *self) 
     
    327349        klass->get_url_string_func = tny_camel_msg_get_url_string; 
    328350        klass->uncache_attachments_func = tny_camel_msg_uncache_attachments; 
     351        klass->rewrite_cache_func = tny_camel_msg_rewrite_cache; 
    329352 
    330353        return; 
     
    335358{ 
    336359        GObjectClass *object_class; 
    337  
     360         
    338361        parent_class = g_type_class_peek_parent (class); 
    339362        object_class = (GObjectClass*) class; 
    340  
     363         
    341364        class->get_header_func = tny_camel_msg_get_header_default; 
    342365        class->get_folder_func = tny_camel_msg_get_folder_default; 
    343366        class->get_url_string_func = tny_camel_msg_get_url_string_default; 
    344367        class->uncache_attachments_func = tny_camel_msg_uncache_attachments_default; 
    345  
     368        class->rewrite_cache_func = tny_camel_msg_rewrite_cache_default; 
     369         
    346370        object_class->finalize = tny_camel_msg_finalize; 
    347  
     371         
    348372        g_type_class_add_private (object_class, sizeof (TnyCamelMsgPriv)); 
    349373 
     
    389413 
    390414        if (G_UNLIKELY(type == 0)) 
    391        
    392                static const GTypeInfo info =  
    393                
     415         
     416            static const GTypeInfo info =  
     417                 
    394418                  sizeof (TnyCamelMsgClass), 
    395419                  NULL,   /* base_init */ 
     
    403427                  NULL 
    404428                }; 
    405  
     429                 
    406430                static const GInterfaceInfo tny_msg_info =  
    407                
     431                 
    408432                  (GInterfaceInitFunc) tny_msg_init, /* interface_init */ 
    409433                  NULL,         /* interface_finalize */ 
    410434                  NULL          /* interface_data */ 
    411435                }; 
    412  
     436                 
    413437                type = g_type_register_static (TNY_TYPE_CAMEL_MIME_PART, 
    414                         "TnyCamelMsg", 
    415                         &info, 0); 
    416  
     438                                              "TnyCamelMsg", 
     439                                              &info, 0); 
     440                 
    417441                g_type_add_interface_static (type, TNY_TYPE_MSG, 
    418                         &tny_msg_info); 
    419  
     442                                            &tny_msg_info); 
     443                 
    420444        } 
    421445 
  • trunk/libtinymail-camel/tny-camel-msg.h

    r2267 r2287  
    5656        gchar* (*get_url_string_func) (TnyMsg *self); 
    5757        void (*uncache_attachments_func) (TnyMsg *self); 
     58        void (*rewrite_cache_func) (TnyMsg *self); 
    5859}; 
    5960 
  • trunk/libtinymail/tny-mime-part.c

    r2129 r2287  
    293293 
    294294/** 
     295 * tny_mime_part_set_purged: 
     296 * @self: a #TnyMimePart object 
     297 *  
     298 * Set the message as purged in cache 
     299 * 
     300 **/ 
     301void 
     302tny_mime_part_set_purged (TnyMimePart *self) 
     303{ 
     304#ifdef DBC /* require */ 
     305        g_assert (TNY_IS_MIME_PART (self)); 
     306        g_assert (TNY_MIME_PART_GET_IFACE (self)->set_purged_func != NULL); 
     307#endif 
     308 
     309        TNY_MIME_PART_GET_IFACE (self)->set_purged_func (self); 
     310        return; 
     311} 
     312 
     313/** 
    295314 * tny_mime_part_set_filename: 
    296315 * @self: a #TnyMimePart object 
     
    388407        g_assert (retval == NULL || strlen (retval) > 0); 
    389408#endif 
     409 
     410        return retval; 
     411} 
     412 
     413/** 
     414 * tny_mime_part_is_purged: 
     415 * @self: a #TnyMimePart object 
     416 *  
     417 * Get if this attachment has been purged from cache. 
     418 * 
     419 * Return value: a #gboolean 
     420 * 
     421 **/ 
     422gboolean 
     423tny_mime_part_is_purged (TnyMimePart *self) 
     424{ 
     425        gboolean retval; 
     426 
     427#ifdef DBC /* require */ 
     428        g_assert (TNY_IS_MIME_PART (self)); 
     429        g_assert (TNY_MIME_PART_GET_IFACE (self)->is_purged_func != NULL); 
     430#endif 
     431 
     432        retval = TNY_MIME_PART_GET_IFACE (self)->is_purged_func (self); 
    390433 
    391434        return retval; 
  • trunk/libtinymail/tny-mime-part.h

    r2129 r2287  
    5454        const gchar* (*get_description_func) (TnyMimePart *self); 
    5555        const gchar* (*get_content_location_func) (TnyMimePart *self); 
     56        gboolean (*is_purged_func) (TnyMimePart *self); 
     57   
    5658        void (*set_content_location_func) (TnyMimePart *self, const gchar *content_location);  
    5759        void (*set_description_func) (TnyMimePart *self, const gchar *description);  
     
    5961        void (*set_filename_func) (TnyMimePart *self, const gchar *filename); 
    6062        void (*set_content_type_func) (TnyMimePart *self, const gchar *contenttype); 
     63        void (*set_purged_func) (TnyMimePart *self); 
    6164        gboolean (*is_attachment_func) (TnyMimePart *self); 
    6265        void (*get_parts_func) (TnyMimePart *self, TnyList *list); 
     
    7881const gchar* tny_mime_part_get_description (TnyMimePart *self); 
    7982const gchar* tny_mime_part_get_content_location (TnyMimePart *self); 
     83gboolean tny_mime_part_is_purged (TnyMimePart *self); 
    8084void tny_mime_part_set_content_location (TnyMimePart *self, const gchar *content_location); 
    8185void tny_mime_part_set_description (TnyMimePart *self, const gchar *description);  
     
    8387void tny_mime_part_set_filename (TnyMimePart *self, const gchar *filename); 
    8488void tny_mime_part_set_content_type (TnyMimePart *self, const gchar *contenttype); 
     89void tny_mime_part_set_purged (TnyMimePart *self); 
    8590gboolean tny_mime_part_is_attachment (TnyMimePart *self); 
    8691void tny_mime_part_decode_to_stream (TnyMimePart *self, TnyStream *stream); 
  • trunk/libtinymail/tny-msg.c

    r2268 r2287  
    4747 
    4848        TNY_MSG_GET_IFACE (self)->uncache_attachments_func (self); 
     49 
     50#ifdef DBC /* ensure */ 
     51#endif 
     52 
     53        return; 
     54} 
     55 
     56/** 
     57 * tny_msg_rewrite_cache: 
     58 * @self: a #TnyMsg object 
     59 *  
     60 * API WARNING: This API might change 
     61 *  
     62 * Rewrite the message to cache, purging mime parts marked for purge. 
     63 *  
     64 **/ 
     65void  
     66tny_msg_rewrite_cache (TnyMsg *self) 
     67{ 
     68#ifdef DBC /* require */ 
     69        g_assert (TNY_IS_MSG (self)); 
     70        g_assert (TNY_MSG_GET_IFACE (self)->rewrite_cache_func != NULL); 
     71#endif 
     72 
     73        TNY_MSG_GET_IFACE (self)->rewrite_cache_func (self); 
    4974 
    5075#ifdef DBC /* ensure */ 
  • trunk/libtinymail/tny-msg.h

    r2267 r2287  
    4747        gchar* (*get_url_string_func) (TnyMsg *self); 
    4848        void (*uncache_attachments_func) (TnyMsg *self); 
     49        void (*rewrite_cache_func) (TnyMsg *self); 
    4950 
    5051}; 
     
    5657gchar* tny_msg_get_url_string (TnyMsg *self); 
    5758void tny_msg_uncache_attachments (TnyMsg *self); 
     59void tny_msg_rewrite_cache (TnyMsg *self); 
    5860 
    5961G_END_DECLS