1.48 <WebKitWebsiteDataManager>

Class: <WebKitWebsiteDataManager>

It derives from <GObject>.

Manages data stored locally by web sites.

You can use WebKitWebsiteDataManager to configure the local directories where website data will be stored. Use website-data-manager:base-data-directory and website-data-manager:base-cache-directory set a common base directory for all website data and caches.

A WebKitWebsiteDataManager can be ephemeral, in which case all the directory configuration is not needed because website data will never persist. You can create an ephemeral WebKitWebsiteDataManager with webkit_website_data_manager_new_ephemeral().

WebKitWebsiteDataManager can also be used to fetch website data, remove data stored by particular websites, or clear data for all websites modified since a given period of time.

Properties

Property: website-data-manager:base-cache-directory self

The base directory for caches. If #f, a default location will be used.

Its value is a string, or #f.

It can only be set when the object is made, with #:base-cache-directory.

Property: website-data-manager:base-data-directory self

The base directory for website data. If #f, a default location will be used.

Its value is a string, or #f.

It can only be set when the object is made, with #:base-data-directory.

Property: website-data-manager:is-ephemeral self

Whether the <WebKitWebsiteDataManager> is ephemeral. An ephemeral <WebKitWebsiteDataManager> handles all websites data as non-persistent, and nothing will be written to the client storage. Note that if you create an ephemeral <WebKitWebsiteDataManager> all other construction parameters to configure data directories will be ignored.

Its value is a boolean.

It can only be set when the object is made, with #:is-ephemeral.

Property: website-data-manager:origin-storage-ratio self

The percentage of volume space that can be used for data storage for every domain. If the maximum storage is reached the storage request will fail with a QuotaExceededError exception. A value of 0.0 means that data storage is not allowed. A value of -1.0, which is the default, means WebKit will use the default quota (1 GiB).

Its value is a real number.

It can only be set when the object is made, with #:origin-storage-ratio. It cannot be read.

Property: website-data-manager:total-storage-ratio self

The percentage of volume space that can be used for data storage for all domains. If the maximum storage is reached the eviction will happen. A value of 0.0 means that data storage is not allowed. A value of -1.0, which is the default, means there’s no limit for the total storage.

Its value is a real number.

It can only be set when the object is made, with #:total-storage-ratio. It cannot be read.

Procedures

Method: website-data-manager:clear self types timespan [cancellable] [callback]
Method: clear self types timespan [cancellable] [callback]

Asynchronously clear the website data of the given types modified in the past timespan.

If timespan is 0, all website data will be removed.

When the operation is finished, callback will be called. You can then call website-data-manager:clear-finish? to get the result of the operation.

Due to implementation limitations, this function does not currently delete any stored cookies if timespan is nonzero. This behavior may change in the future.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

types

Passed: a <WebKitWebsiteDataTypes>, or a list of its symbols, or one of them.

<WebKitWebsiteDataTypes>

timespan

Passed: a 64-bit integer.

a GTimeSpan

cancellable

Passed, or left out: a <GCancellable>, or #f.

a <GCancellable> or #f to ignore

callback

Passed, or left out: a procedure, or #f.

a GAsyncReadyCallback to call when the request is satisfied

See GAsyncReadyCallback for how it is called.

user-data

Not passed: guile-gi supplies it.

the data to pass to callback function

Method: website-data-manager:clear-finish? self result ⇒ %return
Method: clear-finish? self result ⇒ %return

Finish an asynchronous operation started with website-data-manager:clear

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

result

Passed: a <GAsyncResult>.

a <GAsyncResult>

%return

Returned: a boolean.

#t if website data was successfully cleared, or #f otherwise.

Method: website-data-manager:fetch self types [cancellable] [callback]
Method: fetch self types [cancellable] [callback]

Asynchronously get the list of <WebKitWebsiteData> for the given types.

When the operation is finished, callback will be called. You can then call website-data-manager:fetch-finish to get the result of the operation.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

types

Passed: a <WebKitWebsiteDataTypes>, or a list of its symbols, or one of them.

<WebKitWebsiteDataTypes>

cancellable

Passed, or left out: a <GCancellable>, or #f.

a <GCancellable> or #f to ignore

callback

Passed, or left out: a procedure, or #f.

a GAsyncReadyCallback to call when the request is satisfied

See GAsyncReadyCallback for how it is called.

user-data

Not passed: guile-gi supplies it.

the data to pass to callback function

Method: website-data-manager:fetch-finish self result ⇒ %return
Method: fetch-finish self result ⇒ %return

Finish an asynchronous operation started with website-data-manager:fetch.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

result

Passed: a <GAsyncResult>.

a <GAsyncResult>

%return

Returned: a list, each a <WebKitWebsiteData>.

a GList of <WebKitWebsiteData>. You must free the GList with g_list_free() and unref the <WebKitWebsiteData><!– –>s with website-data:unref when you’re done with them.

Method: website-data-manager:get-base-cache-directory self ⇒ %return
Method: get-base-cache-directory self ⇒ %return

Get the website-data-manager:base-cache-directory property.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

%return

Returned: a string, or #f.

the base directory for caches, or #f if website-data-manager:base-cache-directory was not provided or self is ephemeral.

Method: website-data-manager:get-base-data-directory self ⇒ %return
Method: get-base-data-directory self ⇒ %return

Get the website-data-manager:base-data-directory property.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

%return

Returned: a string, or #f.

the base directory for website data, or #f if website-data-manager:base-data-directory was not provided or self is ephemeral.

Method: website-data-manager:get-favicon-database self ⇒ %return
Method: get-favicon-database self ⇒ %return

Get the <WebKitFaviconDatabase> of self.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

%return

Returned: a <WebKitFaviconDatabase>, or #f.

a <WebKitFaviconDatabase>, or #f if website icons are disabled

Method: website-data-manager:get-favicons-enabled? self ⇒ %return
Method: get-favicons-enabled? self ⇒ %return

Get whether website icons are enabled.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

%return

Returned: a boolean.

#t if website icons are enabled, or #f otherwise.

Method: website-data-manager:get-itp-summary self [cancellable] [callback]
Method: get-itp-summary self [cancellable] [callback]

Asynchronously get the list of <WebKitITPThirdParty> seen for self.

Every <WebKitITPThirdParty> contains the list of <WebKitITPFirstParty> under which it has been seen.

When the operation is finished, callback will be called. You can then call website-data-manager:get-itp-summary-finish to get the result of the operation.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

cancellable

Passed, or left out: a <GCancellable>, or #f.

a <GCancellable> or #f to ignore

callback

Passed, or left out: a procedure, or #f.

a GAsyncReadyCallback to call when the request is satisfied

See GAsyncReadyCallback for how it is called.

user-data

Not passed: guile-gi supplies it.

the data to pass to callback function

Method: website-data-manager:get-itp-summary-finish self result ⇒ %return
Method: get-itp-summary-finish self result ⇒ %return

Finish an asynchronous operation started with website-data-manager:get-itp-summary.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

result

Passed: a <GAsyncResult>.

a <GAsyncResult>

%return

Returned: a list, each a <WebKitITPThirdParty>.

a GList of <WebKitITPThirdParty>. You must free the GList with g_list_free() and unref the <WebKitITPThirdParty><!– –>s with itpthird-party:unref when you’re done with them.

Method: website-data-manager:is-ephemeral? self ⇒ %return
Method: is-ephemeral? self ⇒ %return

Get whether a <WebKitWebsiteDataManager> is ephemeral.

See website-data-manager:is-ephemeral for more details.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

%return

Returned: a boolean.

#t if self is ephemeral or #f otherwise.

Method: website-data-manager:remove self types website-data [cancellable] [callback]
Method: remove self types website-data [cancellable] [callback]

Asynchronously removes the website data in the given website-data list.

Asynchronously removes the website data of the given types for websites in the given website-data list. Use website-data-manager:clear if you want to remove the website data for all sites.

When the operation is finished, callback will be called. You can then call website-data-manager:remove-finish? to get the result of the operation.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

types

Passed: a <WebKitWebsiteDataTypes>, or a list of its symbols, or one of them.

<WebKitWebsiteDataTypes>

website-data

Passed: a list, each a <WebKitWebsiteData>.

a GList of <WebKitWebsiteData>

cancellable

Passed, or left out: a <GCancellable>, or #f.

a <GCancellable> or #f to ignore

callback

Passed, or left out: a procedure, or #f.

a GAsyncReadyCallback to call when the request is satisfied

See GAsyncReadyCallback for how it is called.

user-data

Not passed: guile-gi supplies it.

the data to pass to callback function

Method: website-data-manager:remove-finish? self result ⇒ %return
Method: remove-finish? self result ⇒ %return

Finish an asynchronous operation started with website-data-manager:remove.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

result

Passed: a <GAsyncResult>.

a <GAsyncResult>

%return

Returned: a boolean.

#t if website data resources were successfully removed, or #f otherwise.

Method: website-data-manager:set-favicons-enabled self enabled
Method: set-favicons-enabled self enabled

Set whether website icons are enabled. Website icons are disabled by default. When website icons are disabled, the <WebKitFaviconDatabase> of self is closed and its reference removed, so website-data-manager:get-favicon-database will return #f. If website icons are enabled again, a new <WebKitFaviconDatabase> will be created.

self

Passed: a <WebKitWebsiteDataManager>.

a <WebKitWebsiteDataManager>

enabled

Passed: a boolean.

value to set