Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(476)

Unified Diff: Source/core/fetch/Resource.h

Issue 528013002: Restore in-memory parser cache for V8 compile. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add unit tests. Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/fetch/Resource.h
diff --git a/Source/core/fetch/Resource.h b/Source/core/fetch/Resource.h
index 157443890a34ee531010746355a4e7689b130fc3..42dffdcf6aca20f72c54c521c04bb96c42bcc96f 100644
--- a/Source/core/fetch/Resource.h
+++ b/Source/core/fetch/Resource.h
@@ -195,7 +195,10 @@ public:
// Caches the given metadata in association with this resource and suggests
// that the platform persist it. The dataTypeID is a pseudo-randomly chosen
// identifier that is used to distinguish data generated by the caller.
- void setCachedMetadata(unsigned dataTypeID, const char*, size_t);
+ // If persist is set, this will be sent to Platform::cacheMetadata for
+ // persistent caching by the embedder. Otherwise the caching is only
+ // in memory and therefore in-process.
+ void setCachedMetadata(unsigned dataTypeID, const char*, size_t, bool persist = true);
jochen (gone - plz use gerrit) 2014/09/05 11:48:04 is it possible to use a enum instead of the bool?
vogelheim 2014/09/05 11:54:12 Hm. Yes, but why? I don't understand the benefit.
jochen (gone - plz use gerrit) 2014/09/05 14:05:40 so the callsites are easier to read "setCachedMeta
vogelheim 2014/09/05 14:49:01 Done. I called it CacheLocally and SendToPlatform
// Reset existing metadata, to allow setting new data.
void clearCachedMetadata();

Powered by Google App Engine
This is Rietveld 408576698