WebKit.ScriptMessageReply

Fields

None

Methods

ref ()

return_error_message (error_message)

return_value (reply_value)

unref ()

Details

class WebKit.ScriptMessageReply

A reply for a script message received. If no reply has been sent by the user, an automatically generated reply with undefined value with be sent.

New in version 2.40.

ref()
Returns:

the self passed in.

Return type:

WebKit.ScriptMessageReply

Atomically increments the reference count of self by one.

New in version 2.40.

return_error_message(error_message)
Parameters:

error_message (str) – An error message to return as specified by the user’s script message

Reply to a script message with an error message.

New in version 2.40.

return_value(reply_value)
Parameters:

reply_value (JavaScriptCore.Value) – Reply value of the provided script message

Reply to a script message with a value.

This function can be called twice for passing the reply value in.

New in version 2.40.

unref()

Atomically decrements the reference count of self by one.

If the reference count drops to 0, all the memory allocated by the WebKit.ScriptMessageReply is released. This function is MT-safe and may be called from any thread.

New in version 2.40.