Documentation
¶
Index ¶
- func Create() (ret js.Promise[DataItemInfo])
- func Delete(id js.String) (ret js.Promise[js.Void])
- func FuncCreate() (fn js.Func[func() js.Promise[DataItemInfo]])
- func FuncDelete() (fn js.Func[func(id js.String) js.Promise[js.Void]])
- func FuncGetAll() (fn js.Func[func() js.Promise[js.Array[DataItemInfo]]])
- func FuncGetContent() (fn js.Func[func(id js.String) js.Promise[js.ArrayBuffer]])
- func FuncHasOnDataItemsAvailable() (fn js.Func[func(callback js.Func[func(event *DataItemsAvailableEvent)]) bool])
- func FuncOffDataItemsAvailable() (fn js.Func[func(callback js.Func[func(event *DataItemsAvailableEvent)])])
- func FuncOnDataItemsAvailable() (fn js.Func[func(callback js.Func[func(event *DataItemsAvailableEvent)])])
- func FuncSetContent() (fn js.Func[func(id js.String, data js.ArrayBuffer) js.Promise[js.Void]])
- func GetAll() (ret js.Promise[js.Array[DataItemInfo]])
- func GetContent(id js.String) (ret js.Promise[js.ArrayBuffer])
- func HasFuncCreate() bool
- func HasFuncDelete() bool
- func HasFuncGetAll() bool
- func HasFuncGetContent() bool
- func HasFuncHasOnDataItemsAvailable() bool
- func HasFuncOffDataItemsAvailable() bool
- func HasFuncOnDataItemsAvailable() bool
- func HasFuncSetContent() bool
- func HasOnDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret bool)
- func OffDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret js.Void)
- func OnDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret js.Void)
- func SetContent(id js.String, data js.ArrayBuffer) (ret js.Promise[js.Void])
- func TryCreate() (ret js.Promise[DataItemInfo], exception js.Any, ok bool)
- func TryDelete(id js.String) (ret js.Promise[js.Void], exception js.Any, ok bool)
- func TryGetAll() (ret js.Promise[js.Array[DataItemInfo]], exception js.Any, ok bool)
- func TryGetContent(id js.String) (ret js.Promise[js.ArrayBuffer], exception js.Any, ok bool)
- func TryHasOnDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret bool, exception js.Any, ok bool)
- func TryOffDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret js.Void, exception js.Any, ok bool)
- func TryOnDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret js.Void, exception js.Any, ok bool)
- func TrySetContent(id js.String, data js.ArrayBuffer) (ret js.Promise[js.Void], exception js.Any, ok bool)
- type DataCallback
- type DataCallbackFunc
- type DataItemCallback
- type DataItemCallbackFunc
- type DataItemInfo
- type DataItemListCallback
- type DataItemListCallbackFunc
- type DataItemsAvailableEvent
- type OnDataItemsAvailableEventCallback
- type OnDataItemsAvailableEventCallbackFunc
- type VoidCallback
- type VoidCallbackFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Create ¶
func Create() (ret js.Promise[DataItemInfo])
Create calls the function "WEBEXT.lockScreen.data.create" directly.
func FuncCreate ¶
func FuncCreate() (fn js.Func[func() js.Promise[DataItemInfo]])
FuncCreate returns the function "WEBEXT.lockScreen.data.create".
func FuncDelete ¶
FuncDelete returns the function "WEBEXT.lockScreen.data.delete".
func FuncGetAll ¶
FuncGetAll returns the function "WEBEXT.lockScreen.data.getAll".
func FuncGetContent ¶
FuncGetContent returns the function "WEBEXT.lockScreen.data.getContent".
func FuncHasOnDataItemsAvailable ¶
func FuncHasOnDataItemsAvailable() (fn js.Func[func(callback js.Func[func(event *DataItemsAvailableEvent)]) bool])
FuncHasOnDataItemsAvailable returns the function "WEBEXT.lockScreen.data.onDataItemsAvailable.hasListener".
func FuncOffDataItemsAvailable ¶
func FuncOffDataItemsAvailable() (fn js.Func[func(callback js.Func[func(event *DataItemsAvailableEvent)])])
FuncOffDataItemsAvailable returns the function "WEBEXT.lockScreen.data.onDataItemsAvailable.removeListener".
func FuncOnDataItemsAvailable ¶
func FuncOnDataItemsAvailable() (fn js.Func[func(callback js.Func[func(event *DataItemsAvailableEvent)])])
FuncOnDataItemsAvailable returns the function "WEBEXT.lockScreen.data.onDataItemsAvailable.addListener".
func FuncSetContent ¶
FuncSetContent returns the function "WEBEXT.lockScreen.data.setContent".
func GetAll ¶
func GetAll() (ret js.Promise[js.Array[DataItemInfo]])
GetAll calls the function "WEBEXT.lockScreen.data.getAll" directly.
func GetContent ¶
GetContent calls the function "WEBEXT.lockScreen.data.getContent" directly.
func HasFuncCreate ¶
func HasFuncCreate() bool
HasFuncCreate returns true if the function "WEBEXT.lockScreen.data.create" exists.
func HasFuncDelete ¶
func HasFuncDelete() bool
HasFuncDelete returns true if the function "WEBEXT.lockScreen.data.delete" exists.
func HasFuncGetAll ¶
func HasFuncGetAll() bool
HasFuncGetAll returns true if the function "WEBEXT.lockScreen.data.getAll" exists.
func HasFuncGetContent ¶
func HasFuncGetContent() bool
HasFuncGetContent returns true if the function "WEBEXT.lockScreen.data.getContent" exists.
func HasFuncHasOnDataItemsAvailable ¶
func HasFuncHasOnDataItemsAvailable() bool
HasFuncHasOnDataItemsAvailable returns true if the function "WEBEXT.lockScreen.data.onDataItemsAvailable.hasListener" exists.
func HasFuncOffDataItemsAvailable ¶
func HasFuncOffDataItemsAvailable() bool
HasFuncOffDataItemsAvailable returns true if the function "WEBEXT.lockScreen.data.onDataItemsAvailable.removeListener" exists.
func HasFuncOnDataItemsAvailable ¶
func HasFuncOnDataItemsAvailable() bool
HasFuncOnDataItemsAvailable returns true if the function "WEBEXT.lockScreen.data.onDataItemsAvailable.addListener" exists.
func HasFuncSetContent ¶
func HasFuncSetContent() bool
HasFuncSetContent returns true if the function "WEBEXT.lockScreen.data.setContent" exists.
func HasOnDataItemsAvailable ¶
func HasOnDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret bool)
HasOnDataItemsAvailable calls the function "WEBEXT.lockScreen.data.onDataItemsAvailable.hasListener" directly.
func OffDataItemsAvailable ¶
func OffDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret js.Void)
OffDataItemsAvailable calls the function "WEBEXT.lockScreen.data.onDataItemsAvailable.removeListener" directly.
func OnDataItemsAvailable ¶
func OnDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret js.Void)
OnDataItemsAvailable calls the function "WEBEXT.lockScreen.data.onDataItemsAvailable.addListener" directly.
func SetContent ¶
SetContent calls the function "WEBEXT.lockScreen.data.setContent" directly.
func TryCreate ¶
TryCreate calls the function "WEBEXT.lockScreen.data.create" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryDelete ¶
TryDelete calls the function "WEBEXT.lockScreen.data.delete" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryGetAll ¶
TryGetAll calls the function "WEBEXT.lockScreen.data.getAll" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryGetContent ¶
TryGetContent calls the function "WEBEXT.lockScreen.data.getContent" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryHasOnDataItemsAvailable ¶
func TryHasOnDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret bool, exception js.Any, ok bool)
TryHasOnDataItemsAvailable calls the function "WEBEXT.lockScreen.data.onDataItemsAvailable.hasListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOffDataItemsAvailable ¶
func TryOffDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret js.Void, exception js.Any, ok bool)
TryOffDataItemsAvailable calls the function "WEBEXT.lockScreen.data.onDataItemsAvailable.removeListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
func TryOnDataItemsAvailable ¶
func TryOnDataItemsAvailable(callback js.Func[func(event *DataItemsAvailableEvent)]) (ret js.Void, exception js.Any, ok bool)
TryOnDataItemsAvailable calls the function "WEBEXT.lockScreen.data.onDataItemsAvailable.addListener" in a try/catch block and returns (_, err, ok = false) when it went through the catch clause.
Types ¶
type DataCallback ¶
func (*DataCallback[T]) DispatchCallback ¶
func (cb *DataCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*DataCallback[T]) Register ¶
func (cb *DataCallback[T]) Register() js.Func[func(data js.ArrayBuffer)]
type DataCallbackFunc ¶
func (DataCallbackFunc) DispatchCallback ¶
func (fn DataCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (DataCallbackFunc) Register ¶
func (fn DataCallbackFunc) Register() js.Func[func(data js.ArrayBuffer)]
type DataItemCallback ¶
type DataItemCallback[T any] struct { Fn func(arg T, this js.Ref, item *DataItemInfo) js.Ref Arg T }
func (*DataItemCallback[T]) DispatchCallback ¶
func (cb *DataItemCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*DataItemCallback[T]) Register ¶
func (cb *DataItemCallback[T]) Register() js.Func[func(item *DataItemInfo)]
type DataItemCallbackFunc ¶
type DataItemCallbackFunc func(this js.Ref, item *DataItemInfo) js.Ref
func (DataItemCallbackFunc) DispatchCallback ¶
func (fn DataItemCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (DataItemCallbackFunc) Register ¶
func (fn DataItemCallbackFunc) Register() js.Func[func(item *DataItemInfo)]
type DataItemInfo ¶
func (*DataItemInfo) FreeMembers ¶
func (p *DataItemInfo) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (DataItemInfo) FromRef ¶
func (p DataItemInfo) FromRef(ref js.Ref) DataItemInfo
FromRef calls UpdateFrom and returns a DataItemInfo with all fields set.
func (DataItemInfo) New ¶
func (p DataItemInfo) New() js.Ref
New creates a new DataItemInfo in the application heap.
func (*DataItemInfo) Update ¶
func (p *DataItemInfo) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*DataItemInfo) UpdateFrom ¶
func (p *DataItemInfo) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type DataItemListCallback ¶
type DataItemListCallback[T any] struct { Fn func(arg T, this js.Ref, items js.Array[DataItemInfo]) js.Ref Arg T }
func (*DataItemListCallback[T]) DispatchCallback ¶
func (cb *DataItemListCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*DataItemListCallback[T]) Register ¶
func (cb *DataItemListCallback[T]) Register() js.Func[func(items js.Array[DataItemInfo])]
type DataItemListCallbackFunc ¶
func (DataItemListCallbackFunc) DispatchCallback ¶
func (fn DataItemListCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (DataItemListCallbackFunc) Register ¶
func (fn DataItemListCallbackFunc) Register() js.Func[func(items js.Array[DataItemInfo])]
type DataItemsAvailableEvent ¶
type DataItemsAvailableEvent struct {
// WasLocked is "DataItemsAvailableEvent.wasLocked"
//
// Optional
//
// NOTE: FFI_USE_WasLocked MUST be set to true to make this field effective.
WasLocked bool
FFI_USE_WasLocked bool // for WasLocked.
FFI_USE bool
}
func (*DataItemsAvailableEvent) FreeMembers ¶
func (p *DataItemsAvailableEvent) FreeMembers(recursive bool)
FreeMembers frees fields with heap reference, if recursive is true free all heap references reachable from p.
func (DataItemsAvailableEvent) FromRef ¶
func (p DataItemsAvailableEvent) FromRef(ref js.Ref) DataItemsAvailableEvent
FromRef calls UpdateFrom and returns a DataItemsAvailableEvent with all fields set.
func (DataItemsAvailableEvent) New ¶
func (p DataItemsAvailableEvent) New() js.Ref
New creates a new DataItemsAvailableEvent in the application heap.
func (*DataItemsAvailableEvent) Update ¶
func (p *DataItemsAvailableEvent) Update(ref js.Ref)
Update writes all fields of the p to the heap object referenced by ref.
func (*DataItemsAvailableEvent) UpdateFrom ¶
func (p *DataItemsAvailableEvent) UpdateFrom(ref js.Ref)
UpdateFrom copies value of all fields of the heap object to p.
type OnDataItemsAvailableEventCallback ¶
type OnDataItemsAvailableEventCallback[T any] struct { Fn func(arg T, this js.Ref, event *DataItemsAvailableEvent) js.Ref Arg T }
func (*OnDataItemsAvailableEventCallback[T]) DispatchCallback ¶
func (cb *OnDataItemsAvailableEventCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*OnDataItemsAvailableEventCallback[T]) Register ¶
func (cb *OnDataItemsAvailableEventCallback[T]) Register() js.Func[func(event *DataItemsAvailableEvent)]
type OnDataItemsAvailableEventCallbackFunc ¶
type OnDataItemsAvailableEventCallbackFunc func(this js.Ref, event *DataItemsAvailableEvent) js.Ref
func (OnDataItemsAvailableEventCallbackFunc) DispatchCallback ¶
func (fn OnDataItemsAvailableEventCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (OnDataItemsAvailableEventCallbackFunc) Register ¶
func (fn OnDataItemsAvailableEventCallbackFunc) Register() js.Func[func(event *DataItemsAvailableEvent)]
type VoidCallback ¶
func (*VoidCallback[T]) DispatchCallback ¶
func (cb *VoidCallback[T]) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (*VoidCallback[T]) Register ¶
func (cb *VoidCallback[T]) Register() js.Func[func()]
type VoidCallbackFunc ¶
func (VoidCallbackFunc) DispatchCallback ¶
func (fn VoidCallbackFunc) DispatchCallback( targetPC uintptr, ctx *js.CallbackContext, )
func (VoidCallbackFunc) Register ¶
func (fn VoidCallbackFunc) Register() js.Func[func()]