github.com/primecitizens/pcz/std@v0.2.1/plat/js/webext/bluetooth/bindings/import_wasm.go (about) 1 // SPDX-License-Identifier: Apache-2.0 2 // Copyright 2023 The Prime Citizens 3 4 //go:build wasm 5 6 package bindings 7 8 import ( 9 "unsafe" 10 11 "github.com/primecitizens/pcz/std/ffi/js" 12 ) 13 14 type ( 15 _ unsafe.Pointer 16 _ js.Ref 17 ) 18 19 //go:wasmimport plat/js/webext/bluetooth store_AdapterState 20 //go:noescape 21 func AdapterStateJSStore( 22 ptr unsafe.Pointer, ref js.Ref) 23 24 //go:wasmimport plat/js/webext/bluetooth load_AdapterState 25 //go:noescape 26 func AdapterStateJSLoad( 27 ptr unsafe.Pointer, create, ref js.Ref) js.Ref 28 29 //go:wasmimport plat/js/webext/bluetooth constof_FilterType 30 //go:noescape 31 func ConstOfFilterType(str js.Ref) uint32 32 33 //go:wasmimport plat/js/webext/bluetooth store_BluetoothFilter 34 //go:noescape 35 func BluetoothFilterJSStore( 36 ptr unsafe.Pointer, ref js.Ref) 37 38 //go:wasmimport plat/js/webext/bluetooth load_BluetoothFilter 39 //go:noescape 40 func BluetoothFilterJSLoad( 41 ptr unsafe.Pointer, create, ref js.Ref) js.Ref 42 43 //go:wasmimport plat/js/webext/bluetooth constof_VendorIdSource 44 //go:noescape 45 func ConstOfVendorIdSource(str js.Ref) uint32 46 47 //go:wasmimport plat/js/webext/bluetooth constof_DeviceType 48 //go:noescape 49 func ConstOfDeviceType(str js.Ref) uint32 50 51 //go:wasmimport plat/js/webext/bluetooth constof_Transport 52 //go:noescape 53 func ConstOfTransport(str js.Ref) uint32 54 55 //go:wasmimport plat/js/webext/bluetooth store_Device 56 //go:noescape 57 func DeviceJSStore( 58 ptr unsafe.Pointer, ref js.Ref) 59 60 //go:wasmimport plat/js/webext/bluetooth load_Device 61 //go:noescape 62 func DeviceJSLoad( 63 ptr unsafe.Pointer, create, ref js.Ref) js.Ref 64 65 //go:wasmimport plat/js/webext/bluetooth has_GetAdapterState 66 //go:noescape 67 func HasFuncGetAdapterState() js.Ref 68 69 //go:wasmimport plat/js/webext/bluetooth func_GetAdapterState 70 //go:noescape 71 func FuncGetAdapterState(fn unsafe.Pointer) 72 73 //go:wasmimport plat/js/webext/bluetooth call_GetAdapterState 74 //go:noescape 75 func CallGetAdapterState( 76 retPtr unsafe.Pointer) 77 78 //go:wasmimport plat/js/webext/bluetooth try_GetAdapterState 79 //go:noescape 80 func TryGetAdapterState( 81 retPtr unsafe.Pointer, errPtr unsafe.Pointer) (ok js.Ref) 82 83 //go:wasmimport plat/js/webext/bluetooth has_GetDevice 84 //go:noescape 85 func HasFuncGetDevice() js.Ref 86 87 //go:wasmimport plat/js/webext/bluetooth func_GetDevice 88 //go:noescape 89 func FuncGetDevice(fn unsafe.Pointer) 90 91 //go:wasmimport plat/js/webext/bluetooth call_GetDevice 92 //go:noescape 93 func CallGetDevice( 94 retPtr unsafe.Pointer, 95 deviceAddress js.Ref) 96 97 //go:wasmimport plat/js/webext/bluetooth try_GetDevice 98 //go:noescape 99 func TryGetDevice( 100 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 101 deviceAddress js.Ref) (ok js.Ref) 102 103 //go:wasmimport plat/js/webext/bluetooth has_GetDevices 104 //go:noescape 105 func HasFuncGetDevices() js.Ref 106 107 //go:wasmimport plat/js/webext/bluetooth func_GetDevices 108 //go:noescape 109 func FuncGetDevices(fn unsafe.Pointer) 110 111 //go:wasmimport plat/js/webext/bluetooth call_GetDevices 112 //go:noescape 113 func CallGetDevices( 114 retPtr unsafe.Pointer, 115 filter unsafe.Pointer) 116 117 //go:wasmimport plat/js/webext/bluetooth try_GetDevices 118 //go:noescape 119 func TryGetDevices( 120 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 121 filter unsafe.Pointer) (ok js.Ref) 122 123 //go:wasmimport plat/js/webext/bluetooth has_OnAdapterStateChanged 124 //go:noescape 125 func HasFuncOnAdapterStateChanged() js.Ref 126 127 //go:wasmimport plat/js/webext/bluetooth func_OnAdapterStateChanged 128 //go:noescape 129 func FuncOnAdapterStateChanged(fn unsafe.Pointer) 130 131 //go:wasmimport plat/js/webext/bluetooth call_OnAdapterStateChanged 132 //go:noescape 133 func CallOnAdapterStateChanged( 134 retPtr unsafe.Pointer, 135 callback js.Ref) 136 137 //go:wasmimport plat/js/webext/bluetooth try_OnAdapterStateChanged 138 //go:noescape 139 func TryOnAdapterStateChanged( 140 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 141 callback js.Ref) (ok js.Ref) 142 143 //go:wasmimport plat/js/webext/bluetooth has_OffAdapterStateChanged 144 //go:noescape 145 func HasFuncOffAdapterStateChanged() js.Ref 146 147 //go:wasmimport plat/js/webext/bluetooth func_OffAdapterStateChanged 148 //go:noescape 149 func FuncOffAdapterStateChanged(fn unsafe.Pointer) 150 151 //go:wasmimport plat/js/webext/bluetooth call_OffAdapterStateChanged 152 //go:noescape 153 func CallOffAdapterStateChanged( 154 retPtr unsafe.Pointer, 155 callback js.Ref) 156 157 //go:wasmimport plat/js/webext/bluetooth try_OffAdapterStateChanged 158 //go:noescape 159 func TryOffAdapterStateChanged( 160 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 161 callback js.Ref) (ok js.Ref) 162 163 //go:wasmimport plat/js/webext/bluetooth has_HasOnAdapterStateChanged 164 //go:noescape 165 func HasFuncHasOnAdapterStateChanged() js.Ref 166 167 //go:wasmimport plat/js/webext/bluetooth func_HasOnAdapterStateChanged 168 //go:noescape 169 func FuncHasOnAdapterStateChanged(fn unsafe.Pointer) 170 171 //go:wasmimport plat/js/webext/bluetooth call_HasOnAdapterStateChanged 172 //go:noescape 173 func CallHasOnAdapterStateChanged( 174 retPtr unsafe.Pointer, 175 callback js.Ref) 176 177 //go:wasmimport plat/js/webext/bluetooth try_HasOnAdapterStateChanged 178 //go:noescape 179 func TryHasOnAdapterStateChanged( 180 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 181 callback js.Ref) (ok js.Ref) 182 183 //go:wasmimport plat/js/webext/bluetooth has_OnDeviceAdded 184 //go:noescape 185 func HasFuncOnDeviceAdded() js.Ref 186 187 //go:wasmimport plat/js/webext/bluetooth func_OnDeviceAdded 188 //go:noescape 189 func FuncOnDeviceAdded(fn unsafe.Pointer) 190 191 //go:wasmimport plat/js/webext/bluetooth call_OnDeviceAdded 192 //go:noescape 193 func CallOnDeviceAdded( 194 retPtr unsafe.Pointer, 195 callback js.Ref) 196 197 //go:wasmimport plat/js/webext/bluetooth try_OnDeviceAdded 198 //go:noescape 199 func TryOnDeviceAdded( 200 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 201 callback js.Ref) (ok js.Ref) 202 203 //go:wasmimport plat/js/webext/bluetooth has_OffDeviceAdded 204 //go:noescape 205 func HasFuncOffDeviceAdded() js.Ref 206 207 //go:wasmimport plat/js/webext/bluetooth func_OffDeviceAdded 208 //go:noescape 209 func FuncOffDeviceAdded(fn unsafe.Pointer) 210 211 //go:wasmimport plat/js/webext/bluetooth call_OffDeviceAdded 212 //go:noescape 213 func CallOffDeviceAdded( 214 retPtr unsafe.Pointer, 215 callback js.Ref) 216 217 //go:wasmimport plat/js/webext/bluetooth try_OffDeviceAdded 218 //go:noescape 219 func TryOffDeviceAdded( 220 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 221 callback js.Ref) (ok js.Ref) 222 223 //go:wasmimport plat/js/webext/bluetooth has_HasOnDeviceAdded 224 //go:noescape 225 func HasFuncHasOnDeviceAdded() js.Ref 226 227 //go:wasmimport plat/js/webext/bluetooth func_HasOnDeviceAdded 228 //go:noescape 229 func FuncHasOnDeviceAdded(fn unsafe.Pointer) 230 231 //go:wasmimport plat/js/webext/bluetooth call_HasOnDeviceAdded 232 //go:noescape 233 func CallHasOnDeviceAdded( 234 retPtr unsafe.Pointer, 235 callback js.Ref) 236 237 //go:wasmimport plat/js/webext/bluetooth try_HasOnDeviceAdded 238 //go:noescape 239 func TryHasOnDeviceAdded( 240 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 241 callback js.Ref) (ok js.Ref) 242 243 //go:wasmimport plat/js/webext/bluetooth has_OnDeviceChanged 244 //go:noescape 245 func HasFuncOnDeviceChanged() js.Ref 246 247 //go:wasmimport plat/js/webext/bluetooth func_OnDeviceChanged 248 //go:noescape 249 func FuncOnDeviceChanged(fn unsafe.Pointer) 250 251 //go:wasmimport plat/js/webext/bluetooth call_OnDeviceChanged 252 //go:noescape 253 func CallOnDeviceChanged( 254 retPtr unsafe.Pointer, 255 callback js.Ref) 256 257 //go:wasmimport plat/js/webext/bluetooth try_OnDeviceChanged 258 //go:noescape 259 func TryOnDeviceChanged( 260 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 261 callback js.Ref) (ok js.Ref) 262 263 //go:wasmimport plat/js/webext/bluetooth has_OffDeviceChanged 264 //go:noescape 265 func HasFuncOffDeviceChanged() js.Ref 266 267 //go:wasmimport plat/js/webext/bluetooth func_OffDeviceChanged 268 //go:noescape 269 func FuncOffDeviceChanged(fn unsafe.Pointer) 270 271 //go:wasmimport plat/js/webext/bluetooth call_OffDeviceChanged 272 //go:noescape 273 func CallOffDeviceChanged( 274 retPtr unsafe.Pointer, 275 callback js.Ref) 276 277 //go:wasmimport plat/js/webext/bluetooth try_OffDeviceChanged 278 //go:noescape 279 func TryOffDeviceChanged( 280 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 281 callback js.Ref) (ok js.Ref) 282 283 //go:wasmimport plat/js/webext/bluetooth has_HasOnDeviceChanged 284 //go:noescape 285 func HasFuncHasOnDeviceChanged() js.Ref 286 287 //go:wasmimport plat/js/webext/bluetooth func_HasOnDeviceChanged 288 //go:noescape 289 func FuncHasOnDeviceChanged(fn unsafe.Pointer) 290 291 //go:wasmimport plat/js/webext/bluetooth call_HasOnDeviceChanged 292 //go:noescape 293 func CallHasOnDeviceChanged( 294 retPtr unsafe.Pointer, 295 callback js.Ref) 296 297 //go:wasmimport plat/js/webext/bluetooth try_HasOnDeviceChanged 298 //go:noescape 299 func TryHasOnDeviceChanged( 300 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 301 callback js.Ref) (ok js.Ref) 302 303 //go:wasmimport plat/js/webext/bluetooth has_OnDeviceRemoved 304 //go:noescape 305 func HasFuncOnDeviceRemoved() js.Ref 306 307 //go:wasmimport plat/js/webext/bluetooth func_OnDeviceRemoved 308 //go:noescape 309 func FuncOnDeviceRemoved(fn unsafe.Pointer) 310 311 //go:wasmimport plat/js/webext/bluetooth call_OnDeviceRemoved 312 //go:noescape 313 func CallOnDeviceRemoved( 314 retPtr unsafe.Pointer, 315 callback js.Ref) 316 317 //go:wasmimport plat/js/webext/bluetooth try_OnDeviceRemoved 318 //go:noescape 319 func TryOnDeviceRemoved( 320 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 321 callback js.Ref) (ok js.Ref) 322 323 //go:wasmimport plat/js/webext/bluetooth has_OffDeviceRemoved 324 //go:noescape 325 func HasFuncOffDeviceRemoved() js.Ref 326 327 //go:wasmimport plat/js/webext/bluetooth func_OffDeviceRemoved 328 //go:noescape 329 func FuncOffDeviceRemoved(fn unsafe.Pointer) 330 331 //go:wasmimport plat/js/webext/bluetooth call_OffDeviceRemoved 332 //go:noescape 333 func CallOffDeviceRemoved( 334 retPtr unsafe.Pointer, 335 callback js.Ref) 336 337 //go:wasmimport plat/js/webext/bluetooth try_OffDeviceRemoved 338 //go:noescape 339 func TryOffDeviceRemoved( 340 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 341 callback js.Ref) (ok js.Ref) 342 343 //go:wasmimport plat/js/webext/bluetooth has_HasOnDeviceRemoved 344 //go:noescape 345 func HasFuncHasOnDeviceRemoved() js.Ref 346 347 //go:wasmimport plat/js/webext/bluetooth func_HasOnDeviceRemoved 348 //go:noescape 349 func FuncHasOnDeviceRemoved(fn unsafe.Pointer) 350 351 //go:wasmimport plat/js/webext/bluetooth call_HasOnDeviceRemoved 352 //go:noescape 353 func CallHasOnDeviceRemoved( 354 retPtr unsafe.Pointer, 355 callback js.Ref) 356 357 //go:wasmimport plat/js/webext/bluetooth try_HasOnDeviceRemoved 358 //go:noescape 359 func TryHasOnDeviceRemoved( 360 retPtr unsafe.Pointer, errPtr unsafe.Pointer, 361 callback js.Ref) (ok js.Ref) 362 363 //go:wasmimport plat/js/webext/bluetooth has_StartDiscovery 364 //go:noescape 365 func HasFuncStartDiscovery() js.Ref 366 367 //go:wasmimport plat/js/webext/bluetooth func_StartDiscovery 368 //go:noescape 369 func FuncStartDiscovery(fn unsafe.Pointer) 370 371 //go:wasmimport plat/js/webext/bluetooth call_StartDiscovery 372 //go:noescape 373 func CallStartDiscovery( 374 retPtr unsafe.Pointer) 375 376 //go:wasmimport plat/js/webext/bluetooth try_StartDiscovery 377 //go:noescape 378 func TryStartDiscovery( 379 retPtr unsafe.Pointer, errPtr unsafe.Pointer) (ok js.Ref) 380 381 //go:wasmimport plat/js/webext/bluetooth has_StopDiscovery 382 //go:noescape 383 func HasFuncStopDiscovery() js.Ref 384 385 //go:wasmimport plat/js/webext/bluetooth func_StopDiscovery 386 //go:noescape 387 func FuncStopDiscovery(fn unsafe.Pointer) 388 389 //go:wasmimport plat/js/webext/bluetooth call_StopDiscovery 390 //go:noescape 391 func CallStopDiscovery( 392 retPtr unsafe.Pointer) 393 394 //go:wasmimport plat/js/webext/bluetooth try_StopDiscovery 395 //go:noescape 396 func TryStopDiscovery( 397 retPtr unsafe.Pointer, errPtr unsafe.Pointer) (ok js.Ref)