@girs/arrowflight-23.0 4.2.0 → 4.4.0

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 CHANGED
@@ -5,25 +5,25 @@
5
5
  ![downloads/week](https://img.shields.io/npm/dw/@girs/arrowflight-23.0)
6
6
 
7
7
 
8
- GJS TypeScript type definitions for ArrowFlight-23.0, generated from library version 23.0.1 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v4.2.0.
8
+ GJS TypeScript type definitions for ArrowFlight-23.0, generated from library version 23.0.1 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v4.4.0.
9
9
 
10
10
  ## Install
11
11
 
12
- To use this type definitions, install them with NPM:
12
+ Install the type definitions with npm:
13
13
  ```bash
14
14
  npm install @girs/arrowflight-23.0
15
15
  ```
16
16
 
17
17
  ## Usage
18
18
 
19
- You can import this package into your project like this:
19
+ Import it like any other module:
20
20
  ```ts
21
21
  import ArrowFlight from '@girs/arrowflight-23.0';
22
22
  ```
23
23
 
24
24
  ### Ambient Modules
25
25
 
26
- 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.
26
+ [Ambient modules](https://github.com/gjsify/ts-for-gir/tree/main/packages/cli#ambient-modules) let you write the same import you would in plain JavaScript.
27
27
  For this you need to include `@girs/arrowflight-23.0` or `@girs/arrowflight-23.0/ambient` in your `tsconfig` or entry point Typescript file:
28
28
 
29
29
  `index.ts`:
@@ -42,7 +42,7 @@ import '@girs/arrowflight-23.0'
42
42
  }
43
43
  ```
44
44
 
45
- Now you can import the ambient module with TypeScript support:
45
+ The ambient module now resolves with types:
46
46
 
47
47
  ```ts
48
48
  import ArrowFlight from 'gi://ArrowFlight?version=23.0';
@@ -50,7 +50,7 @@ import ArrowFlight from 'gi://ArrowFlight?version=23.0';
50
50
 
51
51
  ### Global import
52
52
 
53
- You can also import the module with Typescript support using the global `imports.gi` object of GJS.
53
+ GJS's global `imports.gi` works too, with types.
54
54
  For this you need to include `@girs/arrowflight-23.0` or `@girs/arrowflight-23.0/import` in your `tsconfig` or entry point Typescript file:
55
55
 
56
56
  `index.ts`:
@@ -69,7 +69,7 @@ import '@girs/arrowflight-23.0'
69
69
  }
70
70
  ```
71
71
 
72
- Now you have also type support for this, too:
72
+ That form carries types as well:
73
73
 
74
74
  ```ts
75
75
  const ArrowFlight = imports.gi.ArrowFlight;
@@ -77,7 +77,7 @@ const ArrowFlight = imports.gi.ArrowFlight;
77
77
 
78
78
  ### Bundle
79
79
 
80
- 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).
80
+ Most projects want a bundler. [esbuild](https://esbuild.github.io/) is the smallest thing that works; the [examples directory](https://github.com/gjsify/ts-for-gir/tree/main/examples) has setups for several others.
81
81
 
82
82
  ## Other packages
83
83
 
@@ -119,17 +119,20 @@ export namespace ArrowFlight {
119
119
  * Add a header.
120
120
  * @param name A header name.
121
121
  * @param value A header value.
122
+ * @since 9.0.0
122
123
  */
123
124
  add_header(name: string, value: string): void;
124
125
 
125
126
  /**
126
127
  * Clear all headers.
128
+ * @since 9.0.0
127
129
  */
128
130
  clear_headers(): void;
129
131
 
130
132
  /**
131
133
  * Iterates over all headers in the options.
132
134
  * @param func The user's callback function.
135
+ * @since 9.0.0
133
136
  */
134
137
  foreach_header(func: HeaderFunc): void;
135
138
  }
@@ -195,11 +198,13 @@ export namespace ArrowFlight {
195
198
  * @param password Password to be used.
196
199
  * @param options A {@link ArrowFlight.CallOptions}.
197
200
  * @returns `true` on success, `false` if there was an error.
201
+ * @since 12.0.0
198
202
  */
199
203
  authenticate_basic_token(user: string, password: string, options: CallOptions | null): [boolean, string, string];
200
204
 
201
205
  /**
202
206
  * @returns `true` on success, `false` if there was an error.
207
+ * @since 8.0.0
203
208
  */
204
209
  close(): boolean;
205
210
 
@@ -207,6 +212,7 @@ export namespace ArrowFlight {
207
212
  * @param ticket A {@link ArrowFlight.Ticket}.
208
213
  * @param options A {@link ArrowFlight.CallOptions}.
209
214
  * @returns The {@link ArrowFlight.StreamReader} to read record batched from the server on success, `null` on error.
215
+ * @since 6.0.0
210
216
  */
211
217
  do_get(ticket: Ticket, options: CallOptions | null): StreamReader | null;
212
218
 
@@ -222,6 +228,7 @@ export namespace ArrowFlight {
222
228
  * @param schema A {@link Arrow.Schema}.
223
229
  * @param options A {@link ArrowFlight.CallOptions}.
224
230
  * @returns The `GAFlighDoPutResult` holding a reader and a writer on success, `null` on error.
231
+ * @since 18.0.0
225
232
  */
226
233
  do_put(descriptor: Descriptor, schema: Arrow.Schema, options: CallOptions | null): DoPutResult | null;
227
234
 
@@ -229,6 +236,7 @@ export namespace ArrowFlight {
229
236
  * @param descriptor A {@link ArrowFlight.Descriptor} to be processed.
230
237
  * @param options A {@link ArrowFlight.CallOptions}.
231
238
  * @returns The returned {@link ArrowFlight.Info} on success, `null` on error.
239
+ * @since 9.0.0
232
240
  */
233
241
  get_flight_info(descriptor: Descriptor, options: CallOptions | null): Info | null;
234
242
 
@@ -236,6 +244,7 @@ export namespace ArrowFlight {
236
244
  * @param criteria A {@link ArrowFlight.Criteria}.
237
245
  * @param options A {@link ArrowFlight.CallOptions}.
238
246
  * @returns The returned list of {@link ArrowFlight.Info} on success, `null` on error.
247
+ * @since 5.0.0
239
248
  */
240
249
  list_flights(criteria: Criteria | null, options: CallOptions | null): Info[] | null;
241
250
  }
@@ -455,6 +464,7 @@ export namespace ArrowFlight {
455
464
  // Methods
456
465
  /**
457
466
  * @returns The opaque value used to express a command. It should be freed with `g_free()` when no longer needed.
467
+ * @since 5.0.0
458
468
  */
459
469
  get_command(): string;
460
470
  }
@@ -625,11 +635,13 @@ export namespace ArrowFlight {
625
635
  /**
626
636
  * @param other_descriptor A {@link ArrowFlight.Descriptor} to be compared.
627
637
  * @returns `true` if both of them represents the same descriptor, `false` otherwise.
638
+ * @since 5.0.0
628
639
  */
629
640
  equal(other_descriptor: Descriptor): boolean;
630
641
 
631
642
  /**
632
643
  * @returns A descriptor as a string. It should be freed with `g_free()` when no longer needed.
644
+ * @since 5.0.0
633
645
  */
634
646
  to_string(): string;
635
647
  }
@@ -765,11 +777,13 @@ export namespace ArrowFlight {
765
777
  /**
766
778
  * @param other_endpoint A {@link ArrowFlight.Endpoint} to be compared.
767
779
  * @returns `true` if both of them represents the same endpoint, `false` otherwise.
780
+ * @since 5.0.0
768
781
  */
769
782
  equal(other_endpoint: Endpoint): boolean;
770
783
 
771
784
  /**
772
785
  * @returns The locations in this endpoint. It must be freed with `g_list_free()` and `g_object_unref()` when no longer needed. You can use `g_list_free_full(locations, g_object_unref)`.
786
+ * @since 5.0.0
773
787
  */
774
788
  get_locations(): Location[] | null;
775
789
  }
@@ -832,32 +846,38 @@ export namespace ArrowFlight {
832
846
  /**
833
847
  * @param other_info A {@link ArrowFlight.Info} to be compared.
834
848
  * @returns `true` if both of them represents the same information, `false` otherwise.
849
+ * @since 5.0.0
835
850
  */
836
851
  equal(other_info: Info): boolean;
837
852
 
838
853
  /**
839
854
  * @returns The {@link ArrowFlight.Descriptor} of the information.
855
+ * @since 5.0.0
840
856
  */
841
857
  get_descriptor(): Descriptor;
842
858
 
843
859
  /**
844
860
  * @returns The list of {@link ArrowFlight.Endpoint} of the information.
861
+ * @since 5.0.0
845
862
  */
846
863
  get_endpoints(): Endpoint[];
847
864
 
848
865
  /**
849
866
  * @param options A {@link Arrow.ReadOptions}.
850
867
  * @returns Deserialized {@link Arrow.Schema}, `null` on error.
868
+ * @since 5.0.0
851
869
  */
852
870
  get_schema(options: Arrow.ReadOptions | null): Arrow.Schema;
853
871
 
854
872
  /**
855
873
  * @returns The number of total bytes of the information.
874
+ * @since 5.0.0
856
875
  */
857
876
  get_total_bytes(): number;
858
877
 
859
878
  /**
860
879
  * @returns The number of total records of the information.
880
+ * @since 5.0.0
861
881
  */
862
882
  get_total_records(): number;
863
883
  }
@@ -910,16 +930,19 @@ export namespace ArrowFlight {
910
930
  /**
911
931
  * @param other_location A {@link ArrowFlight.Location} to be compared.
912
932
  * @returns `true` if both of them represents the same URI, `false` otherwise.
933
+ * @since 5.0.0
913
934
  */
914
935
  equal(other_location: Location): boolean;
915
936
 
916
937
  /**
917
938
  * @returns The scheme of this URI. It should be freed with `g_free()` when no longer needed.
939
+ * @since 5.0.0
918
940
  */
919
941
  get_scheme(): string;
920
942
 
921
943
  /**
922
944
  * @returns A representation of this URI as a string. It should be freed with `g_free()` when no longer needed.
945
+ * @since 5.0.0
923
946
  */
924
947
  to_string(): string;
925
948
  }
@@ -972,6 +995,7 @@ export namespace ArrowFlight {
972
995
  // Methods
973
996
  /**
974
997
  * @returns The descriptor for this upload.
998
+ * @since 14.0.0
975
999
  */
976
1000
  get_descriptor(): Descriptor;
977
1001
  }
@@ -1031,6 +1055,7 @@ export namespace ArrowFlight {
1031
1055
  // Methods
1032
1056
  /**
1033
1057
  * @returns The metadata on success, `null` on error.
1058
+ * @since 18.0.0
1034
1059
  */
1035
1060
  read(): Arrow.Buffer;
1036
1061
  }
@@ -1092,6 +1117,7 @@ export namespace ArrowFlight {
1092
1117
  * Writes metadata to the client.
1093
1118
  * @param metadata A {@link Arrow.Buffer} to be sent.
1094
1119
  * @returns `true` on success, `false` on error.
1120
+ * @since 18.0.0
1095
1121
  */
1096
1122
  write(metadata: Arrow.Buffer): boolean;
1097
1123
  }
@@ -1145,6 +1171,7 @@ export namespace ArrowFlight {
1145
1171
  // Methods
1146
1172
  /**
1147
1173
  * @returns The paths in this descriptor. It must be freed with `g_strfreev()` when no longer needed.
1174
+ * @since 5.0.0
1148
1175
  */
1149
1176
  get_paths(): string[] | null;
1150
1177
  }
@@ -1219,11 +1246,13 @@ export namespace ArrowFlight {
1219
1246
  // Methods
1220
1247
  /**
1221
1248
  * @returns The all data on success, `null` on error.
1249
+ * @since 6.0.0
1222
1250
  */
1223
1251
  read_all(): Arrow.Table;
1224
1252
 
1225
1253
  /**
1226
1254
  * @returns The next chunk on success, `null` on end of stream, `null` on error.
1255
+ * @since 6.0.0
1227
1256
  */
1228
1257
  read_next(): StreamChunk;
1229
1258
  }
@@ -1337,6 +1366,7 @@ export namespace ArrowFlight {
1337
1366
  * @param schema A {@link Arrow.Schema}.
1338
1367
  * @param options A {@link Arrow.WriteOptions}.
1339
1368
  * @returns `true` on success, `false` on error.
1369
+ * @since 18.0.0
1340
1370
  */
1341
1371
  begin(schema: Arrow.Schema, options: Arrow.WriteOptions | null): boolean;
1342
1372
 
@@ -1344,6 +1374,7 @@ export namespace ArrowFlight {
1344
1374
  * Write metadata.
1345
1375
  * @param metadata A {@link Arrow.Buffer}.
1346
1376
  * @returns `true` on success, `false` on error.
1377
+ * @since 18.0.0
1347
1378
  */
1348
1379
  write_metadata(metadata: Arrow.Buffer): boolean;
1349
1380
 
@@ -1352,6 +1383,7 @@ export namespace ArrowFlight {
1352
1383
  * @param record_batch A {@link Arrow.RecordBatch}.
1353
1384
  * @param metadata A {@link Arrow.Buffer}.
1354
1385
  * @returns `true` on success, `false` on error.
1386
+ * @since 18.0.0
1355
1387
  */
1356
1388
  write_record_batch(record_batch: Arrow.RecordBatch, metadata: Arrow.Buffer | null): boolean;
1357
1389
 
@@ -1409,6 +1441,7 @@ export namespace ArrowFlight {
1409
1441
  * A virtual function to implement `DoGet` API.
1410
1442
  * @param context A {@link ArrowFlight.ServerCallContext}.
1411
1443
  * @param ticket A {@link ArrowFlight.Ticket}.
1444
+ * @since 6.0.0
1412
1445
  * @virtual
1413
1446
  */
1414
1447
  vfunc_do_get(context: ServerCallContext, ticket: Ticket): DataStream;
@@ -1418,6 +1451,7 @@ export namespace ArrowFlight {
1418
1451
  * @param context A {@link ArrowFlight.ServerCallContext}.
1419
1452
  * @param reader A {@link ArrowFlight.MessageReader}.
1420
1453
  * @param writer A {@link ArrowFlight.MetadataWriter}.
1454
+ * @since 18.0.0
1421
1455
  * @virtual
1422
1456
  */
1423
1457
  vfunc_do_put(context: ServerCallContext, reader: MessageReader, writer: MetadataWriter): boolean;
@@ -1425,6 +1459,7 @@ export namespace ArrowFlight {
1425
1459
  /**
1426
1460
  * @param context A {@link ArrowFlight.ServerCallContext}.
1427
1461
  * @param request A {@link ArrowFlight.Descriptor}.
1462
+ * @since 9.0.0
1428
1463
  * @virtual
1429
1464
  */
1430
1465
  vfunc_get_flight_info(context: ServerCallContext, request: Descriptor): Info;
@@ -1433,6 +1468,7 @@ export namespace ArrowFlight {
1433
1468
  * A virtual function to implement `ListFlights` API.
1434
1469
  * @param context A {@link ArrowFlight.ServerCallContext}.
1435
1470
  * @param criteria A {@link ArrowFlight.Criteria}.
1471
+ * @since 5.0.0
1436
1472
  * @virtual
1437
1473
  */
1438
1474
  vfunc_list_flights(context: ServerCallContext, criteria: Criteria | null): Info[];
@@ -1442,6 +1478,7 @@ export namespace ArrowFlight {
1442
1478
  * @param context A {@link ArrowFlight.ServerCallContext}.
1443
1479
  * @param ticket A {@link ArrowFlight.Ticket}.
1444
1480
  * @returns {@link ArrowFlight.DataStream} on success, `null` on error.
1481
+ * @since 6.0.0
1445
1482
  */
1446
1483
  do_get(context: ServerCallContext, ticket: Ticket): DataStream;
1447
1484
 
@@ -1451,6 +1488,7 @@ export namespace ArrowFlight {
1451
1488
  * @param reader A {@link ArrowFlight.MessageReader}.
1452
1489
  * @param writer A {@link ArrowFlight.MetadataWriter}.
1453
1490
  * @returns `true` on success, `false` on error.
1491
+ * @since 18.0.0
1454
1492
  */
1455
1493
  do_put(context: ServerCallContext, reader: MessageReader, writer: MetadataWriter): boolean;
1456
1494
 
@@ -1458,6 +1496,7 @@ export namespace ArrowFlight {
1458
1496
  * @param context A {@link ArrowFlight.ServerCallContext}.
1459
1497
  * @param request A {@link ArrowFlight.Descriptor}.
1460
1498
  * @returns A {@link ArrowFlight.Info} on success, `null` on error.
1499
+ * @since 9.0.0
1461
1500
  */
1462
1501
  get_flight_info(context: ServerCallContext, request: Descriptor): Info;
1463
1502
 
@@ -1467,12 +1506,14 @@ export namespace ArrowFlight {
1467
1506
  * @param context A {@link ArrowFlight.ServerCallContext}.
1468
1507
  * @param criteria A {@link ArrowFlight.Criteria}.
1469
1508
  * @returns {@link GLib.List} of {@link ArrowFlight.Info} on success, `null` on error.
1509
+ * @since 5.0.0
1470
1510
  */
1471
1511
  list_flights(context: ServerCallContext, criteria: Criteria | null): Info[];
1472
1512
 
1473
1513
  /**
1474
1514
  * @param options A {@link ArrowFlight.ServerOptions}.
1475
1515
  * @returns `true` on success, `false` on error.
1516
+ * @since 5.0.0
1476
1517
  */
1477
1518
  listen(options: ServerOptions): boolean;
1478
1519
 
@@ -1480,6 +1521,7 @@ export namespace ArrowFlight {
1480
1521
  * Shuts down the serve. This function can be called from signal
1481
1522
  * handler or another thread.
1482
1523
  * @returns `true` on success, `false` on error.
1524
+ * @since 5.0.0
1483
1525
  */
1484
1526
  shutdown(): boolean;
1485
1527
 
@@ -1595,6 +1637,7 @@ export namespace ArrowFlight {
1595
1637
  /**
1596
1638
  * Reads a message from the client.
1597
1639
  * @returns Read data as {@link GLib.Bytes} on success, `null` on error.
1640
+ * @since 12.0.0
1598
1641
  */
1599
1642
  read(): GLib.Bytes | null;
1600
1643
  }
@@ -1656,6 +1699,7 @@ export namespace ArrowFlight {
1656
1699
  * Writes a message to the client.
1657
1700
  * @param message A {@link GLib.Bytes} to be sent.
1658
1701
  * @returns `true` on success, `false` on error.
1702
+ * @since 12.0.0
1659
1703
  */
1660
1704
  write(message: GLib.Bytes | Uint8Array): boolean;
1661
1705
  }
@@ -1722,6 +1766,7 @@ export namespace ArrowFlight {
1722
1766
  /**
1723
1767
  * Iterates over all incoming headers.
1724
1768
  * @param func The user's callback function.
1769
+ * @since 14.0.0
1725
1770
  */
1726
1771
  foreach_incoming_header(func: HeaderFunc): void;
1727
1772
  }
@@ -1777,6 +1822,7 @@ export namespace ArrowFlight {
1777
1822
  * @param context A {@link ArrowFlight.ServerCallContext}.
1778
1823
  * @param sender A {@link ArrowFlight.ServerAuthSender}.
1779
1824
  * @param reader A {@link ArrowFlight.ServerAuthReader}.
1825
+ * @since 12.0.0
1780
1826
  * @virtual
1781
1827
  */
1782
1828
  vfunc_authenticate(context: ServerCallContext, sender: ServerAuthSender, reader: ServerAuthReader): void;
@@ -1785,6 +1831,7 @@ export namespace ArrowFlight {
1785
1831
  * Validates a per-call client token.
1786
1832
  * @param context A {@link ArrowFlight.ServerCallContext}.
1787
1833
  * @param token The client token. May be the empty string if the client does not provide a token.
1834
+ * @since 12.0.0
1788
1835
  * @virtual
1789
1836
  */
1790
1837
  vfunc_is_valid(context: ServerCallContext, token: GLib.Bytes): GLib.Bytes | Uint8Array | null;
@@ -1796,6 +1843,7 @@ export namespace ArrowFlight {
1796
1843
  * @param context A {@link ArrowFlight.ServerCallContext}.
1797
1844
  * @param sender A {@link ArrowFlight.ServerAuthSender}.
1798
1845
  * @param reader A {@link ArrowFlight.ServerAuthReader}.
1846
+ * @since 12.0.0
1799
1847
  */
1800
1848
  authenticate(context: ServerCallContext, sender: ServerAuthSender, reader: ServerAuthReader): void;
1801
1849
 
@@ -1804,6 +1852,7 @@ export namespace ArrowFlight {
1804
1852
  * @param context A {@link ArrowFlight.ServerCallContext}.
1805
1853
  * @param token The client token. May be the empty string if the client does not provide a token.
1806
1854
  * @returns The identity of the peer, if this authentication method supports it.
1855
+ * @since 12.0.0
1807
1856
  */
1808
1857
  is_valid(context: ServerCallContext, token: GLib.Bytes | Uint8Array): GLib.Bytes | null;
1809
1858
  }
@@ -1937,6 +1986,7 @@ export namespace ArrowFlight {
1937
1986
  // Methods
1938
1987
  /**
1939
1988
  * @returns The data of the chunk.
1989
+ * @since 6.0.0
1940
1990
  */
1941
1991
  get_data(): Arrow.RecordBatch;
1942
1992
 
@@ -1948,6 +1998,7 @@ export namespace ArrowFlight {
1948
1998
 
1949
1999
  /**
1950
2000
  * @returns The metadata of the chunk. The metadata may be NULL.
2001
+ * @since 6.0.0
1951
2002
  */
1952
2003
  get_metadata(): Arrow.Buffer | null;
1953
2004
  }
@@ -2045,6 +2096,7 @@ export namespace ArrowFlight {
2045
2096
  // Methods
2046
2097
  /**
2047
2098
  * @returns `true` on success, `false` on error.
2099
+ * @since 18.0.0
2048
2100
  */
2049
2101
  done_writing(): boolean;
2050
2102
  }
@@ -2110,6 +2162,7 @@ export namespace ArrowFlight {
2110
2162
  /**
2111
2163
  * @param other_ticket A {@link ArrowFlight.Ticket} to be compared.
2112
2164
  * @returns `true` if both of them represents the same ticket, `false` otherwise.
2165
+ * @since 5.0.0
2113
2166
  */
2114
2167
  equal(other_ticket: Ticket): boolean;
2115
2168
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@girs/arrowflight-23.0",
3
- "version": "4.2.0",
3
+ "version": "4.4.0",
4
4
  "libraryVersion": "23.0.1",
5
5
  "description": "GJS TypeScript type definitions for ArrowFlight-23.0, generated from library version 23.0.1",
6
6
  "type": "module",
@@ -32,12 +32,12 @@
32
32
  "test": "tsc --project tsconfig.json"
33
33
  },
34
34
  "dependencies": {
35
- "@girs/gjs": "^4.2.0",
36
- "@girs/arrow-23.0": "^4.2.0",
37
- "@girs/gio-2.0": "^4.2.0",
38
- "@girs/gobject-2.0": "^4.2.0",
39
- "@girs/glib-2.0": "^4.2.0",
40
- "@girs/gmodule-2.0": "^4.2.0" },
35
+ "@girs/gjs": "^4.4.0",
36
+ "@girs/arrow-23.0": "^4.4.0",
37
+ "@girs/gio-2.0": "^4.4.0",
38
+ "@girs/gobject-2.0": "^4.4.0",
39
+ "@girs/glib-2.0": "^4.4.0",
40
+ "@girs/gmodule-2.0": "^4.4.0" },
41
41
  "devDependencies": {
42
42
  "typescript": "*"
43
43
  },