Documentation
¶
Index ¶
- func Close(socketId int32) (ret js.Promise[js.Void])
- func Connect(socketId int32, address js.String, uuid js.String) (ret js.Promise[js.Void])
- func Create(properties SocketProperties) (ret js.Promise[CreateInfo])
- func Disconnect(socketId int32) (ret js.Promise[js.Void])
- func FuncClose() (fn js.Func[func(socketId int32) js.Promise[js.Void]])
- func FuncConnect() (...)
- func FuncCreate() (fn js.Func[func(properties SocketProperties) js.Promise[CreateInfo]])
- func FuncDisconnect() (fn js.Func[func(socketId int32) js.Promise[js.Void]])
- func FuncGetInfo() (fn js.Func[func(socketId int32) js.Promise[SocketInfo]])
- func FuncGetSockets() (fn js.Func[func() js.Promise[js.Array[SocketInfo]]])
- func FuncHasOnAccept() (fn js.Func[func(callback js.Func[func(info *AcceptInfo)]) bool])
- func FuncHasOnAcceptError() (fn js.Func[func(callback js.Func[func(info *AcceptErrorInfo)]) bool])
- func FuncHasOnReceive() (fn js.Func[func(callback js.Func[func(info *ReceiveInfo)]) bool])
- func FuncHasOnReceiveError() (fn js.Func[func(callback js.Func[func(info *ReceiveErrorInfo)]) bool])
- func FuncListenUsingL2cap() (...)
- func FuncListenUsingRfcomm() (...)
- func FuncOffAccept() (fn js.Func[func(callback js.Func[func(info *AcceptInfo)])])
- func FuncOffAcceptError() (fn js.Func[func(callback js.Func[func(info *AcceptErrorInfo)])])
- func FuncOffReceive() (fn js.Func[func(callback js.Func[func(info *ReceiveInfo)])])
- func FuncOffReceiveError() (fn js.Func[func(callback js.Func[func(info *ReceiveErrorInfo)])])
- func FuncOnAccept() (fn js.Func[func(callback js.Func[func(info *AcceptInfo)])])
- func FuncOnAcceptError() (fn js.Func[func(callback js.Func[func(info *AcceptErrorInfo)])])
- func FuncOnReceive() (fn js.Func[func(callback js.Func[func(info *ReceiveInfo)])])
- func FuncOnReceiveError() (fn js.Func[func(callback js.Func[func(info *ReceiveErrorInfo)])])
- func FuncSend() (...)
- func FuncSetPaused() (fn js.Func[func(socketId int32, paused bool) js.Promise[js.Void]])
- func FuncUpdate() (...)
- func GetInfo(socketId int32) (ret js.Promise[SocketInfo])
- func GetSockets() (ret js.Promise[js.Array[SocketInfo]])
- func HasFuncClose() bool
- func HasFuncConnect() bool
- func HasFuncCreate() bool
- func HasFuncDisconnect() bool
- func HasFuncGetInfo() bool
- func HasFuncGetSockets() bool
- func HasFuncHasOnAccept() bool
- func HasFuncHasOnAcceptError() bool
- func HasFuncHasOnReceive() bool
- func HasFuncHasOnReceiveError() bool
- func HasFuncListenUsingL2cap() bool
- func HasFuncListenUsingRfcomm() bool
- func HasFuncOffAccept() bool
- func HasFuncOffAcceptError() bool
- func HasFuncOffReceive() bool
- func HasFuncOffReceiveError() bool
- func HasFuncOnAccept() bool
- func HasFuncOnAcceptError() bool
- func HasFuncOnReceive() bool
- func HasFuncOnReceiveError() bool
- func HasFuncSend() bool
- func HasFuncSetPaused() bool
- func HasFuncUpdate() bool
- func HasOnAccept(callback js.Func[func(info *AcceptInfo)]) (ret bool)
- func HasOnAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret bool)
- func HasOnReceive(callback js.Func[func(info *ReceiveInfo)]) (ret bool)
- func HasOnReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret bool)
- func ListenUsingL2cap(socketId int32, uuid js.String, options ListenOptions) (ret js.Promise[js.Void])
- func ListenUsingRfcomm(socketId int32, uuid js.String, options ListenOptions) (ret js.Promise[js.Void])
- func OffAccept(callback js.Func[func(info *AcceptInfo)]) (ret js.Void)
- func OffAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret js.Void)
- func OffReceive(callback js.Func[func(info *ReceiveInfo)]) (ret js.Void)
- func OffReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret js.Void)
- func OnAccept(callback js.Func[func(info *AcceptInfo)]) (ret js.Void)
- func OnAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret js.Void)
- func OnReceive(callback js.Func[func(info *ReceiveInfo)]) (ret js.Void)
- func OnReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret js.Void)
- func Send(socketId int32, data js.ArrayBuffer) (ret js.Promise[js.Number[int32]])
- func SetPaused(socketId int32, paused bool) (ret js.Promise[js.Void])
- func TryClose(socketId int32) (ret js.Promise[js.Void], exception js.Any, ok bool)
- func TryConnect(socketId int32, address js.String, uuid js.String) (ret js.Promise[js.Void], exception js.Any, ok bool)
- func TryCreate(properties SocketProperties) (ret js.Promise[CreateInfo], exception js.Any, ok bool)
- func TryDisconnect(socketId int32) (ret js.Promise[js.Void], exception js.Any, ok bool)
- func TryGetInfo(socketId int32) (ret js.Promise[SocketInfo], exception js.Any, ok bool)
- func TryGetSockets() (ret js.Promise[js.Array[SocketInfo]], exception js.Any, ok bool)
- func TryHasOnAccept(callback js.Func[func(info *AcceptInfo)]) (ret bool, exception js.Any, ok bool)
- func TryHasOnAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret bool, exception js.Any, ok bool)
- func TryHasOnReceive(callback js.Func[func(info *ReceiveInfo)]) (ret bool, exception js.Any, ok bool)
- func TryHasOnReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret bool, exception js.Any, ok bool)
- func TryListenUsingL2cap(socketId int32, uuid js.String, options ListenOptions) (ret js.Promise[js.Void], exception js.Any, ok bool)
- func TryListenUsingRfcomm(socketId int32, uuid js.String, options ListenOptions) (ret js.Promise[js.Void], exception js.Any, ok bool)
- func TryOffAccept(callback js.Func[func(info *AcceptInfo)]) (ret js.Void, exception js.Any, ok bool)
- func TryOffAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret js.Void, exception js.Any, ok bool)
- func TryOffReceive(callback js.Func[func(info *ReceiveInfo)]) (ret js.Void, exception js.Any, ok bool)
- func TryOffReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret js.Void, exception js.Any, ok bool)
- func TryOnAccept(callback js.Func[func(info *AcceptInfo)]) (ret js.Void, exception js.Any, ok bool)
- func TryOnAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret js.Void, exception js.Any, ok bool)
- func TryOnReceive(callback js.Func[func(info *ReceiveInfo)]) (ret js.Void, exception js.Any, ok bool)
- func TryOnReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret js.Void, exception js.Any, ok bool)
- func TrySend(socketId int32, data js.ArrayBuffer) (ret js.Promise[js.Number[int32]], exception js.Any, ok bool)
- func TrySetPaused(socketId int32, paused bool) (ret js.Promise[js.Void], exception js.Any, ok bool)
- func TryUpdate(socketId int32, properties SocketProperties) (ret js.Promise[js.Void], exception js.Any, ok bool)
- func Update(socketId int32, properties SocketProperties) (ret js.Promise[js.Void])
- type AcceptError
- type AcceptErrorInfo
- type AcceptInfo
- type CloseCallback
- type CloseCallbackFunc
- type ConnectCallback
- type ConnectCallbackFunc
- type CreateCallback
- type CreateCallbackFunc
- type CreateInfo
- type DisconnectCallback
- type DisconnectCallbackFunc
- type GetInfoCallback
- type GetInfoCallbackFunc
- type GetSocketsCallback
- type GetSocketsCallbackFunc
- type ListenCallback
- type ListenCallbackFunc
- type ListenOptions
- type OnAcceptErrorEventCallback
- type OnAcceptErrorEventCallbackFunc
- type OnAcceptEventCallback
- type OnAcceptEventCallbackFunc
- type OnReceiveErrorEventCallback
- type OnReceiveErrorEventCallbackFunc
- type OnReceiveEventCallback
- type OnReceiveEventCallbackFunc
- type ReceiveError
- type ReceiveErrorInfo
- type ReceiveInfo
- type SendCallback
- type SendCallbackFunc
- type SetPausedCallback
- type SetPausedCallbackFunc
- type SocketInfo
- type SocketProperties
- type UpdateCallback
- type UpdateCallbackFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Create ¶
func Create(properties SocketProperties) (ret js.Promise[CreateInfo])
Create calls the function "WEBEXT.bluetoothSocket.create" directly.
func Disconnect ¶
Disconnect calls the function "WEBEXT.bluetoothSocket.disconnect" directly.
func FuncConnect ¶
func FuncConnect() (fn js.Func[func(socketId int32, address js.String, uuid js.String) js.Promise[js.Void]])
FuncConnect returns the function "WEBEXT.bluetoothSocket.connect".
func FuncCreate ¶
func FuncCreate() (fn js.Func[func(properties SocketProperties) js.Promise[CreateInfo]])
FuncCreate returns the function "WEBEXT.bluetoothSocket.create".
func FuncDisconnect ¶
FuncDisconnect returns the function "WEBEXT.bluetoothSocket.disconnect".
func FuncGetInfo ¶
FuncGetInfo returns the function "WEBEXT.bluetoothSocket.getInfo".
func FuncGetSockets ¶
FuncGetSockets returns the function "WEBEXT.bluetoothSocket.getSockets".
func FuncHasOnAccept ¶
FuncHasOnAccept returns the function "WEBEXT.bluetoothSocket.onAccept.hasListener".
func FuncHasOnAcceptError ¶
FuncHasOnAcceptError returns the function "WEBEXT.bluetoothSocket.onAcceptError.hasListener".
func FuncHasOnReceive ¶
FuncHasOnReceive returns the function "WEBEXT.bluetoothSocket.onReceive.hasListener".
func FuncHasOnReceiveError ¶
func FuncHasOnReceiveError() (fn js.Func[func(callback js.Func[func(info *ReceiveErrorInfo)]) bool])
FuncHasOnReceiveError returns the function "WEBEXT.bluetoothSocket.onReceiveError.hasListener".
func FuncListenUsingL2cap ¶
func FuncListenUsingL2cap() (fn js.Func[func(socketId int32, uuid js.String, options ListenOptions) js.Promise[js.Void]])
FuncListenUsingL2cap returns the function "WEBEXT.bluetoothSocket.listenUsingL2cap".
func FuncListenUsingRfcomm ¶
func FuncListenUsingRfcomm() (fn js.Func[func(socketId int32, uuid js.String, options ListenOptions) js.Promise[js.Void]])
FuncListenUsingRfcomm returns the function "WEBEXT.bluetoothSocket.listenUsingRfcomm".
func FuncOffAccept ¶
func FuncOffAccept() (fn js.Func[func(callback js.Func[func(info *AcceptInfo)])])
FuncOffAccept returns the function "WEBEXT.bluetoothSocket.onAccept.removeListener".
func FuncOffAcceptError ¶
func FuncOffAcceptError() (fn js.Func[func(callback js.Func[func(info *AcceptErrorInfo)])])
FuncOffAcceptError returns the function "WEBEXT.bluetoothSocket.onAcceptError.removeListener".
func FuncOffReceive ¶
func FuncOffReceive() (fn js.Func[func(callback js.Func[func(info *ReceiveInfo)])])
FuncOffReceive returns the function "WEBEXT.bluetoothSocket.onReceive.removeListener".
func FuncOffReceiveError ¶
func FuncOffReceiveError() (fn js.Func[func(callback js.Func[func(info *ReceiveErrorInfo)])])
FuncOffReceiveError returns the function "WEBEXT.bluetoothSocket.onReceiveError.removeListener".
func FuncOnAccept ¶
func FuncOnAccept() (fn js.Func[func(callback js.Func[func(info *AcceptInfo)])])
FuncOnAccept returns the function "WEBEXT.bluetoothSocket.onAccept.addListener".
func FuncOnAcceptError ¶
func FuncOnAcceptError() (fn js.Func[func(callback js.Func[func(info *AcceptErrorInfo)])])
FuncOnAcceptError returns the function "WEBEXT.bluetoothSocket.onAcceptError.addListener".
func FuncOnReceive ¶
func FuncOnReceive() (fn js.Func[func(callback js.Func[func(info *ReceiveInfo)])])
FuncOnReceive returns the function "WEBEXT.bluetoothSocket.onReceive.addListener".
func FuncOnReceiveError ¶
func FuncOnReceiveError() (fn js.Func[func(callback js.Func[func(info *ReceiveErrorInfo)])])
FuncOnReceiveError returns the function "WEBEXT.bluetoothSocket.onReceiveError.addListener".
func FuncSend ¶
func FuncSend() (fn js.Func[func(socketId int32, data js.ArrayBuffer) js.Promise[js.Number[int32]]])
FuncSend returns the function "WEBEXT.bluetoothSocket.send".
func FuncSetPaused ¶
FuncSetPaused returns the function "WEBEXT.bluetoothSocket.setPaused".
func FuncUpdate ¶
func FuncUpdate() (fn js.Func[func(socketId int32, properties SocketProperties) js.Promise[js.Void]])
FuncUpdate returns the function "WEBEXT.bluetoothSocket.update".
func GetInfo ¶
func GetInfo(socketId int32) (ret js.Promise[SocketInfo])
GetInfo calls the function "WEBEXT.bluetoothSocket.getInfo" directly.
func GetSockets ¶
func GetSockets() (ret js.Promise[js.Array[SocketInfo]])
GetSockets calls the function "WEBEXT.bluetoothSocket.getSockets" directly.
func HasFuncClose ¶
func HasFuncClose() bool
HasFuncClose returns true if the function "WEBEXT.bluetoothSocket.close" exists.
func HasFuncConnect ¶
func HasFuncConnect() bool
HasFuncConnect returns true if the function "WEBEXT.bluetoothSocket.connect" exists.
func HasFuncCreate ¶
func HasFuncCreate() bool
HasFuncCreate returns true if the function "WEBEXT.bluetoothSocket.create" exists.
func HasFuncDisconnect ¶
func HasFuncDisconnect() bool
HasFuncDisconnect returns true if the function "WEBEXT.bluetoothSocket.disconnect" exists.
func HasFuncGetInfo ¶
func HasFuncGetInfo() bool
HasFuncGetInfo returns true if the function "WEBEXT.bluetoothSocket.getInfo" exists.
func HasFuncGetSockets ¶
func HasFuncGetSockets() bool
HasFuncGetSockets returns true if the function "WEBEXT.bluetoothSocket.getSockets" exists.
func HasFuncHasOnAccept ¶
func HasFuncHasOnAccept() bool
HasFuncHasOnAccept returns true if the function "WEBEXT.bluetoothSocket.onAccept.hasListener" exists.
func HasFuncHasOnAcceptError ¶
func HasFuncHasOnAcceptError() bool
HasFuncHasOnAcceptError returns true if the function "WEBEXT.bluetoothSocket.onAcceptError.hasListener" exists.
func HasFuncHasOnReceive ¶
func HasFuncHasOnReceive() bool
HasFuncHasOnReceive returns true if the function "WEBEXT.bluetoothSocket.onReceive.hasListener" exists.
func HasFuncHasOnReceiveError ¶
func HasFuncHasOnReceiveError() bool
HasFuncHasOnReceiveError returns true if the function "WEBEXT.bluetoothSocket.onReceiveError.hasListener" exists.
func HasFuncListenUsingL2cap ¶
func HasFuncListenUsingL2cap() bool
HasFuncListenUsingL2cap returns true if the function "WEBEXT.bluetoothSocket.listenUsingL2cap" exists.
func HasFuncListenUsingRfcomm ¶
func HasFuncListenUsingRfcomm() bool
HasFuncListenUsingRfcomm returns true if the function "WEBEXT.bluetoothSocket.listenUsingRfcomm" exists.
func HasFuncOffAccept ¶
func HasFuncOffAccept() bool
HasFuncOffAccept returns true if the function "WEBEXT.bluetoothSocket.onAccept.removeListener" exists.
func HasFuncOffAcceptError ¶
func HasFuncOffAcceptError() bool
HasFuncOffAcceptError returns true if the function "WEBEXT.bluetoothSocket.onAcceptError.removeListener" exists.
func HasFuncOffReceive ¶
func HasFuncOffReceive() bool
HasFuncOffReceive returns true if the function "WEBEXT.bluetoothSocket.onReceive.removeListener" exists.
func HasFuncOffReceiveError ¶
func HasFuncOffReceiveError() bool
HasFuncOffReceiveError returns true if the function "WEBEXT.bluetoothSocket.onReceiveError.removeListener" exists.
func HasFuncOnAccept ¶
func HasFuncOnAccept() bool
HasFuncOnAccept returns true if the function "WEBEXT.bluetoothSocket.onAccept.addListener" exists.
func HasFuncOnAcceptError ¶
func HasFuncOnAcceptError() bool
HasFuncOnAcceptError returns true if the function "WEBEXT.bluetoothSocket.onAcceptError.addListener" exists.
func HasFuncOnReceive ¶
func HasFuncOnReceive() bool
HasFuncOnReceive returns true if the function "WEBEXT.bluetoothSocket.onReceive.addListener" exists.
func HasFuncOnReceiveError ¶
func HasFuncOnReceiveError() bool
HasFuncOnReceiveError returns true if the function "WEBEXT.bluetoothSocket.onReceiveError.addListener" exists.
func HasFuncSend ¶
func HasFuncSend() bool
HasFuncSend returns true if the function "WEBEXT.bluetoothSocket.send" exists.
func HasFuncSetPaused ¶
func HasFuncSetPaused() bool
HasFuncSetPaused returns true if the function "WEBEXT.bluetoothSocket.setPaused" exists.
func HasFuncUpdate ¶
func HasFuncUpdate() bool
HasFuncUpdate returns true if the function "WEBEXT.bluetoothSocket.update" exists.
func HasOnAccept ¶
func HasOnAccept(callback js.Func[func(info *AcceptInfo)]) (ret bool)
HasOnAccept calls the function "WEBEXT.bluetoothSocket.onAccept.hasListener" directly.
func HasOnAcceptError ¶
func HasOnAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret bool)
HasOnAcceptError calls the function "WEBEXT.bluetoothSocket.onAcceptError.hasListener" directly.
func HasOnReceive ¶
func HasOnReceive(callback js.Func[func(info *ReceiveInfo)]) (ret bool)
HasOnReceive calls the function "WEBEXT.bluetoothSocket.onReceive.hasListener" directly.
func HasOnReceiveError ¶
func HasOnReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret bool)
HasOnReceiveError calls the function "WEBEXT.bluetoothSocket.onReceiveError.hasListener" directly.
func ListenUsingL2cap ¶
func ListenUsingL2cap(socketId int32, uuid js.String, options ListenOptions) (ret js.Promise[js.Void])
ListenUsingL2cap calls the function "WEBEXT.bluetoothSocket.listenUsingL2cap" directly.
func ListenUsingRfcomm ¶
func ListenUsingRfcomm(socketId int32, uuid js.String, options ListenOptions) (ret js.Promise[js.Void])
ListenUsingRfcomm calls the function "WEBEXT.bluetoothSocket.listenUsingRfcomm" directly.
func OffAccept ¶
func OffAccept(callback js.Func[func(info *AcceptInfo)]) (ret js.Void)
OffAccept calls the function "WEBEXT.bluetoothSocket.onAccept.removeListener" directly.
func OffAcceptError ¶
func OffAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret js.Void)
OffAcceptError calls the function "WEBEXT.bluetoothSocket.onAcceptError.removeListener" directly.
func OffReceive ¶
func OffReceive(callback js.Func[func(info *ReceiveInfo)]) (ret js.Void)
OffReceive calls the function "WEBEXT.bluetoothSocket.onReceive.removeListener" directly.
func OffReceiveError ¶
func OffReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret js.Void)
OffReceiveError calls the function "WEBEXT.bluetoothSocket.onReceiveError.removeListener" directly.
func OnAccept ¶
func OnAccept(callback js.Func[func(info *AcceptInfo)]) (ret js.Void)
OnAccept calls the function "WEBEXT.bluetoothSocket.onAccept.addListener" directly.
func OnAcceptError ¶
func OnAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret js.Void)
OnAcceptError calls the function "WEBEXT.bluetoothSocket.onAcceptError.addListener" directly.
func OnReceive ¶
func OnReceive(callback js.Func[func(info *ReceiveInfo)]) (ret js.Void)
OnReceive calls the function "WEBEXT.bluetoothSocket.onReceive.addListener" directly.
func OnReceiveError ¶
func OnReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret js.Void)
OnReceiveError calls the function "WEBEXT.bluetoothSocket.onReceiveError.addListener" directly.
func TryClose ¶
TryClose calls the function "WEBEXT.bluetoothSocket.close" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryConnect ¶
func TryConnect(socketId int32, address js.String, uuid js.String) (ret js.Promise[js.Void], exception js.Any, ok bool)
TryConnect calls the function "WEBEXT.bluetoothSocket.connect" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryCreate ¶
func TryCreate(properties SocketProperties) (ret js.Promise[CreateInfo], exception js.Any, ok bool)
TryCreate calls the function "WEBEXT.bluetoothSocket.create" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryDisconnect ¶
TryDisconnect calls the function "WEBEXT.bluetoothSocket.disconnect" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryGetInfo ¶
TryGetInfo calls the function "WEBEXT.bluetoothSocket.getInfo" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryGetSockets ¶
TryGetSockets calls the function "WEBEXT.bluetoothSocket.getSockets" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryHasOnAccept ¶
TryHasOnAccept calls the function "WEBEXT.bluetoothSocket.onAccept.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryHasOnAcceptError ¶
func TryHasOnAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret bool, exception js.Any, ok bool)
TryHasOnAcceptError calls the function "WEBEXT.bluetoothSocket.onAcceptError.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryHasOnReceive ¶
func TryHasOnReceive(callback js.Func[func(info *ReceiveInfo)]) (ret bool, exception js.Any, ok bool)
TryHasOnReceive calls the function "WEBEXT.bluetoothSocket.onReceive.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryHasOnReceiveError ¶
func TryHasOnReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret bool, exception js.Any, ok bool)
TryHasOnReceiveError calls the function "WEBEXT.bluetoothSocket.onReceiveError.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryListenUsingL2cap ¶
func TryListenUsingL2cap(socketId int32, uuid js.String, options ListenOptions) (ret js.Promise[js.Void], exception js.Any, ok bool)
TryListenUsingL2cap calls the function "WEBEXT.bluetoothSocket.listenUsingL2cap" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryListenUsingRfcomm ¶
func TryListenUsingRfcomm(socketId int32, uuid js.String, options ListenOptions) (ret js.Promise[js.Void], exception js.Any, ok bool)
TryListenUsingRfcomm calls the function "WEBEXT.bluetoothSocket.listenUsingRfcomm" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOffAccept ¶
func TryOffAccept(callback js.Func[func(info *AcceptInfo)]) (ret js.Void, exception js.Any, ok bool)
TryOffAccept calls the function "WEBEXT.bluetoothSocket.onAccept.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOffAcceptError ¶
func TryOffAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret js.Void, exception js.Any, ok bool)
TryOffAcceptError calls the function "WEBEXT.bluetoothSocket.onAcceptError.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOffReceive ¶
func TryOffReceive(callback js.Func[func(info *ReceiveInfo)]) (ret js.Void, exception js.Any, ok bool)
TryOffReceive calls the function "WEBEXT.bluetoothSocket.onReceive.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOffReceiveError ¶
func TryOffReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret js.Void, exception js.Any, ok bool)
TryOffReceiveError calls the function "WEBEXT.bluetoothSocket.onReceiveError.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOnAccept ¶
TryOnAccept calls the function "WEBEXT.bluetoothSocket.onAccept.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOnAcceptError ¶
func TryOnAcceptError(callback js.Func[func(info *AcceptErrorInfo)]) (ret js.Void, exception js.Any, ok bool)
TryOnAcceptError calls the function "WEBEXT.bluetoothSocket.onAcceptError.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOnReceive ¶
func TryOnReceive(callback js.Func[func(info *ReceiveInfo)]) (ret js.Void, exception js.Any, ok bool)
TryOnReceive calls the function "WEBEXT.bluetoothSocket.onReceive.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOnReceiveError ¶
func TryOnReceiveError(callback js.Func[func(info *ReceiveErrorInfo)]) (ret js.Void, exception js.Any, ok bool)
TryOnReceiveError calls the function "WEBEXT.bluetoothSocket.onReceiveError.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TrySend ¶
func TrySend(socketId int32, data js.ArrayBuffer) (ret js.Promise[js.Number[int32]], exception js.Any, ok bool)
TrySend calls the function "WEBEXT.bluetoothSocket.send" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TrySetPaused ¶
TrySetPaused calls the function "WEBEXT.bluetoothSocket.setPaused" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
Types ¶
type AcceptError ¶
type AcceptError uint32
const ( AcceptError_SYSTEM_ERROR AcceptError AcceptError_NOT_LISTENING )
func (AcceptError) FromRef ¶
func (AcceptError) FromRef(str js.Ref) AcceptError
func (AcceptError) String ¶
func (x AcceptError) String() (string, bool)
type AcceptErrorInfo ¶
type AcceptErrorInfo struct {
// SocketId is "AcceptErrorInfo.socketId"
//
// Optional
//
// NOTE: FFI_USE_SocketId MUST be set to true to make this field effective.
SocketId int32
// ErrorMessage is "AcceptErrorInfo.errorMessage"
//
// Optional
ErrorMessage js.String
// Error is "AcceptErrorInfo.error"
//
// Optional
Error AcceptError
FFI_USE_SocketId bool // for SocketId.
FFI_USE bool
}
func (*AcceptErrorInfo) FreeMembers ¶
func (p *AcceptErrorInfo) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (AcceptErrorInfo) FromRef ¶
func (p AcceptErrorInfo) FromRef(ref js.Ref) AcceptErrorInfo
FromRef calls UpdateFrom and returns a AcceptErrorInfo with all fields set.
func (AcceptErrorInfo) New ¶
func (p AcceptErrorInfo) New() js.Ref
New creates a new AcceptErrorInfo in the application heap.
func (*AcceptErrorInfo) Update ¶
func (p *AcceptErrorInfo) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*AcceptErrorInfo) UpdateFrom ¶
func (p *AcceptErrorInfo) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type AcceptInfo ¶
type AcceptInfo struct {
// SocketId is "AcceptInfo.socketId"
//
// Optional
//
// NOTE: FFI_USE_SocketId MUST be set to true to make this field effective.
SocketId int32
// ClientSocketId is "AcceptInfo.clientSocketId"
//
// Optional
//
// NOTE: FFI_USE_ClientSocketId MUST be set to true to make this field effective.
ClientSocketId int32
FFI_USE_SocketId bool // for SocketId.
FFI_USE_ClientSocketId bool // for ClientSocketId.
FFI_USE bool
}
func (*AcceptInfo) FreeMembers ¶
func (p *AcceptInfo) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (AcceptInfo) FromRef ¶
func (p AcceptInfo) FromRef(ref js.Ref) AcceptInfo
FromRef calls UpdateFrom and returns a AcceptInfo with all fields set.
func (AcceptInfo) New ¶
func (p AcceptInfo) New() js.Ref
New creates a new AcceptInfo in the application heap.
func (*AcceptInfo) Update ¶
func (p *AcceptInfo) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*AcceptInfo) UpdateFrom ¶
func (p *AcceptInfo) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type CloseCallback ¶
func (*CloseCallback[T]) DispatchCallback ¶
func (cb *CloseCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*CloseCallback[T]) Register ¶
func (cb *CloseCallback[T]) Register() js.Func[func()]
type CloseCallbackFunc ¶
func (CloseCallbackFunc) DispatchCallback ¶
func (fn CloseCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (CloseCallbackFunc) Register ¶
func (fn CloseCallbackFunc) Register() js.Func[func()]
type ConnectCallback ¶
func (*ConnectCallback[T]) DispatchCallback ¶
func (cb *ConnectCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*ConnectCallback[T]) Register ¶
func (cb *ConnectCallback[T]) Register() js.Func[func()]
type ConnectCallbackFunc ¶
func (ConnectCallbackFunc) DispatchCallback ¶
func (fn ConnectCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (ConnectCallbackFunc) Register ¶
func (fn ConnectCallbackFunc) Register() js.Func[func()]
type CreateCallback ¶
type CreateCallback[T any] struct { Fn func(arg T, this js.Ref, createInfo *CreateInfo) js.Ref Arg T }
func (*CreateCallback[T]) DispatchCallback ¶
func (cb *CreateCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*CreateCallback[T]) Register ¶
func (cb *CreateCallback[T]) Register() js.Func[func(createInfo *CreateInfo)]
type CreateCallbackFunc ¶
type CreateCallbackFunc func(this js.Ref, createInfo *CreateInfo) js.Ref
func (CreateCallbackFunc) DispatchCallback ¶
func (fn CreateCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (CreateCallbackFunc) Register ¶
func (fn CreateCallbackFunc) Register() js.Func[func(createInfo *CreateInfo)]
type CreateInfo ¶
type CreateInfo struct {
// SocketId is "CreateInfo.socketId"
//
// Optional
//
// NOTE: FFI_USE_SocketId MUST be set to true to make this field effective.
SocketId int32
FFI_USE_SocketId bool // for SocketId.
FFI_USE bool
}
func (*CreateInfo) FreeMembers ¶
func (p *CreateInfo) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (CreateInfo) FromRef ¶
func (p CreateInfo) FromRef(ref js.Ref) CreateInfo
FromRef calls UpdateFrom and returns a CreateInfo with all fields set.
func (CreateInfo) New ¶
func (p CreateInfo) New() js.Ref
New creates a new CreateInfo in the application heap.
func (*CreateInfo) Update ¶
func (p *CreateInfo) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*CreateInfo) UpdateFrom ¶
func (p *CreateInfo) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type DisconnectCallback ¶
func (*DisconnectCallback[T]) DispatchCallback ¶
func (cb *DisconnectCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*DisconnectCallback[T]) Register ¶
func (cb *DisconnectCallback[T]) Register() js.Func[func()]
type DisconnectCallbackFunc ¶
func (DisconnectCallbackFunc) DispatchCallback ¶
func (fn DisconnectCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (DisconnectCallbackFunc) Register ¶
func (fn DisconnectCallbackFunc) Register() js.Func[func()]
type GetInfoCallback ¶
type GetInfoCallback[T any] struct { Fn func(arg T, this js.Ref, socketInfo *SocketInfo) js.Ref Arg T }
func (*GetInfoCallback[T]) DispatchCallback ¶
func (cb *GetInfoCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*GetInfoCallback[T]) Register ¶
func (cb *GetInfoCallback[T]) Register() js.Func[func(socketInfo *SocketInfo)]
type GetInfoCallbackFunc ¶
type GetInfoCallbackFunc func(this js.Ref, socketInfo *SocketInfo) js.Ref
func (GetInfoCallbackFunc) DispatchCallback ¶
func (fn GetInfoCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (GetInfoCallbackFunc) Register ¶
func (fn GetInfoCallbackFunc) Register() js.Func[func(socketInfo *SocketInfo)]
type GetSocketsCallback ¶
type GetSocketsCallback[T any] struct { Fn func(arg T, this js.Ref, sockets js.Array[SocketInfo]) js.Ref Arg T }
func (*GetSocketsCallback[T]) DispatchCallback ¶
func (cb *GetSocketsCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*GetSocketsCallback[T]) Register ¶
func (cb *GetSocketsCallback[T]) Register() js.Func[func(sockets js.Array[SocketInfo])]
type GetSocketsCallbackFunc ¶
func (GetSocketsCallbackFunc) DispatchCallback ¶
func (fn GetSocketsCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (GetSocketsCallbackFunc) Register ¶
func (fn GetSocketsCallbackFunc) Register() js.Func[func(sockets js.Array[SocketInfo])]
type ListenCallback ¶
func (*ListenCallback[T]) DispatchCallback ¶
func (cb *ListenCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*ListenCallback[T]) Register ¶
func (cb *ListenCallback[T]) Register() js.Func[func()]
type ListenCallbackFunc ¶
func (ListenCallbackFunc) DispatchCallback ¶
func (fn ListenCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (ListenCallbackFunc) Register ¶
func (fn ListenCallbackFunc) Register() js.Func[func()]
type ListenOptions ¶
type ListenOptions struct {
// Channel is "ListenOptions.channel"
//
// Optional
//
// NOTE: FFI_USE_Channel MUST be set to true to make this field effective.
Channel int32
// Psm is "ListenOptions.psm"
//
// Optional
//
// NOTE: FFI_USE_Psm MUST be set to true to make this field effective.
Psm int32
// Backlog is "ListenOptions.backlog"
//
// Optional
//
// NOTE: FFI_USE_Backlog MUST be set to true to make this field effective.
Backlog int32
FFI_USE_Channel bool // for Channel.
FFI_USE_Psm bool // for Psm.
FFI_USE_Backlog bool // for Backlog.
FFI_USE bool
}
func (*ListenOptions) FreeMembers ¶
func (p *ListenOptions) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (ListenOptions) FromRef ¶
func (p ListenOptions) FromRef(ref js.Ref) ListenOptions
FromRef calls UpdateFrom and returns a ListenOptions with all fields set.
func (ListenOptions) New ¶
func (p ListenOptions) New() js.Ref
New creates a new ListenOptions in the application heap.
func (*ListenOptions) Update ¶
func (p *ListenOptions) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*ListenOptions) UpdateFrom ¶
func (p *ListenOptions) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type OnAcceptErrorEventCallback ¶
type OnAcceptErrorEventCallback[T any] struct { Fn func(arg T, this js.Ref, info *AcceptErrorInfo) js.Ref Arg T }
func (*OnAcceptErrorEventCallback[T]) DispatchCallback ¶
func (cb *OnAcceptErrorEventCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*OnAcceptErrorEventCallback[T]) Register ¶
func (cb *OnAcceptErrorEventCallback[T]) Register() js.Func[func(info *AcceptErrorInfo)]
type OnAcceptErrorEventCallbackFunc ¶
type OnAcceptErrorEventCallbackFunc func(this js.Ref, info *AcceptErrorInfo) js.Ref
func (OnAcceptErrorEventCallbackFunc) DispatchCallback ¶
func (fn OnAcceptErrorEventCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (OnAcceptErrorEventCallbackFunc) Register ¶
func (fn OnAcceptErrorEventCallbackFunc) Register() js.Func[func(info *AcceptErrorInfo)]
type OnAcceptEventCallback ¶
type OnAcceptEventCallback[T any] struct { Fn func(arg T, this js.Ref, info *AcceptInfo) js.Ref Arg T }
func (*OnAcceptEventCallback[T]) DispatchCallback ¶
func (cb *OnAcceptEventCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*OnAcceptEventCallback[T]) Register ¶
func (cb *OnAcceptEventCallback[T]) Register() js.Func[func(info *AcceptInfo)]
type OnAcceptEventCallbackFunc ¶
type OnAcceptEventCallbackFunc func(this js.Ref, info *AcceptInfo) js.Ref
func (OnAcceptEventCallbackFunc) DispatchCallback ¶
func (fn OnAcceptEventCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (OnAcceptEventCallbackFunc) Register ¶
func (fn OnAcceptEventCallbackFunc) Register() js.Func[func(info *AcceptInfo)]
type OnReceiveErrorEventCallback ¶
type OnReceiveErrorEventCallback[T any] struct { Fn func(arg T, this js.Ref, info *ReceiveErrorInfo) js.Ref Arg T }
func (*OnReceiveErrorEventCallback[T]) DispatchCallback ¶
func (cb *OnReceiveErrorEventCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*OnReceiveErrorEventCallback[T]) Register ¶
func (cb *OnReceiveErrorEventCallback[T]) Register() js.Func[func(info *ReceiveErrorInfo)]
type OnReceiveErrorEventCallbackFunc ¶
type OnReceiveErrorEventCallbackFunc func(this js.Ref, info *ReceiveErrorInfo) js.Ref
func (OnReceiveErrorEventCallbackFunc) DispatchCallback ¶
func (fn OnReceiveErrorEventCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (OnReceiveErrorEventCallbackFunc) Register ¶
func (fn OnReceiveErrorEventCallbackFunc) Register() js.Func[func(info *ReceiveErrorInfo)]
type OnReceiveEventCallback ¶
type OnReceiveEventCallback[T any] struct { Fn func(arg T, this js.Ref, info *ReceiveInfo) js.Ref Arg T }
func (*OnReceiveEventCallback[T]) DispatchCallback ¶
func (cb *OnReceiveEventCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*OnReceiveEventCallback[T]) Register ¶
func (cb *OnReceiveEventCallback[T]) Register() js.Func[func(info *ReceiveInfo)]
type OnReceiveEventCallbackFunc ¶
type OnReceiveEventCallbackFunc func(this js.Ref, info *ReceiveInfo) js.Ref
func (OnReceiveEventCallbackFunc) DispatchCallback ¶
func (fn OnReceiveEventCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (OnReceiveEventCallbackFunc) Register ¶
func (fn OnReceiveEventCallbackFunc) Register() js.Func[func(info *ReceiveInfo)]
type ReceiveError ¶
type ReceiveError uint32
const ( ReceiveError_DISCONNECTED ReceiveError ReceiveError_SYSTEM_ERROR ReceiveError_NOT_CONNECTED )
func (ReceiveError) FromRef ¶
func (ReceiveError) FromRef(str js.Ref) ReceiveError
func (ReceiveError) String ¶
func (x ReceiveError) String() (string, bool)
type ReceiveErrorInfo ¶
type ReceiveErrorInfo struct {
// SocketId is "ReceiveErrorInfo.socketId"
//
// Optional
//
// NOTE: FFI_USE_SocketId MUST be set to true to make this field effective.
SocketId int32
// ErrorMessage is "ReceiveErrorInfo.errorMessage"
//
// Optional
ErrorMessage js.String
// Error is "ReceiveErrorInfo.error"
//
// Optional
Error ReceiveError
FFI_USE_SocketId bool // for SocketId.
FFI_USE bool
}
func (*ReceiveErrorInfo) FreeMembers ¶
func (p *ReceiveErrorInfo) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (ReceiveErrorInfo) FromRef ¶
func (p ReceiveErrorInfo) FromRef(ref js.Ref) ReceiveErrorInfo
FromRef calls UpdateFrom and returns a ReceiveErrorInfo with all fields set.
func (ReceiveErrorInfo) New ¶
func (p ReceiveErrorInfo) New() js.Ref
New creates a new ReceiveErrorInfo in the application heap.
func (*ReceiveErrorInfo) Update ¶
func (p *ReceiveErrorInfo) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*ReceiveErrorInfo) UpdateFrom ¶
func (p *ReceiveErrorInfo) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type ReceiveInfo ¶
type ReceiveInfo struct {
// SocketId is "ReceiveInfo.socketId"
//
// Optional
//
// NOTE: FFI_USE_SocketId MUST be set to true to make this field effective.
SocketId int32
// Data is "ReceiveInfo.data"
//
// Optional
Data js.ArrayBuffer
FFI_USE_SocketId bool // for SocketId.
FFI_USE bool
}
func (*ReceiveInfo) FreeMembers ¶
func (p *ReceiveInfo) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (ReceiveInfo) FromRef ¶
func (p ReceiveInfo) FromRef(ref js.Ref) ReceiveInfo
FromRef calls UpdateFrom and returns a ReceiveInfo with all fields set.
func (ReceiveInfo) New ¶
func (p ReceiveInfo) New() js.Ref
New creates a new ReceiveInfo in the application heap.
func (*ReceiveInfo) Update ¶
func (p *ReceiveInfo) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*ReceiveInfo) UpdateFrom ¶
func (p *ReceiveInfo) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type SendCallback ¶
func (*SendCallback[T]) DispatchCallback ¶
func (cb *SendCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
type SendCallbackFunc ¶
func (SendCallbackFunc) DispatchCallback ¶
func (fn SendCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
type SetPausedCallback ¶
func (*SetPausedCallback[T]) DispatchCallback ¶
func (cb *SetPausedCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*SetPausedCallback[T]) Register ¶
func (cb *SetPausedCallback[T]) Register() js.Func[func()]
type SetPausedCallbackFunc ¶
func (SetPausedCallbackFunc) DispatchCallback ¶
func (fn SetPausedCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (SetPausedCallbackFunc) Register ¶
func (fn SetPausedCallbackFunc) Register() js.Func[func()]
type SocketInfo ¶
type SocketInfo struct {
// SocketId is "SocketInfo.socketId"
//
// Optional
//
// NOTE: FFI_USE_SocketId MUST be set to true to make this field effective.
SocketId int32
// Persistent is "SocketInfo.persistent"
//
// Optional
//
// NOTE: FFI_USE_Persistent MUST be set to true to make this field effective.
Persistent bool
// Name is "SocketInfo.name"
//
// Optional
Name js.String
// BufferSize is "SocketInfo.bufferSize"
//
// Optional
//
// NOTE: FFI_USE_BufferSize MUST be set to true to make this field effective.
BufferSize int32
// Paused is "SocketInfo.paused"
//
// Optional
//
// NOTE: FFI_USE_Paused MUST be set to true to make this field effective.
Paused bool
// Connected is "SocketInfo.connected"
//
// Optional
//
// NOTE: FFI_USE_Connected MUST be set to true to make this field effective.
Connected bool
// Address is "SocketInfo.address"
//
// Optional
Address js.String
// Uuid is "SocketInfo.uuid"
//
// Optional
Uuid js.String
FFI_USE_SocketId bool // for SocketId.
FFI_USE_Persistent bool // for Persistent.
FFI_USE_BufferSize bool // for BufferSize.
FFI_USE_Paused bool // for Paused.
FFI_USE_Connected bool // for Connected.
FFI_USE bool
}
func (*SocketInfo) FreeMembers ¶
func (p *SocketInfo) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (SocketInfo) FromRef ¶
func (p SocketInfo) FromRef(ref js.Ref) SocketInfo
FromRef calls UpdateFrom and returns a SocketInfo with all fields set.
func (SocketInfo) New ¶
func (p SocketInfo) New() js.Ref
New creates a new SocketInfo in the application heap.
func (*SocketInfo) Update ¶
func (p *SocketInfo) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*SocketInfo) UpdateFrom ¶
func (p *SocketInfo) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type SocketProperties ¶
type SocketProperties struct {
// Persistent is "SocketProperties.persistent"
//
// Optional
//
// NOTE: FFI_USE_Persistent MUST be set to true to make this field effective.
Persistent bool
// Name is "SocketProperties.name"
//
// Optional
Name js.String
// BufferSize is "SocketProperties.bufferSize"
//
// Optional
//
// NOTE: FFI_USE_BufferSize MUST be set to true to make this field effective.
BufferSize int32
FFI_USE_Persistent bool // for Persistent.
FFI_USE_BufferSize bool // for BufferSize.
FFI_USE bool
}
func (*SocketProperties) FreeMembers ¶
func (p *SocketProperties) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (SocketProperties) FromRef ¶
func (p SocketProperties) FromRef(ref js.Ref) SocketProperties
FromRef calls UpdateFrom and returns a SocketProperties with all fields set.
func (SocketProperties) New ¶
func (p SocketProperties) New() js.Ref
New creates a new SocketProperties in the application heap.
func (*SocketProperties) Update ¶
func (p *SocketProperties) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*SocketProperties) UpdateFrom ¶
func (p *SocketProperties) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type UpdateCallback ¶
func (*UpdateCallback[T]) DispatchCallback ¶
func (cb *UpdateCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*UpdateCallback[T]) Register ¶
func (cb *UpdateCallback[T]) Register() js.Func[func()]
type UpdateCallbackFunc ¶
func (UpdateCallbackFunc) DispatchCallback ¶
func (fn UpdateCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (UpdateCallbackFunc) Register ¶
func (fn UpdateCallbackFunc) Register() js.Func[func()]