manpagez: man pages & more
html files: webkitgtk
Home | html | info | man

WebKitWebResource

WebKitWebResource — Represents a downloaded URI.

Properties

gchar * encoding Read
gchar * frame-name Read
gchar * mime-type Read
gchar * uri Read / Write / Construct Only

Signals

void content-length-received Run Last
void load-failed Run Last
void load-finished Run Last
void response-received Run Last

Types and Values

Object Hierarchy

    GObject
    ╰── WebKitWebResource

Description

A web resource encapsulates the data of the download as well as the URI, MIME type and frame name of the resource.

Functions

webkit_web_resource_get_data ()

GString *
webkit_web_resource_get_data (WebKitWebResource *web_resource);

Returns the data of the webResource .

Parameters

web_resource

a WebKitWebResource

 

Returns

a GString containing the character data of the webResource . The string is owned by WebKit and should not be freed or destroyed.

[transfer none]

Since: 1.1.14


webkit_web_resource_get_encoding ()

const gchar *
webkit_web_resource_get_encoding (WebKitWebResource *web_resource);

Parameters

web_resource

a WebKitWebResource

 

Returns

the encoding name of the resource

Since: 1.1.14


webkit_web_resource_get_frame_name ()

const gchar *
webkit_web_resource_get_frame_name (WebKitWebResource *web_resource);

Parameters

web_resource

a WebKitWebResource

 

Returns

the frame name of the resource.

Since: 1.1.14


webkit_web_resource_get_mime_type ()

const gchar *
webkit_web_resource_get_mime_type (WebKitWebResource *web_resource);

Parameters

web_resource

a WebKitWebResource

 

Returns

the MIME type of the resource

Since: 1.1.14


webkit_web_resource_get_uri ()

const gchar *
webkit_web_resource_get_uri (WebKitWebResource *web_resource);

Parameters

web_resource

a WebKitWebResource

 

Returns

the URI of the resource

Since: 1.1.14


webkit_web_resource_new ()

WebKitWebResource *
webkit_web_resource_new (const gchar *data,
                         gssize size,
                         const gchar *uri,
                         const gchar *mime_type,
                         const gchar *encoding,
                         const gchar *frame_name);

Returns a new WebKitWebResource. The encoding can be NULL. The frame_name argument can be used if the resource represents contents of an entire HTML frame, otherwise pass NULL.

Parameters

data

the data to initialize the WebKitWebResource

 

size

the length of data

 

uri

the URI of the WebKitWebResource

 

mime_type

the MIME type of the WebKitWebResource

 

encoding

the text encoding name of the WebKitWebResource

 

frame_name

the frame name of the WebKitWebResource

 

Returns

a new WebKitWebResource

Since: 1.1.14

Types and Values

WebKitWebResource

typedef struct _WebKitWebResource WebKitWebResource;

Property Details

The “encoding” property

  “encoding”                 gchar *

The encoding name to which the web resource was encoded in.

Flags: Read

Default value: NULL

Since: 1.1.14


The “frame-name” property

  “frame-name”               gchar *

The frame name for the web resource.

Flags: Read

Default value: NULL

Since: 1.1.14


The “mime-type” property

  “mime-type”                gchar *

The MIME type of the web resource.

Flags: Read

Default value: NULL

Since: 1.1.14


The “uri” property

  “uri”                      gchar *

The URI of the web resource

Flags: Read / Write / Construct Only

Default value: NULL

Since: 1.1.14

Signal Details

The “content-length-received” signal

void
user_function (WebKitWebResource *web_resource,
               gint               length_received,
               gpointer           user_data)

Emitted when new resource data has been received. The length_received variable stores the amount of bytes received since the last time this signal was emitted. This is useful to provide progress information about the resource load operation.

Parameters

web_resource

the WebKitWebResource that was loaded

 

length_received

the amount of data received since the last signal emission

 

user_data

user data set when the signal handler was connected.

 

Flags: Run Last

Since: 1.7.5


The “load-failed” signal

void
user_function (WebKitWebResource *web_resource,
               gpointer           error,
               gpointer           user_data)

Invoked when the web_resource failed to load

Parameters

web_resource

the WebKitWebResource that was loaded

 

error

the GError that was triggered

 

user_data

user data set when the signal handler was connected.

 

Flags: Run Last

Since: 1.7.5


The “load-finished” signal

void
user_function (WebKitWebResource *web_resource,
               gpointer           user_data)

Emitted when all the data for the resource was loaded

Parameters

web_resource

the WebKitWebResource being loaded

 

user_data

user data set when the signal handler was connected.

 

Flags: Run Last

Since: 1.7.5


The “response-received” signal

void
user_function (WebKitWebResource     *web_resource,
               WebKitNetworkResponse *response,
               gpointer               user_data)

Emitted when the response is received from the server.

Parameters

web_resource

the WebKitWebResource being loaded

 

response

the WebKitNetworkResponse that was received

 

user_data

user data set when the signal handler was connected.

 

Flags: Run Last

Since: 1.7.5

© manpagez.com 2000-2024
Individual documents may contain additional copyright information.