StorageApi class
Methods
clearCookies ({BrowserContextID ? browserContextId })
→ Future <void >
Clears cookies.
browserContextId
Browser context to use when called on the browser endpoint.
clearDataForOrigin (String origin , String storageTypes )
→ Future <void >
Clears storage for origin.
origin
Security origin.
storageTypes
Comma separated list of StorageType to clear.
clearDataForStorageKey (String storageKey , String storageTypes )
→ Future <void >
Clears storage for storage key.
storageKey
Storage key.
storageTypes
Comma separated list of StorageType to clear.
clearSharedStorageEntries (String ownerOrigin )
→ Future <void >
Clears all entries for a given origin's shared storage.
clearTrustTokens (String issuerOrigin )
→ Future <bool >
Removes all Trust Tokens issued by the provided issuerOrigin.
Leaves other stored data, including the issuer's Redemption Records, intact.
Returns: True if any tokens were deleted, false otherwise.
deleteSharedStorageEntry (String ownerOrigin , String key )
→ Future <void >
Deletes entry for key
(if it exists) for a given origin's shared storage.
getCookies ({BrowserContextID ? browserContextId })
→ Future <List <Cookie > >
Returns all browser cookies.
browserContextId
Browser context to use when called on the browser endpoint.
Returns: Array of cookie objects.
getInterestGroupDetails (String ownerOrigin , String name )
→ Future <InterestGroupDetails >
Gets details for a named interest group.
getSharedStorageEntries (String ownerOrigin )
→ Future <List <SharedStorageEntry > >
Gets the entries in an given origin's shared storage.
getSharedStorageMetadata (String ownerOrigin )
→ Future <SharedStorageMetadata >
Gets metadata for an origin's shared storage.
getStorageKeyForFrame (FrameId frameId )
→ Future <SerializedStorageKey >
Returns a storage key given a frame id.
getTrustTokens ()
→ Future <List <TrustTokens > >
Returns the number of stored Trust Tokens per issuer for the
current browsing context.
getUsageAndQuota (String origin )
→ Future <GetUsageAndQuotaResult >
Returns usage and quota in bytes.
origin
Security origin.
noSuchMethod (Invocation invocation )
→ dynamic
Invoked when a nonexistent method or property is accessed.
inherited
overrideQuotaForOrigin (String origin , {num ? quotaSize })
→ Future <void >
Override quota for the specified origin
origin
Security origin.
quotaSize
The quota size (in bytes) to override the original quota with.
If this is called multiple times, the overridden quota will be equal to
the quotaSize provided in the final call. If this is called without
specifying a quotaSize, the quota will be reset to the default value for
the specified origin. If this is called multiple times with different
origins, the override will be maintained for each origin until it is
disabled (called without a quotaSize).
resetSharedStorageBudget (String ownerOrigin )
→ Future <void >
Resets the budget for ownerOrigin
by clearing all budget withdrawals.
setCookies (List <CookieParam > cookies , {BrowserContextID ? browserContextId })
→ Future <void >
Sets given cookies.
cookies
Cookies to be set.
browserContextId
Browser context to use when called on the browser endpoint.
setInterestGroupTracking (bool enable )
→ Future <void >
Enables/Disables issuing of interestGroupAccessed events.
setSharedStorageEntry (String ownerOrigin , String key , String value , {bool ? ignoreIfPresent })
→ Future <void >
Sets entry with key
and value
for a given origin's shared storage.
ignoreIfPresent
If ignoreIfPresent
is included and true, then only sets the entry if
key
doesn't already exist.
setSharedStorageTracking (bool enable )
→ Future <void >
Enables/disables issuing of sharedStorageAccessed events.
toString ()
→ String
A string representation of this object.
inherited
trackCacheStorageForOrigin (String origin )
→ Future <void >
Registers origin to be notified when an update occurs to its cache storage list.
origin
Security origin.
trackCacheStorageForStorageKey (String storageKey )
→ Future <void >
Registers storage key to be notified when an update occurs to its cache storage list.
storageKey
Storage key.
trackIndexedDBForOrigin (String origin )
→ Future <void >
Registers origin to be notified when an update occurs to its IndexedDB.
origin
Security origin.
trackIndexedDBForStorageKey (String storageKey )
→ Future <void >
Registers storage key to be notified when an update occurs to its IndexedDB.
storageKey
Storage key.
untrackCacheStorageForOrigin (String origin )
→ Future <void >
Unregisters origin from receiving notifications for cache storage.
origin
Security origin.
untrackCacheStorageForStorageKey (String storageKey )
→ Future <void >
Unregisters storage key from receiving notifications for cache storage.
storageKey
Storage key.
untrackIndexedDBForOrigin (String origin )
→ Future <void >
Unregisters origin from receiving notifications for IndexedDB.
origin
Security origin.
untrackIndexedDBForStorageKey (String storageKey )
→ Future <void >
Unregisters storage key from receiving notifications for IndexedDB.
storageKey
Storage key.