@girs/gnomebluetooth-3.0 3.0.0-3.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,91 @@
1
+
2
+ # GnomeBluetooth-3.0
3
+
4
+ ![version](https://img.shields.io/npm/v/@girs/gnomebluetooth-3.0)
5
+ ![downloads/week](https://img.shields.io/npm/dw/@girs/gnomebluetooth-3.0)
6
+
7
+
8
+ GJS TypeScript type definitions for GnomeBluetooth-3.0, generated from library version 3.0.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v3.2.4.
9
+
10
+
11
+ ## Install
12
+
13
+ To use this type definitions, install them with NPM:
14
+ ```bash
15
+ npm install @girs/gnomebluetooth-3.0
16
+ ```
17
+
18
+ ## Usage
19
+
20
+ You can import this package into your project like this:
21
+ ```ts
22
+ import GnomeBluetooth from '@girs/gnomebluetooth-3.0';
23
+ ```
24
+
25
+ Or if you prefer CommonJS, you can also use this:
26
+ ```ts
27
+ const GnomeBluetooth = require('@girs/gnomebluetooth-3.0');
28
+ ```
29
+
30
+ ### Ambient Modules
31
+
32
+ You can also use [ambient modules](https://github.com/gjsify/ts-for-gir/tree/main/packages/cli#ambient-modules) to import this module like you would do this in JavaScript.
33
+ For this you need to include `@girs/gnomebluetooth-3.0` or `@girs/gnomebluetooth-3.0/ambient` in your `tsconfig` or entry point Typescript file:
34
+
35
+ `index.ts`:
36
+ ```ts
37
+ import '@girs/gnomebluetooth-3.0'
38
+ ```
39
+
40
+ `tsconfig.json`:
41
+ ```json
42
+ {
43
+ "compilerOptions": {
44
+ ...
45
+ },
46
+ "include": ["@girs/gnomebluetooth-3.0"],
47
+ ...
48
+ }
49
+ ```
50
+
51
+ Now you can import the ambient module with TypeScript support:
52
+
53
+ ```ts
54
+ import GnomeBluetooth from 'gi://GnomeBluetooth?version=3.0';
55
+ ```
56
+
57
+ ### Global import
58
+
59
+ You can also import the module with Typescript support using the global `imports.gi` object of GJS.
60
+ For this you need to include `@girs/gnomebluetooth-3.0` or `@girs/gnomebluetooth-3.0/import` in your `tsconfig` or entry point Typescript file:
61
+
62
+ `index.ts`:
63
+ ```ts
64
+ import '@girs/gnomebluetooth-3.0'
65
+ ```
66
+
67
+ `tsconfig.json`:
68
+ ```json
69
+ {
70
+ "compilerOptions": {
71
+ ...
72
+ },
73
+ "include": ["@girs/gnomebluetooth-3.0"],
74
+ ...
75
+ }
76
+ ```
77
+
78
+ Now you have also type support for this, too:
79
+
80
+ ```ts
81
+ const GnomeBluetooth = imports.gi.GnomeBluetooth;
82
+ ```
83
+
84
+ ### Bundle
85
+
86
+ Depending on your project configuration, it is recommended to use a bundler like [esbuild](https://esbuild.github.io/). You can find examples using different bundlers [here](https://github.com/gjsify/ts-for-gir/tree/main/examples).
87
+
88
+ ## Other packages
89
+
90
+ All existing pre-generated packages can be found on [gjsify/types](https://github.com/gjsify/types).
91
+
@@ -0,0 +1,9 @@
1
+
2
+
3
+ declare module 'gi://GnomeBluetooth?version=3.0' {
4
+ import GnomeBluetooth30 from '@girs/gnomebluetooth-3.0';
5
+ export default GnomeBluetooth30;
6
+ }
7
+
8
+
9
+
@@ -0,0 +1,13 @@
1
+
2
+
3
+ import GnomeBluetooth30 from '@girs/gnomebluetooth-3.0';
4
+
5
+ declare global {
6
+ export interface GjsGiImports {
7
+ GnomeBluetooth: typeof GnomeBluetooth30;
8
+ }
9
+ }
10
+
11
+ export default GjsGiImports;
12
+
13
+
@@ -0,0 +1,11 @@
1
+
2
+
3
+ imports.gi.versions.GnomeBluetooth = '3.0'
4
+ const GnomeBluetooth = imports.gi.GnomeBluetooth;
5
+
6
+ module.exports = GnomeBluetooth;
7
+
8
+
9
+
10
+
11
+
@@ -0,0 +1,528 @@
1
+
2
+ /*
3
+ * Type Definitions for Gjs (https://gjs.guide/)
4
+ *
5
+ * These type definitions are automatically generated, do not edit them by hand.
6
+ * If you found a bug fix it in `ts-for-gir` or create a bug report on https://github.com/gjsify/ts-for-gir
7
+ */
8
+
9
+ import './gnomebluetooth-3.0-ambient.d.ts';
10
+ import './gnomebluetooth-3.0-import.d.ts';
11
+ /**
12
+ * GnomeBluetooth-3.0
13
+ */
14
+
15
+ import type Gio from '@girs/gio-2.0';
16
+ import type GObject from '@girs/gobject-2.0';
17
+ import type GLib from '@girs/glib-2.0';
18
+
19
+ /**
20
+ * A more precise power state for a Bluetooth adapter.
21
+ */
22
+ export enum AdapterState {
23
+ /**
24
+ * Bluetooth adapter is missing.
25
+ */
26
+ ABSENT,
27
+ /**
28
+ * Bluetooth adapter is on.
29
+ */
30
+ ON,
31
+ /**
32
+ * Bluetooth adapter is being turned on.
33
+ */
34
+ TURNING_ON,
35
+ /**
36
+ * Bluetooth adapter is being turned off.
37
+ */
38
+ TURNING_OFF,
39
+ /**
40
+ * Bluetooth adapter is off.
41
+ */
42
+ OFF,
43
+ }
44
+ /**
45
+ * The type of battery reporting supported by the device.
46
+ */
47
+ export enum BatteryType {
48
+ /**
49
+ * no battery reporting
50
+ */
51
+ NONE,
52
+ /**
53
+ * battery reported in percentage
54
+ */
55
+ PERCENTAGE,
56
+ /**
57
+ * battery reported coarsely
58
+ */
59
+ COARSE,
60
+ }
61
+ /**
62
+ * The type of a Bluetooth device. See also %BLUETOOTH_TYPE_INPUT and %BLUETOOTH_TYPE_AUDIO
63
+ * @bitfield
64
+ */
65
+ export enum Type {
66
+ /**
67
+ * any device, or a device of an unknown type
68
+ */
69
+ ANY,
70
+ /**
71
+ * a telephone (usually a cell/mobile phone)
72
+ */
73
+ PHONE,
74
+ /**
75
+ * a modem
76
+ */
77
+ MODEM,
78
+ /**
79
+ * a computer, can be a laptop, a wearable computer, etc.
80
+ */
81
+ COMPUTER,
82
+ /**
83
+ * a network device, such as a router
84
+ */
85
+ NETWORK,
86
+ /**
87
+ * a headset (usually a hands-free device)
88
+ */
89
+ HEADSET,
90
+ /**
91
+ * headphones (covers two ears)
92
+ */
93
+ HEADPHONES,
94
+ /**
95
+ * another type of audio device
96
+ */
97
+ OTHER_AUDIO,
98
+ /**
99
+ * a keyboard
100
+ */
101
+ KEYBOARD,
102
+ /**
103
+ * a mouse
104
+ */
105
+ MOUSE,
106
+ /**
107
+ * a camera (still or moving)
108
+ */
109
+ CAMERA,
110
+ /**
111
+ * a printer
112
+ */
113
+ PRINTER,
114
+ /**
115
+ * a joypad, joystick, or other game controller
116
+ */
117
+ JOYPAD,
118
+ /**
119
+ * a drawing tablet
120
+ */
121
+ TABLET,
122
+ /**
123
+ * a video device, such as a webcam
124
+ */
125
+ VIDEO,
126
+ /**
127
+ * a remote control
128
+ */
129
+ REMOTE_CONTROL,
130
+ /**
131
+ * a scanner
132
+ */
133
+ SCANNER,
134
+ /**
135
+ * a display
136
+ */
137
+ DISPLAY,
138
+ /**
139
+ * a wearable computer
140
+ */
141
+ WEARABLE,
142
+ /**
143
+ * a toy or game
144
+ */
145
+ TOY,
146
+ /**
147
+ * audio speaker or speakers
148
+ */
149
+ SPEAKERS,
150
+ }
151
+ /**
152
+ * Use this value to select any Bluetooth audio device where a #BluetoothType enum is required.
153
+ */
154
+ export const TYPE_AUDIO: number
155
+ /**
156
+ * Use this value to select any Bluetooth input device where a #BluetoothType enum is required.
157
+ */
158
+ export const TYPE_INPUT: number
159
+ /**
160
+ * Returns the type of device corresponding to the given `appearance` value,
161
+ * as usually found in the GAP service.
162
+ * @param appearance a Bluetooth device appearance
163
+ * @returns a #BluetoothType.
164
+ */
165
+ export function appearance_to_type(appearance: number): Type
166
+ /**
167
+ * Returns the type of device corresponding to the given `class` value.
168
+ * @param class_ a Bluetooth device class
169
+ * @returns a #BluetoothType.
170
+ */
171
+ export function class_to_type(class_: number): Type
172
+ /**
173
+ * Start a GUI application for transferring files over Bluetooth.
174
+ * @param address Remote device to use
175
+ * @param alias Remote device's name
176
+ * @returns %TRUE on success, %FALSE on error.
177
+ */
178
+ export function send_to_address(address: string | null, alias: string | null): boolean
179
+ /**
180
+ * Returns a human-readable string representation of `type` usable for display to users. Do not free the return value.
181
+ * The returned string is already translated with gettext().
182
+ * @param type a #BluetoothType
183
+ * @returns a string.
184
+ */
185
+ export function type_to_string(type: number): string | null
186
+ /**
187
+ * Returns a string representing a human-readable (but not usable for display to users) version of the `uuid`. Do not free the return value.
188
+ * @param uuid a string representing a Bluetooth UUID
189
+ * @returns a string.
190
+ */
191
+ export function uuid_to_string(uuid: string | null): string | null
192
+ /**
193
+ * Returns whether the string is a valid Bluetooth address. This does not contact the device in any way.
194
+ * @param bdaddr a string representing a Bluetooth address
195
+ * @returns %TRUE if the address is valid, %FALSE if not.
196
+ */
197
+ export function verify_address(bdaddr: string | null): boolean
198
+ export module Client {
199
+
200
+ // Signal callback interfaces
201
+
202
+ /**
203
+ * Signal callback interface for `device-added`
204
+ */
205
+ export interface DeviceAddedSignalCallback {
206
+ ($obj: Client, device: GObject.Object): void
207
+ }
208
+
209
+ /**
210
+ * Signal callback interface for `device-removed`
211
+ */
212
+ export interface DeviceRemovedSignalCallback {
213
+ ($obj: Client, device: string | null): void
214
+ }
215
+
216
+
217
+ // Constructor properties interface
218
+
219
+ export interface ConstructorProperties extends GObject.Object.ConstructorProperties {
220
+
221
+ // Own constructor properties of GnomeBluetooth-3.0.GnomeBluetooth.Client
222
+
223
+ /**
224
+ * %TRUE if the default Bluetooth adapter is powered.
225
+ */
226
+ default_adapter_powered?: boolean | null
227
+ /**
228
+ * %TRUE if the default Bluetooth adapter is in setup mode (discoverable, and discovering).
229
+ */
230
+ default_adapter_setup_mode?: boolean | null
231
+ }
232
+
233
+ }
234
+
235
+ export interface Client {
236
+
237
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.Client
238
+
239
+ /**
240
+ * The D-Bus path of the default Bluetooth adapter or %NULL.
241
+ */
242
+ readonly default_adapter: string | null
243
+ /**
244
+ * The address of the default Bluetooth adapter or %NULL.
245
+ */
246
+ readonly default_adapter_address: string | null
247
+ /**
248
+ * The name of the default Bluetooth adapter or %NULL.
249
+ */
250
+ readonly default_adapter_name: string | null
251
+ /**
252
+ * %TRUE if the default Bluetooth adapter is powered.
253
+ */
254
+ default_adapter_powered: boolean
255
+ /**
256
+ * %TRUE if the default Bluetooth adapter is in setup mode (discoverable, and discovering).
257
+ */
258
+ default_adapter_setup_mode: boolean
259
+ /**
260
+ * The #BluetoothAdapterState of the default Bluetooth adapter. More precise than
261
+ * #BluetoothClient:default-adapter-powered.
262
+ */
263
+ readonly default_adapter_state: AdapterState
264
+ /**
265
+ * The number of detected Bluetooth adapters.
266
+ */
267
+ readonly num_adapters: number
268
+
269
+ // Owm methods of GnomeBluetooth-3.0.GnomeBluetooth.Client
270
+
271
+ /**
272
+ * This will start the process of connecting to one of the known-connectable
273
+ * services on the device. This means that it could connect to all the audio
274
+ * services on a headset, but just to the input service on a keyboard.
275
+ *
276
+ * Broadly speaking, this will only have an effect on devices with audio and HID
277
+ * services, and do nothing if the device doesn't have the "connectable"
278
+ * property set.
279
+ *
280
+ * When the connection operation is finished, `callback` will be called. You can
281
+ * then call bluetooth_client_connect_service_finish() to get the result of the
282
+ * operation.
283
+ * @param path the object path on which to operate
284
+ * @param connect Whether try to connect or disconnect from services on a device
285
+ * @param cancellable optional #GCancellable object, %NULL to ignore
286
+ * @param callback a #GAsyncReadyCallback to call when the connection is complete
287
+ */
288
+ connect_service(path: string | null, connect: boolean, cancellable: Gio.Cancellable | null, callback: Gio.AsyncReadyCallback<this> | null): void
289
+ /**
290
+ * Finishes the connection operation. See bluetooth_client_connect_service().
291
+ * @param res a #GAsyncResult
292
+ * @returns %TRUE if the connection operation succeeded, %FALSE otherwise.
293
+ */
294
+ connect_service_finish(res: Gio.AsyncResult): boolean
295
+ /**
296
+ * Returns an unfiltered #GListStore representing the devices attached to the default
297
+ * Bluetooth adapter.
298
+ * @returns a #GListStore
299
+ */
300
+ get_devices(): Gio.ListStore
301
+ /**
302
+ * Returns whether there are connected devices with the input capability.
303
+ * This can be used by an OS user interface to warn the user before disabling
304
+ * Bluetooth so that the user isn't stranded without any input devices.
305
+ * @returns %TRUE if there are connected input devices.
306
+ */
307
+ has_connected_input_devices(): boolean
308
+
309
+ // Own signals of GnomeBluetooth-3.0.GnomeBluetooth.Client
310
+
311
+ connect(sigName: "device-added", callback: Client.DeviceAddedSignalCallback): number
312
+ connect_after(sigName: "device-added", callback: Client.DeviceAddedSignalCallback): number
313
+ emit(sigName: "device-added", device: GObject.Object, ...args: any[]): void
314
+ connect(sigName: "device-removed", callback: Client.DeviceRemovedSignalCallback): number
315
+ connect_after(sigName: "device-removed", callback: Client.DeviceRemovedSignalCallback): number
316
+ emit(sigName: "device-removed", device: string | null, ...args: any[]): void
317
+
318
+ // Class property signals of GnomeBluetooth-3.0.GnomeBluetooth.Client
319
+
320
+ connect(sigName: "notify::default-adapter", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
321
+ connect_after(sigName: "notify::default-adapter", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
322
+ emit(sigName: "notify::default-adapter", ...args: any[]): void
323
+ connect(sigName: "notify::default-adapter-address", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
324
+ connect_after(sigName: "notify::default-adapter-address", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
325
+ emit(sigName: "notify::default-adapter-address", ...args: any[]): void
326
+ connect(sigName: "notify::default-adapter-name", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
327
+ connect_after(sigName: "notify::default-adapter-name", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
328
+ emit(sigName: "notify::default-adapter-name", ...args: any[]): void
329
+ connect(sigName: "notify::default-adapter-powered", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
330
+ connect_after(sigName: "notify::default-adapter-powered", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
331
+ emit(sigName: "notify::default-adapter-powered", ...args: any[]): void
332
+ connect(sigName: "notify::default-adapter-setup-mode", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
333
+ connect_after(sigName: "notify::default-adapter-setup-mode", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
334
+ emit(sigName: "notify::default-adapter-setup-mode", ...args: any[]): void
335
+ connect(sigName: "notify::default-adapter-state", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
336
+ connect_after(sigName: "notify::default-adapter-state", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
337
+ emit(sigName: "notify::default-adapter-state", ...args: any[]): void
338
+ connect(sigName: "notify::num-adapters", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
339
+ connect_after(sigName: "notify::num-adapters", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
340
+ emit(sigName: "notify::num-adapters", ...args: any[]): void
341
+ connect(sigName: string, callback: (...args: any[]) => void): number
342
+ connect_after(sigName: string, callback: (...args: any[]) => void): number
343
+ emit(sigName: string, ...args: any[]): void
344
+ disconnect(id: number): void
345
+ }
346
+
347
+ export class Client extends GObject.Object {
348
+
349
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.Client
350
+
351
+ static name: string
352
+ static $gtype: GObject.GType<Client>
353
+
354
+ // Constructors of GnomeBluetooth-3.0.GnomeBluetooth.Client
355
+
356
+ constructor(config?: Client.ConstructorProperties)
357
+ /**
358
+ * Returns a reference to the #BluetoothClient singleton. Use g_object_unref() when done with the object.
359
+ * @constructor
360
+ * @returns a #BluetoothClient object.
361
+ */
362
+ constructor()
363
+ /**
364
+ * Returns a reference to the #BluetoothClient singleton. Use g_object_unref() when done with the object.
365
+ * @constructor
366
+ * @returns a #BluetoothClient object.
367
+ */
368
+ static new(): Client
369
+ _init(config?: Client.ConstructorProperties): void
370
+ }
371
+
372
+ export module Device {
373
+
374
+ // Constructor properties interface
375
+
376
+ export interface ConstructorProperties extends GObject.Object.ConstructorProperties {
377
+
378
+ // Own constructor properties of GnomeBluetooth-3.0.GnomeBluetooth.Device
379
+
380
+ address?: string | null
381
+ alias?: string | null
382
+ battery_level?: number | null
383
+ battery_percentage?: number | null
384
+ battery_type?: BatteryType | null
385
+ connected?: boolean | null
386
+ icon?: string | null
387
+ legacy_pairing?: boolean | null
388
+ name?: string | null
389
+ paired?: boolean | null
390
+ proxy?: Gio.DBusProxy | null
391
+ trusted?: boolean | null
392
+ type?: Type | null
393
+ uuids?: string[] | null
394
+ }
395
+
396
+ }
397
+
398
+ export interface Device {
399
+
400
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.Device
401
+
402
+ address: string | null
403
+ alias: string | null
404
+ battery_level: number
405
+ battery_percentage: number
406
+ battery_type: BatteryType
407
+ readonly connectable: boolean
408
+ connected: boolean
409
+ icon: string | null
410
+ legacy_pairing: boolean
411
+ name: string | null
412
+ paired: boolean
413
+ proxy: Gio.DBusProxy
414
+ trusted: boolean
415
+ type: Type
416
+ uuids: string[]
417
+
418
+ // Owm methods of GnomeBluetooth-3.0.GnomeBluetooth.Device
419
+
420
+ dump(): void
421
+ get_object_path(): string | null
422
+ to_string(): string | null
423
+
424
+ // Class property signals of GnomeBluetooth-3.0.GnomeBluetooth.Device
425
+
426
+ connect(sigName: "notify::address", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
427
+ connect_after(sigName: "notify::address", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
428
+ emit(sigName: "notify::address", ...args: any[]): void
429
+ connect(sigName: "notify::alias", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
430
+ connect_after(sigName: "notify::alias", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
431
+ emit(sigName: "notify::alias", ...args: any[]): void
432
+ connect(sigName: "notify::battery-level", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
433
+ connect_after(sigName: "notify::battery-level", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
434
+ emit(sigName: "notify::battery-level", ...args: any[]): void
435
+ connect(sigName: "notify::battery-percentage", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
436
+ connect_after(sigName: "notify::battery-percentage", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
437
+ emit(sigName: "notify::battery-percentage", ...args: any[]): void
438
+ connect(sigName: "notify::battery-type", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
439
+ connect_after(sigName: "notify::battery-type", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
440
+ emit(sigName: "notify::battery-type", ...args: any[]): void
441
+ connect(sigName: "notify::connectable", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
442
+ connect_after(sigName: "notify::connectable", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
443
+ emit(sigName: "notify::connectable", ...args: any[]): void
444
+ connect(sigName: "notify::connected", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
445
+ connect_after(sigName: "notify::connected", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
446
+ emit(sigName: "notify::connected", ...args: any[]): void
447
+ connect(sigName: "notify::icon", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
448
+ connect_after(sigName: "notify::icon", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
449
+ emit(sigName: "notify::icon", ...args: any[]): void
450
+ connect(sigName: "notify::legacy-pairing", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
451
+ connect_after(sigName: "notify::legacy-pairing", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
452
+ emit(sigName: "notify::legacy-pairing", ...args: any[]): void
453
+ connect(sigName: "notify::name", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
454
+ connect_after(sigName: "notify::name", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
455
+ emit(sigName: "notify::name", ...args: any[]): void
456
+ connect(sigName: "notify::paired", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
457
+ connect_after(sigName: "notify::paired", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
458
+ emit(sigName: "notify::paired", ...args: any[]): void
459
+ connect(sigName: "notify::proxy", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
460
+ connect_after(sigName: "notify::proxy", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
461
+ emit(sigName: "notify::proxy", ...args: any[]): void
462
+ connect(sigName: "notify::trusted", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
463
+ connect_after(sigName: "notify::trusted", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
464
+ emit(sigName: "notify::trusted", ...args: any[]): void
465
+ connect(sigName: "notify::type", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
466
+ connect_after(sigName: "notify::type", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
467
+ emit(sigName: "notify::type", ...args: any[]): void
468
+ connect(sigName: "notify::uuids", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
469
+ connect_after(sigName: "notify::uuids", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
470
+ emit(sigName: "notify::uuids", ...args: any[]): void
471
+ connect(sigName: string, callback: (...args: any[]) => void): number
472
+ connect_after(sigName: string, callback: (...args: any[]) => void): number
473
+ emit(sigName: string, ...args: any[]): void
474
+ disconnect(id: number): void
475
+ }
476
+
477
+ export class Device extends GObject.Object {
478
+
479
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.Device
480
+
481
+ static name: string
482
+ static $gtype: GObject.GType<Device>
483
+
484
+ // Constructors of GnomeBluetooth-3.0.GnomeBluetooth.Device
485
+
486
+ constructor(config?: Device.ConstructorProperties)
487
+ _init(config?: Device.ConstructorProperties): void
488
+ }
489
+
490
+ export interface ClientClass {
491
+
492
+ // Own fields of GnomeBluetooth-3.0.GnomeBluetooth.ClientClass
493
+
494
+ parent_class: GObject.ObjectClass
495
+ }
496
+
497
+ export abstract class ClientClass {
498
+
499
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.ClientClass
500
+
501
+ static name: string
502
+ }
503
+
504
+ export interface DeviceClass {
505
+
506
+ // Own fields of GnomeBluetooth-3.0.GnomeBluetooth.DeviceClass
507
+
508
+ parent_class: GObject.ObjectClass
509
+ }
510
+
511
+ export abstract class DeviceClass {
512
+
513
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.DeviceClass
514
+
515
+ static name: string
516
+ }
517
+
518
+ /**
519
+ * Name of the imported GIR library
520
+ * @see https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L188
521
+ */
522
+ export const __name__: string
523
+ /**
524
+ * Version of the imported GIR library
525
+ * @see https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L189
526
+ */
527
+ export const __version__: string
528
+ // END
@@ -0,0 +1,533 @@
1
+
2
+ /*
3
+ * Type Definitions for Gjs (https://gjs.guide/)
4
+ *
5
+ * These type definitions are automatically generated, do not edit them by hand.
6
+ * If you found a bug fix it in `ts-for-gir` or create a bug report on https://github.com/gjsify/ts-for-gir
7
+ */
8
+
9
+ import './gnomebluetooth-3.0-ambient.d.ts';
10
+ import './gnomebluetooth-3.0-import.d.ts';
11
+ /**
12
+ * GnomeBluetooth-3.0
13
+ */
14
+
15
+ import type Gio from '@girs/gio-2.0';
16
+ import type GObject from '@girs/gobject-2.0';
17
+ import type GLib from '@girs/glib-2.0';
18
+
19
+ export namespace GnomeBluetooth {
20
+
21
+ /**
22
+ * A more precise power state for a Bluetooth adapter.
23
+ */
24
+ enum AdapterState {
25
+ /**
26
+ * Bluetooth adapter is missing.
27
+ */
28
+ ABSENT,
29
+ /**
30
+ * Bluetooth adapter is on.
31
+ */
32
+ ON,
33
+ /**
34
+ * Bluetooth adapter is being turned on.
35
+ */
36
+ TURNING_ON,
37
+ /**
38
+ * Bluetooth adapter is being turned off.
39
+ */
40
+ TURNING_OFF,
41
+ /**
42
+ * Bluetooth adapter is off.
43
+ */
44
+ OFF,
45
+ }
46
+ /**
47
+ * The type of battery reporting supported by the device.
48
+ */
49
+ enum BatteryType {
50
+ /**
51
+ * no battery reporting
52
+ */
53
+ NONE,
54
+ /**
55
+ * battery reported in percentage
56
+ */
57
+ PERCENTAGE,
58
+ /**
59
+ * battery reported coarsely
60
+ */
61
+ COARSE,
62
+ }
63
+ /**
64
+ * The type of a Bluetooth device. See also %BLUETOOTH_TYPE_INPUT and %BLUETOOTH_TYPE_AUDIO
65
+ * @bitfield
66
+ */
67
+ enum Type {
68
+ /**
69
+ * any device, or a device of an unknown type
70
+ */
71
+ ANY,
72
+ /**
73
+ * a telephone (usually a cell/mobile phone)
74
+ */
75
+ PHONE,
76
+ /**
77
+ * a modem
78
+ */
79
+ MODEM,
80
+ /**
81
+ * a computer, can be a laptop, a wearable computer, etc.
82
+ */
83
+ COMPUTER,
84
+ /**
85
+ * a network device, such as a router
86
+ */
87
+ NETWORK,
88
+ /**
89
+ * a headset (usually a hands-free device)
90
+ */
91
+ HEADSET,
92
+ /**
93
+ * headphones (covers two ears)
94
+ */
95
+ HEADPHONES,
96
+ /**
97
+ * another type of audio device
98
+ */
99
+ OTHER_AUDIO,
100
+ /**
101
+ * a keyboard
102
+ */
103
+ KEYBOARD,
104
+ /**
105
+ * a mouse
106
+ */
107
+ MOUSE,
108
+ /**
109
+ * a camera (still or moving)
110
+ */
111
+ CAMERA,
112
+ /**
113
+ * a printer
114
+ */
115
+ PRINTER,
116
+ /**
117
+ * a joypad, joystick, or other game controller
118
+ */
119
+ JOYPAD,
120
+ /**
121
+ * a drawing tablet
122
+ */
123
+ TABLET,
124
+ /**
125
+ * a video device, such as a webcam
126
+ */
127
+ VIDEO,
128
+ /**
129
+ * a remote control
130
+ */
131
+ REMOTE_CONTROL,
132
+ /**
133
+ * a scanner
134
+ */
135
+ SCANNER,
136
+ /**
137
+ * a display
138
+ */
139
+ DISPLAY,
140
+ /**
141
+ * a wearable computer
142
+ */
143
+ WEARABLE,
144
+ /**
145
+ * a toy or game
146
+ */
147
+ TOY,
148
+ /**
149
+ * audio speaker or speakers
150
+ */
151
+ SPEAKERS,
152
+ }
153
+ /**
154
+ * Use this value to select any Bluetooth audio device where a #BluetoothType enum is required.
155
+ */
156
+ const TYPE_AUDIO: number
157
+ /**
158
+ * Use this value to select any Bluetooth input device where a #BluetoothType enum is required.
159
+ */
160
+ const TYPE_INPUT: number
161
+ /**
162
+ * Returns the type of device corresponding to the given `appearance` value,
163
+ * as usually found in the GAP service.
164
+ * @param appearance a Bluetooth device appearance
165
+ * @returns a #BluetoothType.
166
+ */
167
+ function appearance_to_type(appearance: number): Type
168
+ /**
169
+ * Returns the type of device corresponding to the given `class` value.
170
+ * @param class_ a Bluetooth device class
171
+ * @returns a #BluetoothType.
172
+ */
173
+ function class_to_type(class_: number): Type
174
+ /**
175
+ * Start a GUI application for transferring files over Bluetooth.
176
+ * @param address Remote device to use
177
+ * @param alias Remote device's name
178
+ * @returns %TRUE on success, %FALSE on error.
179
+ */
180
+ function send_to_address(address: string | null, alias: string | null): boolean
181
+ /**
182
+ * Returns a human-readable string representation of `type` usable for display to users. Do not free the return value.
183
+ * The returned string is already translated with gettext().
184
+ * @param type a #BluetoothType
185
+ * @returns a string.
186
+ */
187
+ function type_to_string(type: number): string | null
188
+ /**
189
+ * Returns a string representing a human-readable (but not usable for display to users) version of the `uuid`. Do not free the return value.
190
+ * @param uuid a string representing a Bluetooth UUID
191
+ * @returns a string.
192
+ */
193
+ function uuid_to_string(uuid: string | null): string | null
194
+ /**
195
+ * Returns whether the string is a valid Bluetooth address. This does not contact the device in any way.
196
+ * @param bdaddr a string representing a Bluetooth address
197
+ * @returns %TRUE if the address is valid, %FALSE if not.
198
+ */
199
+ function verify_address(bdaddr: string | null): boolean
200
+ module Client {
201
+
202
+ // Signal callback interfaces
203
+
204
+ /**
205
+ * Signal callback interface for `device-added`
206
+ */
207
+ interface DeviceAddedSignalCallback {
208
+ ($obj: Client, device: GObject.Object): void
209
+ }
210
+
211
+ /**
212
+ * Signal callback interface for `device-removed`
213
+ */
214
+ interface DeviceRemovedSignalCallback {
215
+ ($obj: Client, device: string | null): void
216
+ }
217
+
218
+
219
+ // Constructor properties interface
220
+
221
+ interface ConstructorProperties extends GObject.Object.ConstructorProperties {
222
+
223
+ // Own constructor properties of GnomeBluetooth-3.0.GnomeBluetooth.Client
224
+
225
+ /**
226
+ * %TRUE if the default Bluetooth adapter is powered.
227
+ */
228
+ default_adapter_powered?: boolean | null
229
+ /**
230
+ * %TRUE if the default Bluetooth adapter is in setup mode (discoverable, and discovering).
231
+ */
232
+ default_adapter_setup_mode?: boolean | null
233
+ }
234
+
235
+ }
236
+
237
+ interface Client {
238
+
239
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.Client
240
+
241
+ /**
242
+ * The D-Bus path of the default Bluetooth adapter or %NULL.
243
+ */
244
+ readonly default_adapter: string | null
245
+ /**
246
+ * The address of the default Bluetooth adapter or %NULL.
247
+ */
248
+ readonly default_adapter_address: string | null
249
+ /**
250
+ * The name of the default Bluetooth adapter or %NULL.
251
+ */
252
+ readonly default_adapter_name: string | null
253
+ /**
254
+ * %TRUE if the default Bluetooth adapter is powered.
255
+ */
256
+ default_adapter_powered: boolean
257
+ /**
258
+ * %TRUE if the default Bluetooth adapter is in setup mode (discoverable, and discovering).
259
+ */
260
+ default_adapter_setup_mode: boolean
261
+ /**
262
+ * The #BluetoothAdapterState of the default Bluetooth adapter. More precise than
263
+ * #BluetoothClient:default-adapter-powered.
264
+ */
265
+ readonly default_adapter_state: AdapterState
266
+ /**
267
+ * The number of detected Bluetooth adapters.
268
+ */
269
+ readonly num_adapters: number
270
+
271
+ // Owm methods of GnomeBluetooth-3.0.GnomeBluetooth.Client
272
+
273
+ /**
274
+ * This will start the process of connecting to one of the known-connectable
275
+ * services on the device. This means that it could connect to all the audio
276
+ * services on a headset, but just to the input service on a keyboard.
277
+ *
278
+ * Broadly speaking, this will only have an effect on devices with audio and HID
279
+ * services, and do nothing if the device doesn't have the "connectable"
280
+ * property set.
281
+ *
282
+ * When the connection operation is finished, `callback` will be called. You can
283
+ * then call bluetooth_client_connect_service_finish() to get the result of the
284
+ * operation.
285
+ * @param path the object path on which to operate
286
+ * @param connect Whether try to connect or disconnect from services on a device
287
+ * @param cancellable optional #GCancellable object, %NULL to ignore
288
+ * @param callback a #GAsyncReadyCallback to call when the connection is complete
289
+ */
290
+ connect_service(path: string | null, connect: boolean, cancellable: Gio.Cancellable | null, callback: Gio.AsyncReadyCallback<this> | null): void
291
+ /**
292
+ * Finishes the connection operation. See bluetooth_client_connect_service().
293
+ * @param res a #GAsyncResult
294
+ * @returns %TRUE if the connection operation succeeded, %FALSE otherwise.
295
+ */
296
+ connect_service_finish(res: Gio.AsyncResult): boolean
297
+ /**
298
+ * Returns an unfiltered #GListStore representing the devices attached to the default
299
+ * Bluetooth adapter.
300
+ * @returns a #GListStore
301
+ */
302
+ get_devices(): Gio.ListStore
303
+ /**
304
+ * Returns whether there are connected devices with the input capability.
305
+ * This can be used by an OS user interface to warn the user before disabling
306
+ * Bluetooth so that the user isn't stranded without any input devices.
307
+ * @returns %TRUE if there are connected input devices.
308
+ */
309
+ has_connected_input_devices(): boolean
310
+
311
+ // Own signals of GnomeBluetooth-3.0.GnomeBluetooth.Client
312
+
313
+ connect(sigName: "device-added", callback: Client.DeviceAddedSignalCallback): number
314
+ connect_after(sigName: "device-added", callback: Client.DeviceAddedSignalCallback): number
315
+ emit(sigName: "device-added", device: GObject.Object, ...args: any[]): void
316
+ connect(sigName: "device-removed", callback: Client.DeviceRemovedSignalCallback): number
317
+ connect_after(sigName: "device-removed", callback: Client.DeviceRemovedSignalCallback): number
318
+ emit(sigName: "device-removed", device: string | null, ...args: any[]): void
319
+
320
+ // Class property signals of GnomeBluetooth-3.0.GnomeBluetooth.Client
321
+
322
+ connect(sigName: "notify::default-adapter", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
323
+ connect_after(sigName: "notify::default-adapter", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
324
+ emit(sigName: "notify::default-adapter", ...args: any[]): void
325
+ connect(sigName: "notify::default-adapter-address", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
326
+ connect_after(sigName: "notify::default-adapter-address", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
327
+ emit(sigName: "notify::default-adapter-address", ...args: any[]): void
328
+ connect(sigName: "notify::default-adapter-name", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
329
+ connect_after(sigName: "notify::default-adapter-name", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
330
+ emit(sigName: "notify::default-adapter-name", ...args: any[]): void
331
+ connect(sigName: "notify::default-adapter-powered", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
332
+ connect_after(sigName: "notify::default-adapter-powered", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
333
+ emit(sigName: "notify::default-adapter-powered", ...args: any[]): void
334
+ connect(sigName: "notify::default-adapter-setup-mode", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
335
+ connect_after(sigName: "notify::default-adapter-setup-mode", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
336
+ emit(sigName: "notify::default-adapter-setup-mode", ...args: any[]): void
337
+ connect(sigName: "notify::default-adapter-state", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
338
+ connect_after(sigName: "notify::default-adapter-state", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
339
+ emit(sigName: "notify::default-adapter-state", ...args: any[]): void
340
+ connect(sigName: "notify::num-adapters", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
341
+ connect_after(sigName: "notify::num-adapters", callback: (($obj: Client, pspec: GObject.ParamSpec) => void)): number
342
+ emit(sigName: "notify::num-adapters", ...args: any[]): void
343
+ connect(sigName: string, callback: (...args: any[]) => void): number
344
+ connect_after(sigName: string, callback: (...args: any[]) => void): number
345
+ emit(sigName: string, ...args: any[]): void
346
+ disconnect(id: number): void
347
+ }
348
+
349
+ class Client extends GObject.Object {
350
+
351
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.Client
352
+
353
+ static name: string
354
+ static $gtype: GObject.GType<Client>
355
+
356
+ // Constructors of GnomeBluetooth-3.0.GnomeBluetooth.Client
357
+
358
+ constructor(config?: Client.ConstructorProperties)
359
+ /**
360
+ * Returns a reference to the #BluetoothClient singleton. Use g_object_unref() when done with the object.
361
+ * @constructor
362
+ * @returns a #BluetoothClient object.
363
+ */
364
+ constructor()
365
+ /**
366
+ * Returns a reference to the #BluetoothClient singleton. Use g_object_unref() when done with the object.
367
+ * @constructor
368
+ * @returns a #BluetoothClient object.
369
+ */
370
+ static new(): Client
371
+ _init(config?: Client.ConstructorProperties): void
372
+ }
373
+
374
+ module Device {
375
+
376
+ // Constructor properties interface
377
+
378
+ interface ConstructorProperties extends GObject.Object.ConstructorProperties {
379
+
380
+ // Own constructor properties of GnomeBluetooth-3.0.GnomeBluetooth.Device
381
+
382
+ address?: string | null
383
+ alias?: string | null
384
+ battery_level?: number | null
385
+ battery_percentage?: number | null
386
+ battery_type?: BatteryType | null
387
+ connected?: boolean | null
388
+ icon?: string | null
389
+ legacy_pairing?: boolean | null
390
+ name?: string | null
391
+ paired?: boolean | null
392
+ proxy?: Gio.DBusProxy | null
393
+ trusted?: boolean | null
394
+ type?: Type | null
395
+ uuids?: string[] | null
396
+ }
397
+
398
+ }
399
+
400
+ interface Device {
401
+
402
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.Device
403
+
404
+ address: string | null
405
+ alias: string | null
406
+ battery_level: number
407
+ battery_percentage: number
408
+ battery_type: BatteryType
409
+ readonly connectable: boolean
410
+ connected: boolean
411
+ icon: string | null
412
+ legacy_pairing: boolean
413
+ name: string | null
414
+ paired: boolean
415
+ proxy: Gio.DBusProxy
416
+ trusted: boolean
417
+ type: Type
418
+ uuids: string[]
419
+
420
+ // Owm methods of GnomeBluetooth-3.0.GnomeBluetooth.Device
421
+
422
+ dump(): void
423
+ get_object_path(): string | null
424
+ to_string(): string | null
425
+
426
+ // Class property signals of GnomeBluetooth-3.0.GnomeBluetooth.Device
427
+
428
+ connect(sigName: "notify::address", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
429
+ connect_after(sigName: "notify::address", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
430
+ emit(sigName: "notify::address", ...args: any[]): void
431
+ connect(sigName: "notify::alias", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
432
+ connect_after(sigName: "notify::alias", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
433
+ emit(sigName: "notify::alias", ...args: any[]): void
434
+ connect(sigName: "notify::battery-level", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
435
+ connect_after(sigName: "notify::battery-level", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
436
+ emit(sigName: "notify::battery-level", ...args: any[]): void
437
+ connect(sigName: "notify::battery-percentage", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
438
+ connect_after(sigName: "notify::battery-percentage", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
439
+ emit(sigName: "notify::battery-percentage", ...args: any[]): void
440
+ connect(sigName: "notify::battery-type", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
441
+ connect_after(sigName: "notify::battery-type", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
442
+ emit(sigName: "notify::battery-type", ...args: any[]): void
443
+ connect(sigName: "notify::connectable", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
444
+ connect_after(sigName: "notify::connectable", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
445
+ emit(sigName: "notify::connectable", ...args: any[]): void
446
+ connect(sigName: "notify::connected", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
447
+ connect_after(sigName: "notify::connected", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
448
+ emit(sigName: "notify::connected", ...args: any[]): void
449
+ connect(sigName: "notify::icon", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
450
+ connect_after(sigName: "notify::icon", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
451
+ emit(sigName: "notify::icon", ...args: any[]): void
452
+ connect(sigName: "notify::legacy-pairing", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
453
+ connect_after(sigName: "notify::legacy-pairing", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
454
+ emit(sigName: "notify::legacy-pairing", ...args: any[]): void
455
+ connect(sigName: "notify::name", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
456
+ connect_after(sigName: "notify::name", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
457
+ emit(sigName: "notify::name", ...args: any[]): void
458
+ connect(sigName: "notify::paired", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
459
+ connect_after(sigName: "notify::paired", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
460
+ emit(sigName: "notify::paired", ...args: any[]): void
461
+ connect(sigName: "notify::proxy", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
462
+ connect_after(sigName: "notify::proxy", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
463
+ emit(sigName: "notify::proxy", ...args: any[]): void
464
+ connect(sigName: "notify::trusted", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
465
+ connect_after(sigName: "notify::trusted", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
466
+ emit(sigName: "notify::trusted", ...args: any[]): void
467
+ connect(sigName: "notify::type", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
468
+ connect_after(sigName: "notify::type", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
469
+ emit(sigName: "notify::type", ...args: any[]): void
470
+ connect(sigName: "notify::uuids", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
471
+ connect_after(sigName: "notify::uuids", callback: (($obj: Device, pspec: GObject.ParamSpec) => void)): number
472
+ emit(sigName: "notify::uuids", ...args: any[]): void
473
+ connect(sigName: string, callback: (...args: any[]) => void): number
474
+ connect_after(sigName: string, callback: (...args: any[]) => void): number
475
+ emit(sigName: string, ...args: any[]): void
476
+ disconnect(id: number): void
477
+ }
478
+
479
+ class Device extends GObject.Object {
480
+
481
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.Device
482
+
483
+ static name: string
484
+ static $gtype: GObject.GType<Device>
485
+
486
+ // Constructors of GnomeBluetooth-3.0.GnomeBluetooth.Device
487
+
488
+ constructor(config?: Device.ConstructorProperties)
489
+ _init(config?: Device.ConstructorProperties): void
490
+ }
491
+
492
+ interface ClientClass {
493
+
494
+ // Own fields of GnomeBluetooth-3.0.GnomeBluetooth.ClientClass
495
+
496
+ parent_class: GObject.ObjectClass
497
+ }
498
+
499
+ abstract class ClientClass {
500
+
501
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.ClientClass
502
+
503
+ static name: string
504
+ }
505
+
506
+ interface DeviceClass {
507
+
508
+ // Own fields of GnomeBluetooth-3.0.GnomeBluetooth.DeviceClass
509
+
510
+ parent_class: GObject.ObjectClass
511
+ }
512
+
513
+ abstract class DeviceClass {
514
+
515
+ // Own properties of GnomeBluetooth-3.0.GnomeBluetooth.DeviceClass
516
+
517
+ static name: string
518
+ }
519
+
520
+ /**
521
+ * Name of the imported GIR library
522
+ * @see https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L188
523
+ */
524
+ const __name__: string
525
+ /**
526
+ * Version of the imported GIR library
527
+ * @see https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L189
528
+ */
529
+ const __version__: string
530
+ }
531
+
532
+ export default GnomeBluetooth;
533
+ // END
@@ -0,0 +1,10 @@
1
+
2
+
3
+ // @ts-expect-error
4
+ import GnomeBluetooth from 'gi://GnomeBluetooth?version=3.0';
5
+ export { GnomeBluetooth };
6
+ export default GnomeBluetooth;
7
+
8
+
9
+
10
+
package/package.json ADDED
@@ -0,0 +1,54 @@
1
+ {
2
+ "name": "@girs/gnomebluetooth-3.0",
3
+ "version": "3.0.0-3.2.4",
4
+ "description": "GJS TypeScript type definitions for GnomeBluetooth-3.0, generated from library version 3.0.0",
5
+ "type": "module",
6
+ "module": "gnomebluetooth-3.0.js",
7
+ "main": "gnomebluetooth-3.0.js",
8
+ "exports": {
9
+ "./ambient": "./gnomebluetooth-3.0-ambient.d.ts",
10
+ "./import": "./gnomebluetooth-3.0-import.d.ts",
11
+ ".": {
12
+ "import": {
13
+ "types": "./gnomebluetooth-3.0.d.ts",
14
+ "default": "./gnomebluetooth-3.0.js"
15
+ },
16
+ "require": {
17
+ "types": "./gnomebluetooth-3.0.d.cts",
18
+ "default": "./gnomebluetooth-3.0.cjs"
19
+ }
20
+ }
21
+ },
22
+ "scripts": {
23
+ "test": "yarn test:esm && yarn test:cjs",
24
+ "test:esm": "NODE_OPTIONS=--max_old_space_size=9216 tsc --noEmit gnomebluetooth-3.0.d.ts",
25
+ "test:cjs": "NODE_OPTIONS=--max_old_space_size=9216 tsc --noEmit gnomebluetooth-3.0.d.cts"
26
+ },
27
+ "dependencies": {
28
+ "@girs/gio-2.0": "^2.78.0-3.2.4",
29
+ "@girs/gjs": "^3.2.4",
30
+ "@girs/glib-2.0": "^2.78.0-3.2.4",
31
+ "@girs/gobject-2.0": "^2.78.0-3.2.4"
32
+ },
33
+ "devDependencies": {
34
+ "typescript": "*"
35
+ },
36
+ "keywords": [
37
+ "Gir",
38
+ "TypeScript",
39
+ "types",
40
+ "GObject-Introspection",
41
+ "GJS",
42
+ "GnomeBluetooth-3.0"
43
+ ],
44
+ "author": "ts-for-gir",
45
+ "license": "MIT",
46
+ "repository": {
47
+ "type": "git",
48
+ "url": "git+https://github.com/gjsify/types.git"
49
+ },
50
+ "bugs": {
51
+ "url": "https://github.com/gjsify/ts-for-gir/issues"
52
+ },
53
+ "homepage": "https://github.com/gjsify/types/tree/main/gnomebluetooth-3.0#readme"
54
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,23 @@
1
+ {
2
+ "compilerOptions": {
3
+ // General settings for code interpretation
4
+ "target": "ESNext",
5
+ "module": "ESNext",
6
+ "lib": ["ESNext"],
7
+ "types": [],
8
+ "experimentalDecorators": true,
9
+ "moduleResolution": "node",
10
+ "noEmit": true,
11
+ "noEmitOnError": false,
12
+ "baseUrl": "./",
13
+ "rootDir": ".",
14
+ // General settings for code generation
15
+ "removeComments": false,
16
+ "inlineSourceMap": false,
17
+ "inlineSources": false,
18
+ "newLine": "LF"
19
+ },
20
+ "include": ["./gnomebluetooth-3.0.d.ts"]
21
+ }
22
+
23
+
package/typedoc.json ADDED
@@ -0,0 +1,7 @@
1
+ {
2
+ "entryPoints": ["./gnomebluetooth-3.0.d.ts"],
3
+ "readme": "./README.md",
4
+ "name": "GnomeBluetooth-3.0",
5
+ "tsconfig": "./tsconfig.json"
6
+ }
7
+