summaryrefslogtreecommitdiff
path: root/chromium/content/public/browser/browser_context.h
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2020-10-12 14:27:29 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2020-10-13 09:35:20 +0000
commitc30a6232df03e1efbd9f3b226777b07e087a1122 (patch)
treee992f45784689f373bcc38d1b79a239ebe17ee23 /chromium/content/public/browser/browser_context.h
parent7b5b123ac58f58ffde0f4f6e488bcd09aa4decd3 (diff)
downloadqtwebengine-chromium-85-based.tar.gz
BASELINE: Update Chromium to 85.0.4183.14085-based
Change-Id: Iaa42f4680837c57725b1344f108c0196741f6057 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'chromium/content/public/browser/browser_context.h')
-rw-r--r--chromium/content/public/browser/browser_context.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/chromium/content/public/browser/browser_context.h b/chromium/content/public/browser/browser_context.h
index 8140c9b0468..429b7d0188e 100644
--- a/chromium/content/public/browser/browser_context.h
+++ b/chromium/content/public/browser/browser_context.h
@@ -92,6 +92,7 @@ class SharedCorsOriginAccessList;
class SiteInstance;
class StorageNotificationService;
class StoragePartition;
+class StoragePartitionConfig;
class SSLHostStateDelegate;
// A mapping from the scheme name to the protocol handler that services its
@@ -130,10 +131,25 @@ class CONTENT_EXPORT BrowserContext : public base::SupportsUserData {
static StoragePartition* GetStoragePartition(BrowserContext* browser_context,
SiteInstance* site_instance,
bool can_create = true);
+
+ // Returns a StoragePartition for the given StoragePartitionConfig. By
+ // default this will create a new StoragePartition if it doesn't exist,
+ // unless |can_create| is false.
+ static StoragePartition* GetStoragePartition(
+ BrowserContext* browser_context,
+ const StoragePartitionConfig& storage_partition_config,
+ bool can_create = true);
+
+ // Deprecated. Do not add new callers. Use the SiteInstance or
+ // StoragePartitionConfig methods above instead.
+ // Returns a StoragePartition for the given site URL. By default this will
+ // create a new StoragePartition if it doesn't exist, unless |can_create| is
+ // false.
static StoragePartition* GetStoragePartitionForSite(
BrowserContext* browser_context,
const GURL& site,
bool can_create = true);
+
using StoragePartitionCallback =
base::RepeatingCallback<void(StoragePartition*)>;
static void ForEachStoragePartition(BrowserContext* browser_context,