WebResource

class WebResource(pointer: <Error class: unknown class><<Error class: unknown class>>)

Represents a resource at the end of a URI.

A #WebKitWebResource encapsulates content for each resource at the end of a particular URI. For example, one #WebKitWebResource will be created for each separate image and stylesheet when a page is loaded.

You can access the response and the URI for a given #WebKitWebResource, using webkit_web_resource_get_uri() and webkit_web_resource_get_response(), as well as the raw data, using webkit_web_resource_get_data().

Skipped during bindings generation

  • parameter length: length: Out parameter is not supported

Constructors

Link copied to clipboard
constructor(pointer: <Error class: unknown class><<Error class: unknown class>>)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

The #WebKitURIResponse associated with this resource.

Link copied to clipboard
val uri: String

The current active URI of the #WebKitWebResource. See webkit_web_resource_get_uri() for more details.

Link copied to clipboard
val webkitWebResourcePointer: <Error class: unknown class><<Error class: unknown class>>

Functions

Link copied to clipboard
fun connectFailed(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (<Error class: unknown class>) -> Unit): <Error class: unknown class>

This signal is emitted when an error occurs during the resource load operation.

Link copied to clipboard
fun connectFailedWithTlsErrors(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (<Error class: unknown class>, <Error class: unknown class>) -> Unit): <Error class: unknown class>

This signal is emitted when a TLS error occurs during the resource load operation.

Link copied to clipboard
fun connectFinished(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: () -> Unit): <Error class: unknown class>

This signal is emitted when the resource load finishes successfully or due to an error. In case of errors #WebKitWebResource::failed signal is emitted before this one.

Link copied to clipboard
fun connectSentRequest(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: (request: UriRequest, redirectedResponse: UriResponse) -> Unit): <Error class: unknown class>

This signal is emitted when @request has been sent to the server. In case of a server redirection this signal is emitted again with the @request argument containing the new request sent to the server due to the redirection and the

Link copied to clipboard
fun getData(cancellable: <Error class: unknown class>? = null, callback: <Error class: unknown class>?)

Asynchronously get the raw data for @resource.