runtime

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 7, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Rendered for js/wasm

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FuncConnect

func FuncConnect() (fn js.Func[func(extensionId js.String, connectInfo ConnectArgConnectInfo) Port])

FuncConnect returns the function "WEBEXT.runtime.connect".

func FuncConnectNative

func FuncConnectNative() (fn js.Func[func(application js.String) Port])

FuncConnectNative returns the function "WEBEXT.runtime.connectNative".

func FuncGetBackgroundPage

func FuncGetBackgroundPage() (fn js.Func[func() js.Promise[js.Any]])

FuncGetBackgroundPage returns the function "WEBEXT.runtime.getBackgroundPage".

func FuncGetContexts

func FuncGetContexts() (fn js.Func[func(filter ContextFilter) js.Promise[js.Array[ExtensionContext]]])

FuncGetContexts returns the function "WEBEXT.runtime.getContexts".

func FuncGetManifest

func FuncGetManifest() (fn js.Func[func() js.Any])

FuncGetManifest returns the function "WEBEXT.runtime.getManifest".

func FuncGetPackageDirectoryEntry

func FuncGetPackageDirectoryEntry() (fn js.Func[func(callback js.Func[func(directoryEntry js.Any)])])

FuncGetPackageDirectoryEntry returns the function "WEBEXT.runtime.getPackageDirectoryEntry".

func FuncGetPlatformInfo

func FuncGetPlatformInfo() (fn js.Func[func() js.Promise[PlatformInfo]])

FuncGetPlatformInfo returns the function "WEBEXT.runtime.getPlatformInfo".

func FuncGetURL

func FuncGetURL() (fn js.Func[func(path js.String) js.String])

FuncGetURL returns the function "WEBEXT.runtime.getURL".

func FuncHasOnBrowserUpdateAvailable

func FuncHasOnBrowserUpdateAvailable() (fn js.Func[func(callback js.Func[func()]) bool])

FuncHasOnBrowserUpdateAvailable returns the function "WEBEXT.runtime.onBrowserUpdateAvailable.hasListener".

func FuncHasOnConnect

func FuncHasOnConnect() (fn js.Func[func(callback js.Func[func(port *Port)]) bool])

FuncHasOnConnect returns the function "WEBEXT.runtime.onConnect.hasListener".

func FuncHasOnConnectExternal

func FuncHasOnConnectExternal() (fn js.Func[func(callback js.Func[func(port *Port)]) bool])

FuncHasOnConnectExternal returns the function "WEBEXT.runtime.onConnectExternal.hasListener".

func FuncHasOnConnectNative

func FuncHasOnConnectNative() (fn js.Func[func(callback js.Func[func(port *Port)]) bool])

FuncHasOnConnectNative returns the function "WEBEXT.runtime.onConnectNative.hasListener".

func FuncHasOnInstalled

func FuncHasOnInstalled() (fn js.Func[func(callback js.Func[func(details *OnInstalledArgDetails)]) bool])

FuncHasOnInstalled returns the function "WEBEXT.runtime.onInstalled.hasListener".

func FuncHasOnMessage

func FuncHasOnMessage() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) bool])

FuncHasOnMessage returns the function "WEBEXT.runtime.onMessage.hasListener".

func FuncHasOnMessageExternal

func FuncHasOnMessageExternal() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) bool])

FuncHasOnMessageExternal returns the function "WEBEXT.runtime.onMessageExternal.hasListener".

func FuncHasOnRestartRequired

func FuncHasOnRestartRequired() (fn js.Func[func(callback js.Func[func(reason OnRestartRequiredReason)]) bool])

FuncHasOnRestartRequired returns the function "WEBEXT.runtime.onRestartRequired.hasListener".

func FuncHasOnStartup

func FuncHasOnStartup() (fn js.Func[func(callback js.Func[func()]) bool])

FuncHasOnStartup returns the function "WEBEXT.runtime.onStartup.hasListener".

func FuncHasOnSuspend

func FuncHasOnSuspend() (fn js.Func[func(callback js.Func[func()]) bool])

FuncHasOnSuspend returns the function "WEBEXT.runtime.onSuspend.hasListener".

func FuncHasOnSuspendCanceled

func FuncHasOnSuspendCanceled() (fn js.Func[func(callback js.Func[func()]) bool])

FuncHasOnSuspendCanceled returns the function "WEBEXT.runtime.onSuspendCanceled.hasListener".

func FuncHasOnUpdateAvailable

func FuncHasOnUpdateAvailable() (fn js.Func[func(callback js.Func[func(details js.Any)]) bool])

FuncHasOnUpdateAvailable returns the function "WEBEXT.runtime.onUpdateAvailable.hasListener".

func FuncHasOnUserScriptConnect

func FuncHasOnUserScriptConnect() (fn js.Func[func(callback js.Func[func(port *Port)]) bool])

FuncHasOnUserScriptConnect returns the function "WEBEXT.runtime.onUserScriptConnect.hasListener".

func FuncHasOnUserScriptMessage

func FuncHasOnUserScriptMessage() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) bool])

FuncHasOnUserScriptMessage returns the function "WEBEXT.runtime.onUserScriptMessage.hasListener".

func FuncOffBrowserUpdateAvailable

func FuncOffBrowserUpdateAvailable() (fn js.Func[func(callback js.Func[func()])])

FuncOffBrowserUpdateAvailable returns the function "WEBEXT.runtime.onBrowserUpdateAvailable.removeListener".

func FuncOffConnect

func FuncOffConnect() (fn js.Func[func(callback js.Func[func(port *Port)])])

FuncOffConnect returns the function "WEBEXT.runtime.onConnect.removeListener".

func FuncOffConnectExternal

func FuncOffConnectExternal() (fn js.Func[func(callback js.Func[func(port *Port)])])

FuncOffConnectExternal returns the function "WEBEXT.runtime.onConnectExternal.removeListener".

func FuncOffConnectNative

func FuncOffConnectNative() (fn js.Func[func(callback js.Func[func(port *Port)])])

FuncOffConnectNative returns the function "WEBEXT.runtime.onConnectNative.removeListener".

func FuncOffInstalled

func FuncOffInstalled() (fn js.Func[func(callback js.Func[func(details *OnInstalledArgDetails)])])

FuncOffInstalled returns the function "WEBEXT.runtime.onInstalled.removeListener".

func FuncOffMessage

func FuncOffMessage() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool])])

FuncOffMessage returns the function "WEBEXT.runtime.onMessage.removeListener".

func FuncOffMessageExternal

func FuncOffMessageExternal() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool])])

FuncOffMessageExternal returns the function "WEBEXT.runtime.onMessageExternal.removeListener".

func FuncOffRestartRequired

func FuncOffRestartRequired() (fn js.Func[func(callback js.Func[func(reason OnRestartRequiredReason)])])

FuncOffRestartRequired returns the function "WEBEXT.runtime.onRestartRequired.removeListener".

func FuncOffStartup

func FuncOffStartup() (fn js.Func[func(callback js.Func[func()])])

FuncOffStartup returns the function "WEBEXT.runtime.onStartup.removeListener".

func FuncOffSuspend

func FuncOffSuspend() (fn js.Func[func(callback js.Func[func()])])

FuncOffSuspend returns the function "WEBEXT.runtime.onSuspend.removeListener".

func FuncOffSuspendCanceled

func FuncOffSuspendCanceled() (fn js.Func[func(callback js.Func[func()])])

FuncOffSuspendCanceled returns the function "WEBEXT.runtime.onSuspendCanceled.removeListener".

func FuncOffUpdateAvailable

func FuncOffUpdateAvailable() (fn js.Func[func(callback js.Func[func(details js.Any)])])

FuncOffUpdateAvailable returns the function "WEBEXT.runtime.onUpdateAvailable.removeListener".

func FuncOffUserScriptConnect

func FuncOffUserScriptConnect() (fn js.Func[func(callback js.Func[func(port *Port)])])

FuncOffUserScriptConnect returns the function "WEBEXT.runtime.onUserScriptConnect.removeListener".

func FuncOffUserScriptMessage

func FuncOffUserScriptMessage() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool])])

FuncOffUserScriptMessage returns the function "WEBEXT.runtime.onUserScriptMessage.removeListener".

func FuncOnBrowserUpdateAvailable

func FuncOnBrowserUpdateAvailable() (fn js.Func[func(callback js.Func[func()])])

FuncOnBrowserUpdateAvailable returns the function "WEBEXT.runtime.onBrowserUpdateAvailable.addListener".

func FuncOnConnect

func FuncOnConnect() (fn js.Func[func(callback js.Func[func(port *Port)])])

FuncOnConnect returns the function "WEBEXT.runtime.onConnect.addListener".

func FuncOnConnectExternal

func FuncOnConnectExternal() (fn js.Func[func(callback js.Func[func(port *Port)])])

FuncOnConnectExternal returns the function "WEBEXT.runtime.onConnectExternal.addListener".

func FuncOnConnectNative

func FuncOnConnectNative() (fn js.Func[func(callback js.Func[func(port *Port)])])

FuncOnConnectNative returns the function "WEBEXT.runtime.onConnectNative.addListener".

func FuncOnInstalled

func FuncOnInstalled() (fn js.Func[func(callback js.Func[func(details *OnInstalledArgDetails)])])

FuncOnInstalled returns the function "WEBEXT.runtime.onInstalled.addListener".

func FuncOnMessage

func FuncOnMessage() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool])])

FuncOnMessage returns the function "WEBEXT.runtime.onMessage.addListener".

func FuncOnMessageExternal

func FuncOnMessageExternal() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool])])

FuncOnMessageExternal returns the function "WEBEXT.runtime.onMessageExternal.addListener".

func FuncOnRestartRequired

func FuncOnRestartRequired() (fn js.Func[func(callback js.Func[func(reason OnRestartRequiredReason)])])

FuncOnRestartRequired returns the function "WEBEXT.runtime.onRestartRequired.addListener".

func FuncOnStartup

func FuncOnStartup() (fn js.Func[func(callback js.Func[func()])])

FuncOnStartup returns the function "WEBEXT.runtime.onStartup.addListener".

func FuncOnSuspend

func FuncOnSuspend() (fn js.Func[func(callback js.Func[func()])])

FuncOnSuspend returns the function "WEBEXT.runtime.onSuspend.addListener".

func FuncOnSuspendCanceled

func FuncOnSuspendCanceled() (fn js.Func[func(callback js.Func[func()])])

FuncOnSuspendCanceled returns the function "WEBEXT.runtime.onSuspendCanceled.addListener".

func FuncOnUpdateAvailable

func FuncOnUpdateAvailable() (fn js.Func[func(callback js.Func[func(details js.Any)])])

FuncOnUpdateAvailable returns the function "WEBEXT.runtime.onUpdateAvailable.addListener".

func FuncOnUserScriptConnect

func FuncOnUserScriptConnect() (fn js.Func[func(callback js.Func[func(port *Port)])])

FuncOnUserScriptConnect returns the function "WEBEXT.runtime.onUserScriptConnect.addListener".

func FuncOnUserScriptMessage

func FuncOnUserScriptMessage() (fn js.Func[func(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool])])

FuncOnUserScriptMessage returns the function "WEBEXT.runtime.onUserScriptMessage.addListener".

func FuncOpenOptionsPage

func FuncOpenOptionsPage() (fn js.Func[func() js.Promise[js.Void]])

FuncOpenOptionsPage returns the function "WEBEXT.runtime.openOptionsPage".

func FuncReload

func FuncReload() (fn js.Func[func()])

FuncReload returns the function "WEBEXT.runtime.reload".

func FuncRequestUpdateCheck

func FuncRequestUpdateCheck() (fn js.Func[func() js.Promise[RequestUpdateCheckReturnType]])

FuncRequestUpdateCheck returns the function "WEBEXT.runtime.requestUpdateCheck".

func FuncRestart

func FuncRestart() (fn js.Func[func()])

FuncRestart returns the function "WEBEXT.runtime.restart".

func FuncRestartAfterDelay

func FuncRestartAfterDelay() (fn js.Func[func(seconds int64) js.Promise[js.Void]])

FuncRestartAfterDelay returns the function "WEBEXT.runtime.restartAfterDelay".

func FuncSendMessage

func FuncSendMessage() (fn js.Func[func(extensionId js.String, message js.Any, options SendMessageArgOptions) js.Promise[js.Any]])

FuncSendMessage returns the function "WEBEXT.runtime.sendMessage".

func FuncSendNativeMessage

func FuncSendNativeMessage() (fn js.Func[func(application js.String, message js.Any) js.Promise[js.Any]])

FuncSendNativeMessage returns the function "WEBEXT.runtime.sendNativeMessage".

func FuncSetUninstallURL

func FuncSetUninstallURL() (fn js.Func[func(url js.String) js.Promise[js.Void]])

FuncSetUninstallURL returns the function "WEBEXT.runtime.setUninstallURL".

func GetBackgroundPage

func GetBackgroundPage() (ret js.Promise[js.Any])

GetBackgroundPage calls the function "WEBEXT.runtime.getBackgroundPage" directly.

func GetContexts

func GetContexts(filter ContextFilter) (ret js.Promise[js.Array[ExtensionContext]])

GetContexts calls the function "WEBEXT.runtime.getContexts" directly.

func GetManifest

func GetManifest() (ret js.Any)

GetManifest calls the function "WEBEXT.runtime.getManifest" directly.

func GetPackageDirectoryEntry

func GetPackageDirectoryEntry(callback js.Func[func(directoryEntry js.Any)]) (ret js.Void)

GetPackageDirectoryEntry calls the function "WEBEXT.runtime.getPackageDirectoryEntry" directly.

func GetPlatformInfo

func GetPlatformInfo() (ret js.Promise[PlatformInfo])

GetPlatformInfo calls the function "WEBEXT.runtime.getPlatformInfo" directly.

func GetURL

func GetURL(path js.String) (ret js.String)

GetURL calls the function "WEBEXT.runtime.getURL" directly.

func HasFuncConnect

func HasFuncConnect() bool

HasFuncConnect returns true if the function "WEBEXT.runtime.connect" exists.

func HasFuncConnectNative

func HasFuncConnectNative() bool

HasFuncConnectNative returns true if the function "WEBEXT.runtime.connectNative" exists.

func HasFuncGetBackgroundPage

func HasFuncGetBackgroundPage() bool

HasFuncGetBackgroundPage returns true if the function "WEBEXT.runtime.getBackgroundPage" exists.

func HasFuncGetContexts

func HasFuncGetContexts() bool

HasFuncGetContexts returns true if the function "WEBEXT.runtime.getContexts" exists.

func HasFuncGetManifest

func HasFuncGetManifest() bool

HasFuncGetManifest returns true if the function "WEBEXT.runtime.getManifest" exists.

func HasFuncGetPackageDirectoryEntry

func HasFuncGetPackageDirectoryEntry() bool

HasFuncGetPackageDirectoryEntry returns true if the function "WEBEXT.runtime.getPackageDirectoryEntry" exists.

func HasFuncGetPlatformInfo

func HasFuncGetPlatformInfo() bool

HasFuncGetPlatformInfo returns true if the function "WEBEXT.runtime.getPlatformInfo" exists.

func HasFuncGetURL

func HasFuncGetURL() bool

HasFuncGetURL returns true if the function "WEBEXT.runtime.getURL" exists.

func HasFuncHasOnBrowserUpdateAvailable

func HasFuncHasOnBrowserUpdateAvailable() bool

HasFuncHasOnBrowserUpdateAvailable returns true if the function "WEBEXT.runtime.onBrowserUpdateAvailable.hasListener" exists.

func HasFuncHasOnConnect

func HasFuncHasOnConnect() bool

HasFuncHasOnConnect returns true if the function "WEBEXT.runtime.onConnect.hasListener" exists.

func HasFuncHasOnConnectExternal

func HasFuncHasOnConnectExternal() bool

HasFuncHasOnConnectExternal returns true if the function "WEBEXT.runtime.onConnectExternal.hasListener" exists.

func HasFuncHasOnConnectNative

func HasFuncHasOnConnectNative() bool

HasFuncHasOnConnectNative returns true if the function "WEBEXT.runtime.onConnectNative.hasListener" exists.

func HasFuncHasOnInstalled

func HasFuncHasOnInstalled() bool

HasFuncHasOnInstalled returns true if the function "WEBEXT.runtime.onInstalled.hasListener" exists.

func HasFuncHasOnMessage

func HasFuncHasOnMessage() bool

HasFuncHasOnMessage returns true if the function "WEBEXT.runtime.onMessage.hasListener" exists.

func HasFuncHasOnMessageExternal

func HasFuncHasOnMessageExternal() bool

HasFuncHasOnMessageExternal returns true if the function "WEBEXT.runtime.onMessageExternal.hasListener" exists.

func HasFuncHasOnRestartRequired

func HasFuncHasOnRestartRequired() bool

HasFuncHasOnRestartRequired returns true if the function "WEBEXT.runtime.onRestartRequired.hasListener" exists.

func HasFuncHasOnStartup

func HasFuncHasOnStartup() bool

HasFuncHasOnStartup returns true if the function "WEBEXT.runtime.onStartup.hasListener" exists.

func HasFuncHasOnSuspend

func HasFuncHasOnSuspend() bool

HasFuncHasOnSuspend returns true if the function "WEBEXT.runtime.onSuspend.hasListener" exists.

func HasFuncHasOnSuspendCanceled

func HasFuncHasOnSuspendCanceled() bool

HasFuncHasOnSuspendCanceled returns true if the function "WEBEXT.runtime.onSuspendCanceled.hasListener" exists.

func HasFuncHasOnUpdateAvailable

func HasFuncHasOnUpdateAvailable() bool

HasFuncHasOnUpdateAvailable returns true if the function "WEBEXT.runtime.onUpdateAvailable.hasListener" exists.

func HasFuncHasOnUserScriptConnect

func HasFuncHasOnUserScriptConnect() bool

HasFuncHasOnUserScriptConnect returns true if the function "WEBEXT.runtime.onUserScriptConnect.hasListener" exists.

func HasFuncHasOnUserScriptMessage

func HasFuncHasOnUserScriptMessage() bool

HasFuncHasOnUserScriptMessage returns true if the function "WEBEXT.runtime.onUserScriptMessage.hasListener" exists.

func HasFuncOffBrowserUpdateAvailable

func HasFuncOffBrowserUpdateAvailable() bool

HasFuncOffBrowserUpdateAvailable returns true if the function "WEBEXT.runtime.onBrowserUpdateAvailable.removeListener" exists.

func HasFuncOffConnect

func HasFuncOffConnect() bool

HasFuncOffConnect returns true if the function "WEBEXT.runtime.onConnect.removeListener" exists.

func HasFuncOffConnectExternal

func HasFuncOffConnectExternal() bool

HasFuncOffConnectExternal returns true if the function "WEBEXT.runtime.onConnectExternal.removeListener" exists.

func HasFuncOffConnectNative

func HasFuncOffConnectNative() bool

HasFuncOffConnectNative returns true if the function "WEBEXT.runtime.onConnectNative.removeListener" exists.

func HasFuncOffInstalled

func HasFuncOffInstalled() bool

HasFuncOffInstalled returns true if the function "WEBEXT.runtime.onInstalled.removeListener" exists.

func HasFuncOffMessage

func HasFuncOffMessage() bool

HasFuncOffMessage returns true if the function "WEBEXT.runtime.onMessage.removeListener" exists.

func HasFuncOffMessageExternal

func HasFuncOffMessageExternal() bool

HasFuncOffMessageExternal returns true if the function "WEBEXT.runtime.onMessageExternal.removeListener" exists.

func HasFuncOffRestartRequired

func HasFuncOffRestartRequired() bool

HasFuncOffRestartRequired returns true if the function "WEBEXT.runtime.onRestartRequired.removeListener" exists.

func HasFuncOffStartup

func HasFuncOffStartup() bool

HasFuncOffStartup returns true if the function "WEBEXT.runtime.onStartup.removeListener" exists.

func HasFuncOffSuspend

func HasFuncOffSuspend() bool

HasFuncOffSuspend returns true if the function "WEBEXT.runtime.onSuspend.removeListener" exists.

func HasFuncOffSuspendCanceled

func HasFuncOffSuspendCanceled() bool

HasFuncOffSuspendCanceled returns true if the function "WEBEXT.runtime.onSuspendCanceled.removeListener" exists.

func HasFuncOffUpdateAvailable

func HasFuncOffUpdateAvailable() bool

HasFuncOffUpdateAvailable returns true if the function "WEBEXT.runtime.onUpdateAvailable.removeListener" exists.

func HasFuncOffUserScriptConnect

func HasFuncOffUserScriptConnect() bool

HasFuncOffUserScriptConnect returns true if the function "WEBEXT.runtime.onUserScriptConnect.removeListener" exists.

func HasFuncOffUserScriptMessage

func HasFuncOffUserScriptMessage() bool

HasFuncOffUserScriptMessage returns true if the function "WEBEXT.runtime.onUserScriptMessage.removeListener" exists.

func HasFuncOnBrowserUpdateAvailable

func HasFuncOnBrowserUpdateAvailable() bool

HasFuncOnBrowserUpdateAvailable returns true if the function "WEBEXT.runtime.onBrowserUpdateAvailable.addListener" exists.

func HasFuncOnConnect

func HasFuncOnConnect() bool

HasFuncOnConnect returns true if the function "WEBEXT.runtime.onConnect.addListener" exists.

func HasFuncOnConnectExternal

func HasFuncOnConnectExternal() bool

HasFuncOnConnectExternal returns true if the function "WEBEXT.runtime.onConnectExternal.addListener" exists.

func HasFuncOnConnectNative

func HasFuncOnConnectNative() bool

HasFuncOnConnectNative returns true if the function "WEBEXT.runtime.onConnectNative.addListener" exists.

func HasFuncOnInstalled

func HasFuncOnInstalled() bool

HasFuncOnInstalled returns true if the function "WEBEXT.runtime.onInstalled.addListener" exists.

func HasFuncOnMessage

func HasFuncOnMessage() bool

HasFuncOnMessage returns true if the function "WEBEXT.runtime.onMessage.addListener" exists.

func HasFuncOnMessageExternal

func HasFuncOnMessageExternal() bool

HasFuncOnMessageExternal returns true if the function "WEBEXT.runtime.onMessageExternal.addListener" exists.

func HasFuncOnRestartRequired

func HasFuncOnRestartRequired() bool

HasFuncOnRestartRequired returns true if the function "WEBEXT.runtime.onRestartRequired.addListener" exists.

func HasFuncOnStartup

func HasFuncOnStartup() bool

HasFuncOnStartup returns true if the function "WEBEXT.runtime.onStartup.addListener" exists.

func HasFuncOnSuspend

func HasFuncOnSuspend() bool

HasFuncOnSuspend returns true if the function "WEBEXT.runtime.onSuspend.addListener" exists.

func HasFuncOnSuspendCanceled

func HasFuncOnSuspendCanceled() bool

HasFuncOnSuspendCanceled returns true if the function "WEBEXT.runtime.onSuspendCanceled.addListener" exists.

func HasFuncOnUpdateAvailable

func HasFuncOnUpdateAvailable() bool

HasFuncOnUpdateAvailable returns true if the function "WEBEXT.runtime.onUpdateAvailable.addListener" exists.

func HasFuncOnUserScriptConnect

func HasFuncOnUserScriptConnect() bool

HasFuncOnUserScriptConnect returns true if the function "WEBEXT.runtime.onUserScriptConnect.addListener" exists.

func HasFuncOnUserScriptMessage

func HasFuncOnUserScriptMessage() bool

HasFuncOnUserScriptMessage returns true if the function "WEBEXT.runtime.onUserScriptMessage.addListener" exists.

func HasFuncOpenOptionsPage

func HasFuncOpenOptionsPage() bool

HasFuncOpenOptionsPage returns true if the function "WEBEXT.runtime.openOptionsPage" exists.

func HasFuncReload

func HasFuncReload() bool

HasFuncReload returns true if the function "WEBEXT.runtime.reload" exists.

func HasFuncRequestUpdateCheck

func HasFuncRequestUpdateCheck() bool

HasFuncRequestUpdateCheck returns true if the function "WEBEXT.runtime.requestUpdateCheck" exists.

func HasFuncRestart

func HasFuncRestart() bool

HasFuncRestart returns true if the function "WEBEXT.runtime.restart" exists.

func HasFuncRestartAfterDelay

func HasFuncRestartAfterDelay() bool

HasFuncRestartAfterDelay returns true if the function "WEBEXT.runtime.restartAfterDelay" exists.

func HasFuncSendMessage

func HasFuncSendMessage() bool

HasFuncSendMessage returns true if the function "WEBEXT.runtime.sendMessage" exists.

func HasFuncSendNativeMessage

func HasFuncSendNativeMessage() bool

HasFuncSendNativeMessage returns true if the function "WEBEXT.runtime.sendNativeMessage" exists.

func HasFuncSetUninstallURL

func HasFuncSetUninstallURL() bool

HasFuncSetUninstallURL returns true if the function "WEBEXT.runtime.setUninstallURL" exists.

func HasOnBrowserUpdateAvailable

func HasOnBrowserUpdateAvailable(callback js.Func[func()]) (ret bool)

HasOnBrowserUpdateAvailable calls the function "WEBEXT.runtime.onBrowserUpdateAvailable.hasListener" directly.

func HasOnConnect

func HasOnConnect(callback js.Func[func(port *Port)]) (ret bool)

HasOnConnect calls the function "WEBEXT.runtime.onConnect.hasListener" directly.

func HasOnConnectExternal

func HasOnConnectExternal(callback js.Func[func(port *Port)]) (ret bool)

HasOnConnectExternal calls the function "WEBEXT.runtime.onConnectExternal.hasListener" directly.

func HasOnConnectNative

func HasOnConnectNative(callback js.Func[func(port *Port)]) (ret bool)

HasOnConnectNative calls the function "WEBEXT.runtime.onConnectNative.hasListener" directly.

func HasOnInstalled

func HasOnInstalled(callback js.Func[func(details *OnInstalledArgDetails)]) (ret bool)

HasOnInstalled calls the function "WEBEXT.runtime.onInstalled.hasListener" directly.

func HasOnMessage

func HasOnMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret bool)

HasOnMessage calls the function "WEBEXT.runtime.onMessage.hasListener" directly.

func HasOnMessageExternal

func HasOnMessageExternal(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret bool)

HasOnMessageExternal calls the function "WEBEXT.runtime.onMessageExternal.hasListener" directly.

func HasOnRestartRequired

func HasOnRestartRequired(callback js.Func[func(reason OnRestartRequiredReason)]) (ret bool)

HasOnRestartRequired calls the function "WEBEXT.runtime.onRestartRequired.hasListener" directly.

func HasOnStartup

func HasOnStartup(callback js.Func[func()]) (ret bool)

HasOnStartup calls the function "WEBEXT.runtime.onStartup.hasListener" directly.

func HasOnSuspend

func HasOnSuspend(callback js.Func[func()]) (ret bool)

HasOnSuspend calls the function "WEBEXT.runtime.onSuspend.hasListener" directly.

func HasOnSuspendCanceled

func HasOnSuspendCanceled(callback js.Func[func()]) (ret bool)

HasOnSuspendCanceled calls the function "WEBEXT.runtime.onSuspendCanceled.hasListener" directly.

func HasOnUpdateAvailable

func HasOnUpdateAvailable(callback js.Func[func(details js.Any)]) (ret bool)

HasOnUpdateAvailable calls the function "WEBEXT.runtime.onUpdateAvailable.hasListener" directly.

func HasOnUserScriptConnect

func HasOnUserScriptConnect(callback js.Func[func(port *Port)]) (ret bool)

HasOnUserScriptConnect calls the function "WEBEXT.runtime.onUserScriptConnect.hasListener" directly.

func HasOnUserScriptMessage

func HasOnUserScriptMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret bool)

HasOnUserScriptMessage calls the function "WEBEXT.runtime.onUserScriptMessage.hasListener" directly.

func Id

func Id() (ret js.String, ok bool)

Id returns the value of property "WEBEXT.runtime.id".

The returned bool will be false if there is no such property.

func OffBrowserUpdateAvailable

func OffBrowserUpdateAvailable(callback js.Func[func()]) (ret js.Void)

OffBrowserUpdateAvailable calls the function "WEBEXT.runtime.onBrowserUpdateAvailable.removeListener" directly.

func OffConnect

func OffConnect(callback js.Func[func(port *Port)]) (ret js.Void)

OffConnect calls the function "WEBEXT.runtime.onConnect.removeListener" directly.

func OffConnectExternal

func OffConnectExternal(callback js.Func[func(port *Port)]) (ret js.Void)

OffConnectExternal calls the function "WEBEXT.runtime.onConnectExternal.removeListener" directly.

func OffConnectNative

func OffConnectNative(callback js.Func[func(port *Port)]) (ret js.Void)

OffConnectNative calls the function "WEBEXT.runtime.onConnectNative.removeListener" directly.

func OffInstalled

func OffInstalled(callback js.Func[func(details *OnInstalledArgDetails)]) (ret js.Void)

OffInstalled calls the function "WEBEXT.runtime.onInstalled.removeListener" directly.

func OffMessage

func OffMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void)

OffMessage calls the function "WEBEXT.runtime.onMessage.removeListener" directly.

func OffMessageExternal

func OffMessageExternal(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void)

OffMessageExternal calls the function "WEBEXT.runtime.onMessageExternal.removeListener" directly.

func OffRestartRequired

func OffRestartRequired(callback js.Func[func(reason OnRestartRequiredReason)]) (ret js.Void)

OffRestartRequired calls the function "WEBEXT.runtime.onRestartRequired.removeListener" directly.

func OffStartup

func OffStartup(callback js.Func[func()]) (ret js.Void)

OffStartup calls the function "WEBEXT.runtime.onStartup.removeListener" directly.

func OffSuspend

func OffSuspend(callback js.Func[func()]) (ret js.Void)

OffSuspend calls the function "WEBEXT.runtime.onSuspend.removeListener" directly.

func OffSuspendCanceled

func OffSuspendCanceled(callback js.Func[func()]) (ret js.Void)

OffSuspendCanceled calls the function "WEBEXT.runtime.onSuspendCanceled.removeListener" directly.

func OffUpdateAvailable

func OffUpdateAvailable(callback js.Func[func(details js.Any)]) (ret js.Void)

OffUpdateAvailable calls the function "WEBEXT.runtime.onUpdateAvailable.removeListener" directly.

func OffUserScriptConnect

func OffUserScriptConnect(callback js.Func[func(port *Port)]) (ret js.Void)

OffUserScriptConnect calls the function "WEBEXT.runtime.onUserScriptConnect.removeListener" directly.

func OffUserScriptMessage

func OffUserScriptMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void)

OffUserScriptMessage calls the function "WEBEXT.runtime.onUserScriptMessage.removeListener" directly.

func OnBrowserUpdateAvailable

func OnBrowserUpdateAvailable(callback js.Func[func()]) (ret js.Void)

OnBrowserUpdateAvailable calls the function "WEBEXT.runtime.onBrowserUpdateAvailable.addListener" directly.

func OnConnect

func OnConnect(callback js.Func[func(port *Port)]) (ret js.Void)

OnConnect calls the function "WEBEXT.runtime.onConnect.addListener" directly.

func OnConnectExternal

func OnConnectExternal(callback js.Func[func(port *Port)]) (ret js.Void)

OnConnectExternal calls the function "WEBEXT.runtime.onConnectExternal.addListener" directly.

func OnConnectNative

func OnConnectNative(callback js.Func[func(port *Port)]) (ret js.Void)

OnConnectNative calls the function "WEBEXT.runtime.onConnectNative.addListener" directly.

func OnInstalled

func OnInstalled(callback js.Func[func(details *OnInstalledArgDetails)]) (ret js.Void)

OnInstalled calls the function "WEBEXT.runtime.onInstalled.addListener" directly.

func OnMessage

func OnMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void)

OnMessage calls the function "WEBEXT.runtime.onMessage.addListener" directly.

func OnMessageExternal

func OnMessageExternal(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void)

OnMessageExternal calls the function "WEBEXT.runtime.onMessageExternal.addListener" directly.

func OnRestartRequired

func OnRestartRequired(callback js.Func[func(reason OnRestartRequiredReason)]) (ret js.Void)

OnRestartRequired calls the function "WEBEXT.runtime.onRestartRequired.addListener" directly.

func OnStartup

func OnStartup(callback js.Func[func()]) (ret js.Void)

OnStartup calls the function "WEBEXT.runtime.onStartup.addListener" directly.

func OnSuspend

func OnSuspend(callback js.Func[func()]) (ret js.Void)

OnSuspend calls the function "WEBEXT.runtime.onSuspend.addListener" directly.

func OnSuspendCanceled

func OnSuspendCanceled(callback js.Func[func()]) (ret js.Void)

OnSuspendCanceled calls the function "WEBEXT.runtime.onSuspendCanceled.addListener" directly.

func OnUpdateAvailable

func OnUpdateAvailable(callback js.Func[func(details js.Any)]) (ret js.Void)

OnUpdateAvailable calls the function "WEBEXT.runtime.onUpdateAvailable.addListener" directly.

func OnUserScriptConnect

func OnUserScriptConnect(callback js.Func[func(port *Port)]) (ret js.Void)

OnUserScriptConnect calls the function "WEBEXT.runtime.onUserScriptConnect.addListener" directly.

func OnUserScriptMessage

func OnUserScriptMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void)

OnUserScriptMessage calls the function "WEBEXT.runtime.onUserScriptMessage.addListener" directly.

func OpenOptionsPage

func OpenOptionsPage() (ret js.Promise[js.Void])

OpenOptionsPage calls the function "WEBEXT.runtime.openOptionsPage" directly.

func Reload

func Reload() (ret js.Void)

Reload calls the function "WEBEXT.runtime.reload" directly.

func RequestUpdateCheck

func RequestUpdateCheck() (ret js.Promise[RequestUpdateCheckReturnType])

RequestUpdateCheck calls the function "WEBEXT.runtime.requestUpdateCheck" directly.

func Restart

func Restart() (ret js.Void)

Restart calls the function "WEBEXT.runtime.restart" directly.

func RestartAfterDelay

func RestartAfterDelay(seconds int64) (ret js.Promise[js.Void])

RestartAfterDelay calls the function "WEBEXT.runtime.restartAfterDelay" directly.

func SendMessage

func SendMessage(extensionId js.String, message js.Any, options SendMessageArgOptions) (ret js.Promise[js.Any])

SendMessage calls the function "WEBEXT.runtime.sendMessage" directly.

func SendNativeMessage

func SendNativeMessage(application js.String, message js.Any) (ret js.Promise[js.Any])

SendNativeMessage calls the function "WEBEXT.runtime.sendNativeMessage" directly.

func SetId

func SetId(val js.String) bool

SetId sets the value of property "WEBEXT.runtime.id" to val.

It returns false if the property cannot be set.

func SetLastError

func SetLastError(val LastErrorProperty) bool

SetLastError sets the value of property "WEBEXT.runtime.lastError" to val.

It returns false if the property cannot be set.

func SetUninstallURL

func SetUninstallURL(url js.String) (ret js.Promise[js.Void])

SetUninstallURL calls the function "WEBEXT.runtime.setUninstallURL" directly.

func TryGetBackgroundPage

func TryGetBackgroundPage() (ret js.Promise[js.Any], exception js.Any, ok bool)

TryGetBackgroundPage calls the function "WEBEXT.runtime.getBackgroundPage" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryGetContexts

func TryGetContexts(filter ContextFilter) (ret js.Promise[js.Array[ExtensionContext]], exception js.Any, ok bool)

TryGetContexts calls the function "WEBEXT.runtime.getContexts" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryGetManifest

func TryGetManifest() (ret js.Any, exception js.Any, ok bool)

TryGetManifest calls the function "WEBEXT.runtime.getManifest" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryGetPackageDirectoryEntry

func TryGetPackageDirectoryEntry(callback js.Func[func(directoryEntry js.Any)]) (ret js.Void, exception js.Any, ok bool)

TryGetPackageDirectoryEntry calls the function "WEBEXT.runtime.getPackageDirectoryEntry" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryGetPlatformInfo

func TryGetPlatformInfo() (ret js.Promise[PlatformInfo], exception js.Any, ok bool)

TryGetPlatformInfo calls the function "WEBEXT.runtime.getPlatformInfo" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryGetURL

func TryGetURL(path js.String) (ret js.String, exception js.Any, ok bool)

TryGetURL calls the function "WEBEXT.runtime.getURL" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnBrowserUpdateAvailable

func TryHasOnBrowserUpdateAvailable(callback js.Func[func()]) (ret bool, exception js.Any, ok bool)

TryHasOnBrowserUpdateAvailable calls the function "WEBEXT.runtime.onBrowserUpdateAvailable.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnConnect

func TryHasOnConnect(callback js.Func[func(port *Port)]) (ret bool, exception js.Any, ok bool)

TryHasOnConnect calls the function "WEBEXT.runtime.onConnect.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnConnectExternal

func TryHasOnConnectExternal(callback js.Func[func(port *Port)]) (ret bool, exception js.Any, ok bool)

TryHasOnConnectExternal calls the function "WEBEXT.runtime.onConnectExternal.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnConnectNative

func TryHasOnConnectNative(callback js.Func[func(port *Port)]) (ret bool, exception js.Any, ok bool)

TryHasOnConnectNative calls the function "WEBEXT.runtime.onConnectNative.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnInstalled

func TryHasOnInstalled(callback js.Func[func(details *OnInstalledArgDetails)]) (ret bool, exception js.Any, ok bool)

TryHasOnInstalled calls the function "WEBEXT.runtime.onInstalled.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnMessage

func TryHasOnMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret bool, exception js.Any, ok bool)

TryHasOnMessage calls the function "WEBEXT.runtime.onMessage.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnMessageExternal

func TryHasOnMessageExternal(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret bool, exception js.Any, ok bool)

TryHasOnMessageExternal calls the function "WEBEXT.runtime.onMessageExternal.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnRestartRequired

func TryHasOnRestartRequired(callback js.Func[func(reason OnRestartRequiredReason)]) (ret bool, exception js.Any, ok bool)

TryHasOnRestartRequired calls the function "WEBEXT.runtime.onRestartRequired.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnStartup

func TryHasOnStartup(callback js.Func[func()]) (ret bool, exception js.Any, ok bool)

TryHasOnStartup calls the function "WEBEXT.runtime.onStartup.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnSuspend

func TryHasOnSuspend(callback js.Func[func()]) (ret bool, exception js.Any, ok bool)

TryHasOnSuspend calls the function "WEBEXT.runtime.onSuspend.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnSuspendCanceled

func TryHasOnSuspendCanceled(callback js.Func[func()]) (ret bool, exception js.Any, ok bool)

TryHasOnSuspendCanceled calls the function "WEBEXT.runtime.onSuspendCanceled.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnUpdateAvailable

func TryHasOnUpdateAvailable(callback js.Func[func(details js.Any)]) (ret bool, exception js.Any, ok bool)

TryHasOnUpdateAvailable calls the function "WEBEXT.runtime.onUpdateAvailable.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnUserScriptConnect

func TryHasOnUserScriptConnect(callback js.Func[func(port *Port)]) (ret bool, exception js.Any, ok bool)

TryHasOnUserScriptConnect calls the function "WEBEXT.runtime.onUserScriptConnect.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryHasOnUserScriptMessage

func TryHasOnUserScriptMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret bool, exception js.Any, ok bool)

TryHasOnUserScriptMessage calls the function "WEBEXT.runtime.onUserScriptMessage.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffBrowserUpdateAvailable

func TryOffBrowserUpdateAvailable(callback js.Func[func()]) (ret js.Void, exception js.Any, ok bool)

TryOffBrowserUpdateAvailable calls the function "WEBEXT.runtime.onBrowserUpdateAvailable.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffConnect

func TryOffConnect(callback js.Func[func(port *Port)]) (ret js.Void, exception js.Any, ok bool)

TryOffConnect calls the function "WEBEXT.runtime.onConnect.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffConnectExternal

func TryOffConnectExternal(callback js.Func[func(port *Port)]) (ret js.Void, exception js.Any, ok bool)

TryOffConnectExternal calls the function "WEBEXT.runtime.onConnectExternal.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffConnectNative

func TryOffConnectNative(callback js.Func[func(port *Port)]) (ret js.Void, exception js.Any, ok bool)

TryOffConnectNative calls the function "WEBEXT.runtime.onConnectNative.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffInstalled

func TryOffInstalled(callback js.Func[func(details *OnInstalledArgDetails)]) (ret js.Void, exception js.Any, ok bool)

TryOffInstalled calls the function "WEBEXT.runtime.onInstalled.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffMessage

func TryOffMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void, exception js.Any, ok bool)

TryOffMessage calls the function "WEBEXT.runtime.onMessage.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffMessageExternal

func TryOffMessageExternal(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void, exception js.Any, ok bool)

TryOffMessageExternal calls the function "WEBEXT.runtime.onMessageExternal.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffRestartRequired

func TryOffRestartRequired(callback js.Func[func(reason OnRestartRequiredReason)]) (ret js.Void, exception js.Any, ok bool)

TryOffRestartRequired calls the function "WEBEXT.runtime.onRestartRequired.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffStartup

func TryOffStartup(callback js.Func[func()]) (ret js.Void, exception js.Any, ok bool)

TryOffStartup calls the function "WEBEXT.runtime.onStartup.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffSuspend

func TryOffSuspend(callback js.Func[func()]) (ret js.Void, exception js.Any, ok bool)

TryOffSuspend calls the function "WEBEXT.runtime.onSuspend.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffSuspendCanceled

func TryOffSuspendCanceled(callback js.Func[func()]) (ret js.Void, exception js.Any, ok bool)

TryOffSuspendCanceled calls the function "WEBEXT.runtime.onSuspendCanceled.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffUpdateAvailable

func TryOffUpdateAvailable(callback js.Func[func(details js.Any)]) (ret js.Void, exception js.Any, ok bool)

TryOffUpdateAvailable calls the function "WEBEXT.runtime.onUpdateAvailable.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffUserScriptConnect

func TryOffUserScriptConnect(callback js.Func[func(port *Port)]) (ret js.Void, exception js.Any, ok bool)

TryOffUserScriptConnect calls the function "WEBEXT.runtime.onUserScriptConnect.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOffUserScriptMessage

func TryOffUserScriptMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void, exception js.Any, ok bool)

TryOffUserScriptMessage calls the function "WEBEXT.runtime.onUserScriptMessage.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnBrowserUpdateAvailable

func TryOnBrowserUpdateAvailable(callback js.Func[func()]) (ret js.Void, exception js.Any, ok bool)

TryOnBrowserUpdateAvailable calls the function "WEBEXT.runtime.onBrowserUpdateAvailable.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnConnect

func TryOnConnect(callback js.Func[func(port *Port)]) (ret js.Void, exception js.Any, ok bool)

TryOnConnect calls the function "WEBEXT.runtime.onConnect.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnConnectExternal

func TryOnConnectExternal(callback js.Func[func(port *Port)]) (ret js.Void, exception js.Any, ok bool)

TryOnConnectExternal calls the function "WEBEXT.runtime.onConnectExternal.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnConnectNative

func TryOnConnectNative(callback js.Func[func(port *Port)]) (ret js.Void, exception js.Any, ok bool)

TryOnConnectNative calls the function "WEBEXT.runtime.onConnectNative.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnInstalled

func TryOnInstalled(callback js.Func[func(details *OnInstalledArgDetails)]) (ret js.Void, exception js.Any, ok bool)

TryOnInstalled calls the function "WEBEXT.runtime.onInstalled.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnMessage

func TryOnMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void, exception js.Any, ok bool)

TryOnMessage calls the function "WEBEXT.runtime.onMessage.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnMessageExternal

func TryOnMessageExternal(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void, exception js.Any, ok bool)

TryOnMessageExternal calls the function "WEBEXT.runtime.onMessageExternal.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnRestartRequired

func TryOnRestartRequired(callback js.Func[func(reason OnRestartRequiredReason)]) (ret js.Void, exception js.Any, ok bool)

TryOnRestartRequired calls the function "WEBEXT.runtime.onRestartRequired.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnStartup

func TryOnStartup(callback js.Func[func()]) (ret js.Void, exception js.Any, ok bool)

TryOnStartup calls the function "WEBEXT.runtime.onStartup.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnSuspend

func TryOnSuspend(callback js.Func[func()]) (ret js.Void, exception js.Any, ok bool)

TryOnSuspend calls the function "WEBEXT.runtime.onSuspend.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnSuspendCanceled

func TryOnSuspendCanceled(callback js.Func[func()]) (ret js.Void, exception js.Any, ok bool)

TryOnSuspendCanceled calls the function "WEBEXT.runtime.onSuspendCanceled.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnUpdateAvailable

func TryOnUpdateAvailable(callback js.Func[func(details js.Any)]) (ret js.Void, exception js.Any, ok bool)

TryOnUpdateAvailable calls the function "WEBEXT.runtime.onUpdateAvailable.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnUserScriptConnect

func TryOnUserScriptConnect(callback js.Func[func(port *Port)]) (ret js.Void, exception js.Any, ok bool)

TryOnUserScriptConnect calls the function "WEBEXT.runtime.onUserScriptConnect.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOnUserScriptMessage

func TryOnUserScriptMessage(callback js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]) (ret js.Void, exception js.Any, ok bool)

TryOnUserScriptMessage calls the function "WEBEXT.runtime.onUserScriptMessage.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryOpenOptionsPage

func TryOpenOptionsPage() (ret js.Promise[js.Void], exception js.Any, ok bool)

TryOpenOptionsPage calls the function "WEBEXT.runtime.openOptionsPage" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryReload

func TryReload() (ret js.Void, exception js.Any, ok bool)

TryReload calls the function "WEBEXT.runtime.reload" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryRequestUpdateCheck

func TryRequestUpdateCheck() (ret js.Promise[RequestUpdateCheckReturnType], exception js.Any, ok bool)

TryRequestUpdateCheck calls the function "WEBEXT.runtime.requestUpdateCheck" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryRestart

func TryRestart() (ret js.Void, exception js.Any, ok bool)

TryRestart calls the function "WEBEXT.runtime.restart" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryRestartAfterDelay

func TryRestartAfterDelay(seconds int64) (ret js.Promise[js.Void], exception js.Any, ok bool)

TryRestartAfterDelay calls the function "WEBEXT.runtime.restartAfterDelay" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TrySendMessage

func TrySendMessage(extensionId js.String, message js.Any, options SendMessageArgOptions) (ret js.Promise[js.Any], exception js.Any, ok bool)

TrySendMessage calls the function "WEBEXT.runtime.sendMessage" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TrySendNativeMessage

func TrySendNativeMessage(application js.String, message js.Any) (ret js.Promise[js.Any], exception js.Any, ok bool)

TrySendNativeMessage calls the function "WEBEXT.runtime.sendNativeMessage" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TrySetUninstallURL

func TrySetUninstallURL(url js.String) (ret js.Promise[js.Void], exception js.Any, ok bool)

TrySetUninstallURL calls the function "WEBEXT.runtime.setUninstallURL" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

Types

type ConnectArgConnectInfo

type ConnectArgConnectInfo struct {
	// IncludeTlsChannelId is "ConnectArgConnectInfo.includeTlsChannelId"
	//
	// Optional
	//
	// NOTE: FFI_USE_IncludeTlsChannelId MUST be set to true to make this field effective.
	IncludeTlsChannelId bool
	// Name is "ConnectArgConnectInfo.name"
	//
	// Optional
	Name js.String

	FFI_USE_IncludeTlsChannelId bool // for IncludeTlsChannelId.

	FFI_USE bool
}

func (*ConnectArgConnectInfo) FreeMembers

func (p *ConnectArgConnectInfo) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (ConnectArgConnectInfo) FromRef

FromRef calls UpdateFrom and returns a ConnectArgConnectInfo with all fields set.

func (ConnectArgConnectInfo) New

func (p ConnectArgConnectInfo) New() js.Ref

New creates a new ConnectArgConnectInfo in the application heap.

func (*ConnectArgConnectInfo) Update

func (p *ConnectArgConnectInfo) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*ConnectArgConnectInfo) UpdateFrom

func (p *ConnectArgConnectInfo) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type ContextFilter

type ContextFilter struct {
	// ContextIds is "ContextFilter.contextIds"
	//
	// Optional
	ContextIds js.Array[js.String]
	// ContextTypes is "ContextFilter.contextTypes"
	//
	// Optional
	ContextTypes js.Array[ContextType]
	// DocumentIds is "ContextFilter.documentIds"
	//
	// Optional
	DocumentIds js.Array[js.String]
	// DocumentOrigins is "ContextFilter.documentOrigins"
	//
	// Optional
	DocumentOrigins js.Array[js.String]
	// DocumentUrls is "ContextFilter.documentUrls"
	//
	// Optional
	DocumentUrls js.Array[js.String]
	// FrameIds is "ContextFilter.frameIds"
	//
	// Optional
	FrameIds js.Array[int64]
	// Incognito is "ContextFilter.incognito"
	//
	// Optional
	//
	// NOTE: FFI_USE_Incognito MUST be set to true to make this field effective.
	Incognito bool
	// TabIds is "ContextFilter.tabIds"
	//
	// Optional
	TabIds js.Array[int64]
	// WindowIds is "ContextFilter.windowIds"
	//
	// Optional
	WindowIds js.Array[int64]

	FFI_USE_Incognito bool // for Incognito.

	FFI_USE bool
}

func (*ContextFilter) FreeMembers

func (p *ContextFilter) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (ContextFilter) FromRef

func (p ContextFilter) FromRef(ref js.Ref) ContextFilter

FromRef calls UpdateFrom and returns a ContextFilter with all fields set.

func (ContextFilter) New

func (p ContextFilter) New() js.Ref

New creates a new ContextFilter in the application heap.

func (*ContextFilter) Update

func (p *ContextFilter) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*ContextFilter) UpdateFrom

func (p *ContextFilter) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type ContextType

type ContextType uint32
const (
	ContextType_TAB ContextType
	ContextType_POPUP
	ContextType_BACKGROUND
	ContextType_OFFSCREEN_DOCUMENT
	ContextType_SIDE_PANEL
)

func (ContextType) FromRef

func (ContextType) FromRef(str js.Ref) ContextType

func (ContextType) String

func (x ContextType) String() (string, bool)

type ExtensionContext

type ExtensionContext struct {
	// ContextId is "ExtensionContext.contextId"
	//
	// Required
	ContextId js.String
	// ContextType is "ExtensionContext.contextType"
	//
	// Required
	ContextType ContextType
	// DocumentId is "ExtensionContext.documentId"
	//
	// Optional
	DocumentId js.String
	// DocumentOrigin is "ExtensionContext.documentOrigin"
	//
	// Optional
	DocumentOrigin js.String
	// DocumentUrl is "ExtensionContext.documentUrl"
	//
	// Optional
	DocumentUrl js.String
	// FrameId is "ExtensionContext.frameId"
	//
	// Required
	FrameId int64
	// Incognito is "ExtensionContext.incognito"
	//
	// Required
	Incognito bool
	// TabId is "ExtensionContext.tabId"
	//
	// Required
	TabId int64
	// WindowId is "ExtensionContext.windowId"
	//
	// Required
	WindowId int64

	FFI_USE bool
}

func (*ExtensionContext) FreeMembers

func (p *ExtensionContext) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (ExtensionContext) FromRef

func (p ExtensionContext) FromRef(ref js.Ref) ExtensionContext

FromRef calls UpdateFrom and returns a ExtensionContext with all fields set.

func (ExtensionContext) New

func (p ExtensionContext) New() js.Ref

New creates a new ExtensionContext in the application heap.

func (*ExtensionContext) Update

func (p *ExtensionContext) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*ExtensionContext) UpdateFrom

func (p *ExtensionContext) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type GetPackageDirectoryEntryArgCallback

type GetPackageDirectoryEntryArgCallback[T any] struct {
	Fn  func(arg T, this js.Ref, directoryEntry js.Any) js.Ref
	Arg T
}

func (*GetPackageDirectoryEntryArgCallback[T]) DispatchCallback

func (cb *GetPackageDirectoryEntryArgCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*GetPackageDirectoryEntryArgCallback[T]) Register

func (cb *GetPackageDirectoryEntryArgCallback[T]) Register() js.Func[func(directoryEntry js.Any)]

type GetPackageDirectoryEntryArgCallbackFunc

type GetPackageDirectoryEntryArgCallbackFunc func(this js.Ref, directoryEntry js.Any) js.Ref

func (GetPackageDirectoryEntryArgCallbackFunc) DispatchCallback

func (fn GetPackageDirectoryEntryArgCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (GetPackageDirectoryEntryArgCallbackFunc) Register

func (fn GetPackageDirectoryEntryArgCallbackFunc) Register() js.Func[func(directoryEntry js.Any)]

type LastErrorProperty

type LastErrorProperty struct {
	// Message is "LastErrorProperty.message"
	//
	// Optional
	Message js.String

	FFI_USE bool
}

func LastError

func LastError() (ret LastErrorProperty, ok bool)

LastError returns the value of property "WEBEXT.runtime.lastError".

The returned bool will be false if there is no such property.

func (*LastErrorProperty) FreeMembers

func (p *LastErrorProperty) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (LastErrorProperty) FromRef

func (p LastErrorProperty) FromRef(ref js.Ref) LastErrorProperty

FromRef calls UpdateFrom and returns a LastErrorProperty with all fields set.

func (LastErrorProperty) New

func (p LastErrorProperty) New() js.Ref

New creates a new LastErrorProperty in the application heap.

func (*LastErrorProperty) Update

func (p *LastErrorProperty) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*LastErrorProperty) UpdateFrom

func (p *LastErrorProperty) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type MessageSender

type MessageSender struct {
	// DocumentId is "MessageSender.documentId"
	//
	// Optional
	DocumentId js.String
	// DocumentLifecycle is "MessageSender.documentLifecycle"
	//
	// Optional
	DocumentLifecycle js.String
	// FrameId is "MessageSender.frameId"
	//
	// Optional
	//
	// NOTE: FFI_USE_FrameId MUST be set to true to make this field effective.
	FrameId int64
	// GuestProcessId is "MessageSender.guestProcessId"
	//
	// Optional
	//
	// NOTE: FFI_USE_GuestProcessId MUST be set to true to make this field effective.
	GuestProcessId int64
	// GuestRenderFrameRoutingId is "MessageSender.guestRenderFrameRoutingId"
	//
	// Optional
	//
	// NOTE: FFI_USE_GuestRenderFrameRoutingId MUST be set to true to make this field effective.
	GuestRenderFrameRoutingId int64
	// Id is "MessageSender.id"
	//
	// Optional
	Id js.String
	// NativeApplication is "MessageSender.nativeApplication"
	//
	// Optional
	NativeApplication js.String
	// Origin is "MessageSender.origin"
	//
	// Optional
	Origin js.String
	// Tab is "MessageSender.tab"
	//
	// Optional
	//
	// NOTE: Tab.FFI_USE MUST be set to true to get Tab used.
	Tab tabs.Tab
	// TlsChannelId is "MessageSender.tlsChannelId"
	//
	// Optional
	TlsChannelId js.String
	// Url is "MessageSender.url"
	//
	// Optional
	Url js.String

	FFI_USE_FrameId                   bool // for FrameId.
	FFI_USE_GuestProcessId            bool // for GuestProcessId.
	FFI_USE_GuestRenderFrameRoutingId bool // for GuestRenderFrameRoutingId.

	FFI_USE bool
}

func (*MessageSender) FreeMembers

func (p *MessageSender) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (MessageSender) FromRef

func (p MessageSender) FromRef(ref js.Ref) MessageSender

FromRef calls UpdateFrom and returns a MessageSender with all fields set.

func (MessageSender) New

func (p MessageSender) New() js.Ref

New creates a new MessageSender in the application heap.

func (*MessageSender) Update

func (p *MessageSender) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*MessageSender) UpdateFrom

func (p *MessageSender) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type OnBrowserUpdateAvailableEventCallback

type OnBrowserUpdateAvailableEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref) js.Ref
	Arg T
}

func (*OnBrowserUpdateAvailableEventCallback[T]) DispatchCallback

func (cb *OnBrowserUpdateAvailableEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnBrowserUpdateAvailableEventCallback[T]) Register

func (cb *OnBrowserUpdateAvailableEventCallback[T]) Register() js.Func[func()]

type OnBrowserUpdateAvailableEventCallbackFunc

type OnBrowserUpdateAvailableEventCallbackFunc func(this js.Ref) js.Ref

func (OnBrowserUpdateAvailableEventCallbackFunc) DispatchCallback

func (fn OnBrowserUpdateAvailableEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnBrowserUpdateAvailableEventCallbackFunc) Register

func (fn OnBrowserUpdateAvailableEventCallbackFunc) Register() js.Func[func()]

type OnConnectEventCallback

type OnConnectEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, port *Port) js.Ref
	Arg T
}

func (*OnConnectEventCallback[T]) DispatchCallback

func (cb *OnConnectEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnConnectEventCallback[T]) Register

func (cb *OnConnectEventCallback[T]) Register() js.Func[func(port *Port)]

type OnConnectEventCallbackFunc

type OnConnectEventCallbackFunc func(this js.Ref, port *Port) js.Ref

func (OnConnectEventCallbackFunc) DispatchCallback

func (fn OnConnectEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnConnectEventCallbackFunc) Register

func (fn OnConnectEventCallbackFunc) Register() js.Func[func(port *Port)]

type OnConnectExternalEventCallback

type OnConnectExternalEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, port *Port) js.Ref
	Arg T
}

func (*OnConnectExternalEventCallback[T]) DispatchCallback

func (cb *OnConnectExternalEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnConnectExternalEventCallback[T]) Register

func (cb *OnConnectExternalEventCallback[T]) Register() js.Func[func(port *Port)]

type OnConnectExternalEventCallbackFunc

type OnConnectExternalEventCallbackFunc func(this js.Ref, port *Port) js.Ref

func (OnConnectExternalEventCallbackFunc) DispatchCallback

func (fn OnConnectExternalEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnConnectExternalEventCallbackFunc) Register

func (fn OnConnectExternalEventCallbackFunc) Register() js.Func[func(port *Port)]

type OnConnectNativeEventCallback

type OnConnectNativeEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, port *Port) js.Ref
	Arg T
}

func (*OnConnectNativeEventCallback[T]) DispatchCallback

func (cb *OnConnectNativeEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnConnectNativeEventCallback[T]) Register

func (cb *OnConnectNativeEventCallback[T]) Register() js.Func[func(port *Port)]

type OnConnectNativeEventCallbackFunc

type OnConnectNativeEventCallbackFunc func(this js.Ref, port *Port) js.Ref

func (OnConnectNativeEventCallbackFunc) DispatchCallback

func (fn OnConnectNativeEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnConnectNativeEventCallbackFunc) Register

func (fn OnConnectNativeEventCallbackFunc) Register() js.Func[func(port *Port)]

type OnInstalledArgDetails

type OnInstalledArgDetails struct {
	// Id is "OnInstalledArgDetails.id"
	//
	// Optional
	Id js.String
	// PreviousVersion is "OnInstalledArgDetails.previousVersion"
	//
	// Optional
	PreviousVersion js.String
	// Reason is "OnInstalledArgDetails.reason"
	//
	// Required
	Reason OnInstalledReason

	FFI_USE bool
}

func (*OnInstalledArgDetails) FreeMembers

func (p *OnInstalledArgDetails) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (OnInstalledArgDetails) FromRef

FromRef calls UpdateFrom and returns a OnInstalledArgDetails with all fields set.

func (OnInstalledArgDetails) New

func (p OnInstalledArgDetails) New() js.Ref

New creates a new OnInstalledArgDetails in the application heap.

func (*OnInstalledArgDetails) Update

func (p *OnInstalledArgDetails) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*OnInstalledArgDetails) UpdateFrom

func (p *OnInstalledArgDetails) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type OnInstalledEventCallback

type OnInstalledEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, details *OnInstalledArgDetails) js.Ref
	Arg T
}

func (*OnInstalledEventCallback[T]) DispatchCallback

func (cb *OnInstalledEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnInstalledEventCallback[T]) Register

func (cb *OnInstalledEventCallback[T]) Register() js.Func[func(details *OnInstalledArgDetails)]

type OnInstalledEventCallbackFunc

type OnInstalledEventCallbackFunc func(this js.Ref, details *OnInstalledArgDetails) js.Ref

func (OnInstalledEventCallbackFunc) DispatchCallback

func (fn OnInstalledEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnInstalledEventCallbackFunc) Register

func (fn OnInstalledEventCallbackFunc) Register() js.Func[func(details *OnInstalledArgDetails)]

type OnInstalledReason

type OnInstalledReason uint32
const (
	OnInstalledReason_INSTALL OnInstalledReason
	OnInstalledReason_UPDATE
	OnInstalledReason_CHROME_UPDATE
	OnInstalledReason_SHARED_MODULE_UPDATE
)

func (OnInstalledReason) FromRef

func (OnInstalledReason) String

func (x OnInstalledReason) String() (string, bool)

type OnMessageArgSendResponse

type OnMessageArgSendResponse[T any] struct {
	Fn  func(arg T, this js.Ref) js.Ref
	Arg T
}

func (*OnMessageArgSendResponse[T]) DispatchCallback

func (cb *OnMessageArgSendResponse[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnMessageArgSendResponse[T]) Register

func (cb *OnMessageArgSendResponse[T]) Register() js.Func[func()]

type OnMessageArgSendResponseFunc

type OnMessageArgSendResponseFunc func(this js.Ref) js.Ref

func (OnMessageArgSendResponseFunc) DispatchCallback

func (fn OnMessageArgSendResponseFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnMessageArgSendResponseFunc) Register

func (fn OnMessageArgSendResponseFunc) Register() js.Func[func()]

type OnMessageEventCallback

type OnMessageEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, message js.Any, sender *MessageSender, sendResponse js.Func[func()]) js.Ref
	Arg T
}

func (*OnMessageEventCallback[T]) DispatchCallback

func (cb *OnMessageEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnMessageEventCallback[T]) Register

func (cb *OnMessageEventCallback[T]) Register() js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]

type OnMessageEventCallbackFunc

type OnMessageEventCallbackFunc func(this js.Ref, message js.Any, sender *MessageSender, sendResponse js.Func[func()]) js.Ref

func (OnMessageEventCallbackFunc) DispatchCallback

func (fn OnMessageEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnMessageEventCallbackFunc) Register

func (fn OnMessageEventCallbackFunc) Register() js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]

type OnMessageExternalArgSendResponse

type OnMessageExternalArgSendResponse[T any] struct {
	Fn  func(arg T, this js.Ref) js.Ref
	Arg T
}

func (*OnMessageExternalArgSendResponse[T]) DispatchCallback

func (cb *OnMessageExternalArgSendResponse[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnMessageExternalArgSendResponse[T]) Register

func (cb *OnMessageExternalArgSendResponse[T]) Register() js.Func[func()]

type OnMessageExternalArgSendResponseFunc

type OnMessageExternalArgSendResponseFunc func(this js.Ref) js.Ref

func (OnMessageExternalArgSendResponseFunc) DispatchCallback

func (fn OnMessageExternalArgSendResponseFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnMessageExternalArgSendResponseFunc) Register

func (fn OnMessageExternalArgSendResponseFunc) Register() js.Func[func()]

type OnMessageExternalEventCallback

type OnMessageExternalEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, message js.Any, sender *MessageSender, sendResponse js.Func[func()]) js.Ref
	Arg T
}

func (*OnMessageExternalEventCallback[T]) DispatchCallback

func (cb *OnMessageExternalEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnMessageExternalEventCallback[T]) Register

func (cb *OnMessageExternalEventCallback[T]) Register() js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]

type OnMessageExternalEventCallbackFunc

type OnMessageExternalEventCallbackFunc func(this js.Ref, message js.Any, sender *MessageSender, sendResponse js.Func[func()]) js.Ref

func (OnMessageExternalEventCallbackFunc) DispatchCallback

func (fn OnMessageExternalEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnMessageExternalEventCallbackFunc) Register

func (fn OnMessageExternalEventCallbackFunc) Register() js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]

type OnRestartRequiredEventCallback

type OnRestartRequiredEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, reason OnRestartRequiredReason) js.Ref
	Arg T
}

func (*OnRestartRequiredEventCallback[T]) DispatchCallback

func (cb *OnRestartRequiredEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnRestartRequiredEventCallback[T]) Register

func (cb *OnRestartRequiredEventCallback[T]) Register() js.Func[func(reason OnRestartRequiredReason)]

type OnRestartRequiredEventCallbackFunc

type OnRestartRequiredEventCallbackFunc func(this js.Ref, reason OnRestartRequiredReason) js.Ref

func (OnRestartRequiredEventCallbackFunc) DispatchCallback

func (fn OnRestartRequiredEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnRestartRequiredEventCallbackFunc) Register

type OnRestartRequiredReason

type OnRestartRequiredReason uint32
const (
	OnRestartRequiredReason_APP_UPDATE OnRestartRequiredReason
	OnRestartRequiredReason_OS_UPDATE
	OnRestartRequiredReason_PERIODIC
)

func (OnRestartRequiredReason) FromRef

func (OnRestartRequiredReason) String

func (x OnRestartRequiredReason) String() (string, bool)

type OnStartupEventCallback

type OnStartupEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref) js.Ref
	Arg T
}

func (*OnStartupEventCallback[T]) DispatchCallback

func (cb *OnStartupEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnStartupEventCallback[T]) Register

func (cb *OnStartupEventCallback[T]) Register() js.Func[func()]

type OnStartupEventCallbackFunc

type OnStartupEventCallbackFunc func(this js.Ref) js.Ref

func (OnStartupEventCallbackFunc) DispatchCallback

func (fn OnStartupEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnStartupEventCallbackFunc) Register

func (fn OnStartupEventCallbackFunc) Register() js.Func[func()]

type OnSuspendCanceledEventCallback

type OnSuspendCanceledEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref) js.Ref
	Arg T
}

func (*OnSuspendCanceledEventCallback[T]) DispatchCallback

func (cb *OnSuspendCanceledEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnSuspendCanceledEventCallback[T]) Register

func (cb *OnSuspendCanceledEventCallback[T]) Register() js.Func[func()]

type OnSuspendCanceledEventCallbackFunc

type OnSuspendCanceledEventCallbackFunc func(this js.Ref) js.Ref

func (OnSuspendCanceledEventCallbackFunc) DispatchCallback

func (fn OnSuspendCanceledEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnSuspendCanceledEventCallbackFunc) Register

func (fn OnSuspendCanceledEventCallbackFunc) Register() js.Func[func()]

type OnSuspendEventCallback

type OnSuspendEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref) js.Ref
	Arg T
}

func (*OnSuspendEventCallback[T]) DispatchCallback

func (cb *OnSuspendEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnSuspendEventCallback[T]) Register

func (cb *OnSuspendEventCallback[T]) Register() js.Func[func()]

type OnSuspendEventCallbackFunc

type OnSuspendEventCallbackFunc func(this js.Ref) js.Ref

func (OnSuspendEventCallbackFunc) DispatchCallback

func (fn OnSuspendEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnSuspendEventCallbackFunc) Register

func (fn OnSuspendEventCallbackFunc) Register() js.Func[func()]

type OnUpdateAvailableEventCallback

type OnUpdateAvailableEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, details js.Any) js.Ref
	Arg T
}

func (*OnUpdateAvailableEventCallback[T]) DispatchCallback

func (cb *OnUpdateAvailableEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnUpdateAvailableEventCallback[T]) Register

func (cb *OnUpdateAvailableEventCallback[T]) Register() js.Func[func(details js.Any)]

type OnUpdateAvailableEventCallbackFunc

type OnUpdateAvailableEventCallbackFunc func(this js.Ref, details js.Any) js.Ref

func (OnUpdateAvailableEventCallbackFunc) DispatchCallback

func (fn OnUpdateAvailableEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnUpdateAvailableEventCallbackFunc) Register

func (fn OnUpdateAvailableEventCallbackFunc) Register() js.Func[func(details js.Any)]

type OnUserScriptConnectEventCallback

type OnUserScriptConnectEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, port *Port) js.Ref
	Arg T
}

func (*OnUserScriptConnectEventCallback[T]) DispatchCallback

func (cb *OnUserScriptConnectEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnUserScriptConnectEventCallback[T]) Register

func (cb *OnUserScriptConnectEventCallback[T]) Register() js.Func[func(port *Port)]

type OnUserScriptConnectEventCallbackFunc

type OnUserScriptConnectEventCallbackFunc func(this js.Ref, port *Port) js.Ref

func (OnUserScriptConnectEventCallbackFunc) DispatchCallback

func (fn OnUserScriptConnectEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnUserScriptConnectEventCallbackFunc) Register

func (fn OnUserScriptConnectEventCallbackFunc) Register() js.Func[func(port *Port)]

type OnUserScriptMessageArgSendResponse

type OnUserScriptMessageArgSendResponse[T any] struct {
	Fn  func(arg T, this js.Ref) js.Ref
	Arg T
}

func (*OnUserScriptMessageArgSendResponse[T]) DispatchCallback

func (cb *OnUserScriptMessageArgSendResponse[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnUserScriptMessageArgSendResponse[T]) Register

func (cb *OnUserScriptMessageArgSendResponse[T]) Register() js.Func[func()]

type OnUserScriptMessageArgSendResponseFunc

type OnUserScriptMessageArgSendResponseFunc func(this js.Ref) js.Ref

func (OnUserScriptMessageArgSendResponseFunc) DispatchCallback

func (fn OnUserScriptMessageArgSendResponseFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnUserScriptMessageArgSendResponseFunc) Register

func (fn OnUserScriptMessageArgSendResponseFunc) Register() js.Func[func()]

type OnUserScriptMessageEventCallback

type OnUserScriptMessageEventCallback[T any] struct {
	Fn  func(arg T, this js.Ref, message js.Any, sender *MessageSender, sendResponse js.Func[func()]) js.Ref
	Arg T
}

func (*OnUserScriptMessageEventCallback[T]) DispatchCallback

func (cb *OnUserScriptMessageEventCallback[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*OnUserScriptMessageEventCallback[T]) Register

func (cb *OnUserScriptMessageEventCallback[T]) Register() js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]

type OnUserScriptMessageEventCallbackFunc

type OnUserScriptMessageEventCallbackFunc func(this js.Ref, message js.Any, sender *MessageSender, sendResponse js.Func[func()]) js.Ref

func (OnUserScriptMessageEventCallbackFunc) DispatchCallback

func (fn OnUserScriptMessageEventCallbackFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (OnUserScriptMessageEventCallbackFunc) Register

func (fn OnUserScriptMessageEventCallbackFunc) Register() js.Func[func(message js.Any, sender *MessageSender, sendResponse js.Func[func()]) bool]

type PlatformArch

type PlatformArch uint32
const (
	PlatformArch_ARM PlatformArch
	PlatformArch_ARM64
	PlatformArch_X86_32
	PlatformArch_X86_64
	PlatformArch_MIPS
	PlatformArch_MIPS64
)

func (PlatformArch) FromRef

func (PlatformArch) FromRef(str js.Ref) PlatformArch

func (PlatformArch) String

func (x PlatformArch) String() (string, bool)

type PlatformInfo

type PlatformInfo struct {
	// Arch is "PlatformInfo.arch"
	//
	// Required
	Arch PlatformArch
	// NaclArch is "PlatformInfo.nacl_arch"
	//
	// Required
	NaclArch PlatformNaclArch
	// Os is "PlatformInfo.os"
	//
	// Required
	Os PlatformOs

	FFI_USE bool
}

func (*PlatformInfo) FreeMembers

func (p *PlatformInfo) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (PlatformInfo) FromRef

func (p PlatformInfo) FromRef(ref js.Ref) PlatformInfo

FromRef calls UpdateFrom and returns a PlatformInfo with all fields set.

func (PlatformInfo) New

func (p PlatformInfo) New() js.Ref

New creates a new PlatformInfo in the application heap.

func (*PlatformInfo) Update

func (p *PlatformInfo) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*PlatformInfo) UpdateFrom

func (p *PlatformInfo) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type PlatformNaclArch

type PlatformNaclArch uint32
const (
	PlatformNaclArch_ARM PlatformNaclArch
	PlatformNaclArch_X86_32
	PlatformNaclArch_X86_64
	PlatformNaclArch_MIPS
	PlatformNaclArch_MIPS64
)

func (PlatformNaclArch) FromRef

func (PlatformNaclArch) FromRef(str js.Ref) PlatformNaclArch

func (PlatformNaclArch) String

func (x PlatformNaclArch) String() (string, bool)

type PlatformOs

type PlatformOs uint32
const (
	PlatformOs_MAC PlatformOs
	PlatformOs_WIN
	PlatformOs_ANDROID
	PlatformOs_CROS
	PlatformOs_LINUX
	PlatformOs_OPENBSD
	PlatformOs_FUCHSIA
)

func (PlatformOs) FromRef

func (PlatformOs) FromRef(str js.Ref) PlatformOs

func (PlatformOs) String

func (x PlatformOs) String() (string, bool)

type Port

type Port struct {
	// Disconnect is "Port.disconnect"
	//
	// Required
	Disconnect js.Func[func()]
	// Name is "Port.name"
	//
	// Required
	Name js.String
	// PostMessage is "Port.postMessage"
	//
	// Required
	PostMessage js.Func[func(message js.Any)]
	// Sender is "Port.sender"
	//
	// Optional
	//
	// NOTE: Sender.FFI_USE MUST be set to true to get Sender used.
	Sender MessageSender

	FFI_USE bool
}

func Connect

func Connect(extensionId js.String, connectInfo ConnectArgConnectInfo) (ret Port)

Connect calls the function "WEBEXT.runtime.connect" directly.

func ConnectNative

func ConnectNative(application js.String) (ret Port)

ConnectNative calls the function "WEBEXT.runtime.connectNative" directly.

func TryConnect

func TryConnect(extensionId js.String, connectInfo ConnectArgConnectInfo) (ret Port, exception js.Any, ok bool)

TryConnect calls the function "WEBEXT.runtime.connect" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func TryConnectNative

func TryConnectNative(application js.String) (ret Port, exception js.Any, ok bool)

TryConnectNative calls the function "WEBEXT.runtime.connectNative" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.

func (*Port) FreeMembers

func (p *Port) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (Port) FromRef

func (p Port) FromRef(ref js.Ref) Port

FromRef calls UpdateFrom and returns a Port with all fields set.

func (Port) New

func (p Port) New() js.Ref

New creates a new Port in the application heap.

func (*Port) Update

func (p *Port) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*Port) UpdateFrom

func (p *Port) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type PortFieldDisconnect

type PortFieldDisconnect[T any] struct {
	Fn  func(arg T, this js.Ref) js.Ref
	Arg T
}

func (*PortFieldDisconnect[T]) DispatchCallback

func (cb *PortFieldDisconnect[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*PortFieldDisconnect[T]) Register

func (cb *PortFieldDisconnect[T]) Register() js.Func[func()]

type PortFieldDisconnectFunc

type PortFieldDisconnectFunc func(this js.Ref) js.Ref

func (PortFieldDisconnectFunc) DispatchCallback

func (fn PortFieldDisconnectFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (PortFieldDisconnectFunc) Register

func (fn PortFieldDisconnectFunc) Register() js.Func[func()]

type PortFieldPostMessage

type PortFieldPostMessage[T any] struct {
	Fn  func(arg T, this js.Ref, message js.Any) js.Ref
	Arg T
}

func (*PortFieldPostMessage[T]) DispatchCallback

func (cb *PortFieldPostMessage[T]) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (*PortFieldPostMessage[T]) Register

func (cb *PortFieldPostMessage[T]) Register() js.Func[func(message js.Any)]

type PortFieldPostMessageFunc

type PortFieldPostMessageFunc func(this js.Ref, message js.Any) js.Ref

func (PortFieldPostMessageFunc) DispatchCallback

func (fn PortFieldPostMessageFunc) DispatchCallback(
	targetPC uintptr, ctx *js.CallbackContext,
)

func (PortFieldPostMessageFunc) Register

func (fn PortFieldPostMessageFunc) Register() js.Func[func(message js.Any)]

type RequestUpdateCheckReturnType

type RequestUpdateCheckReturnType struct {
	// Status is "RequestUpdateCheckReturnType.status"
	//
	// Required
	Status RequestUpdateCheckStatus
	// Version is "RequestUpdateCheckReturnType.version"
	//
	// Optional
	Version js.String

	FFI_USE bool
}

func (*RequestUpdateCheckReturnType) FreeMembers

func (p *RequestUpdateCheckReturnType) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (RequestUpdateCheckReturnType) FromRef

FromRef calls UpdateFrom and returns a RequestUpdateCheckReturnType with all fields set.

func (RequestUpdateCheckReturnType) New

New creates a new RequestUpdateCheckReturnType in the application heap.

func (*RequestUpdateCheckReturnType) Update

func (p *RequestUpdateCheckReturnType) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*RequestUpdateCheckReturnType) UpdateFrom

func (p *RequestUpdateCheckReturnType) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

type RequestUpdateCheckStatus

type RequestUpdateCheckStatus uint32
const (
	RequestUpdateCheckStatus_THROTTLED RequestUpdateCheckStatus
	RequestUpdateCheckStatus_NO_UPDATE
	RequestUpdateCheckStatus_UPDATE_AVAILABLE
)

func (RequestUpdateCheckStatus) FromRef

func (RequestUpdateCheckStatus) String

func (x RequestUpdateCheckStatus) String() (string, bool)

type SendMessageArgOptions

type SendMessageArgOptions struct {
	// IncludeTlsChannelId is "SendMessageArgOptions.includeTlsChannelId"
	//
	// Optional
	//
	// NOTE: FFI_USE_IncludeTlsChannelId MUST be set to true to make this field effective.
	IncludeTlsChannelId bool

	FFI_USE_IncludeTlsChannelId bool // for IncludeTlsChannelId.

	FFI_USE bool
}

func (*SendMessageArgOptions) FreeMembers

func (p *SendMessageArgOptions) FreeMembers(recursive bool)

FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.

func (SendMessageArgOptions) FromRef

FromRef calls UpdateFrom and returns a SendMessageArgOptions with all fields set.

func (SendMessageArgOptions) New

func (p SendMessageArgOptions) New() js.Ref

New creates a new SendMessageArgOptions in the application heap.

func (*SendMessageArgOptions) Update

func (p *SendMessageArgOptions) Update(ref js.Ref)

Update writes all fields of the p to the heap object referenced by ref.

func (*SendMessageArgOptions) UpdateFrom

func (p *SendMessageArgOptions) UpdateFrom(ref js.Ref)

UpdateFrom copies value of all fields of the heap object to p.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL