@dbx-tools/google-rs 0.6.188 → 0.6.191
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/index.ts +1 -1
- package/lib/index.js +15 -13
- package/package.json +9 -8
- package/src/_bindings-ffi.ts +6 -6
- package/src/_bindings.ts +16 -13
package/index.ts
CHANGED
package/lib/index.js
CHANGED
|
@@ -264,7 +264,7 @@ var DEFINITIONS = {
|
|
|
264
264
|
hasRustCallStatus: false
|
|
265
265
|
},
|
|
266
266
|
uniffi_dbx_tools_google_fn_method_googleauth_force_refresh_token: {
|
|
267
|
-
args: [FfiType.Handle],
|
|
267
|
+
args: [FfiType.Handle, FfiType.RustBuffer],
|
|
268
268
|
ret: FfiType.Handle,
|
|
269
269
|
hasRustCallStatus: false
|
|
270
270
|
},
|
|
@@ -274,7 +274,7 @@ var DEFINITIONS = {
|
|
|
274
274
|
hasRustCallStatus: false
|
|
275
275
|
},
|
|
276
276
|
uniffi_dbx_tools_google_fn_method_googleauth_refresh_rejected_token: {
|
|
277
|
-
args: [FfiType.Handle, FfiType.RustBuffer],
|
|
277
|
+
args: [FfiType.Handle, FfiType.RustBuffer, FfiType.RustBuffer],
|
|
278
278
|
ret: FfiType.Handle,
|
|
279
279
|
hasRustCallStatus: false
|
|
280
280
|
},
|
|
@@ -284,7 +284,7 @@ var DEFINITIONS = {
|
|
|
284
284
|
hasRustCallStatus: true
|
|
285
285
|
},
|
|
286
286
|
uniffi_dbx_tools_google_fn_method_googleauth_token: {
|
|
287
|
-
args: [FfiType.Handle],
|
|
287
|
+
args: [FfiType.Handle, FfiType.RustBuffer],
|
|
288
288
|
ret: FfiType.Handle,
|
|
289
289
|
hasRustCallStatus: false
|
|
290
290
|
},
|
|
@@ -362,6 +362,7 @@ var _bindings_ffi_default = getter;
|
|
|
362
362
|
// src/_bindings.ts
|
|
363
363
|
import {
|
|
364
364
|
AbstractFfiConverterByteArray,
|
|
365
|
+
FfiConverterBool,
|
|
365
366
|
FfiConverterObject,
|
|
366
367
|
FfiConverterOptional,
|
|
367
368
|
FfiConverterUInt64,
|
|
@@ -480,11 +481,11 @@ class GoogleAuth extends UniffiAbstractObject {
|
|
|
480
481
|
this[pointerLiteralSymbol] = pointer;
|
|
481
482
|
this[destructorGuardSymbol] = uniffiTypeGoogleAuthObjectFactory.bless(pointer);
|
|
482
483
|
}
|
|
483
|
-
async forceRefreshToken(asyncOpts_) {
|
|
484
|
+
async forceRefreshToken(login = undefined, asyncOpts_) {
|
|
484
485
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
485
486
|
try {
|
|
486
487
|
return await uniffiRustCallAsync(uniffiCaller, () => {
|
|
487
|
-
return _bindings_ffi_default().uniffi_dbx_tools_google_fn_method_googleauth_force_refresh_token(uniffiTypeGoogleAuthObjectFactory.clonePointer(this));
|
|
488
|
+
return _bindings_ffi_default().uniffi_dbx_tools_google_fn_method_googleauth_force_refresh_token(uniffiTypeGoogleAuthObjectFactory.clonePointer(this), FfiConverterOptionalBoolean.lower(login, _bindings_ffi_default().rustbuffer_alloc));
|
|
488
489
|
}, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_poll_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_cancel_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_complete_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_free_rust_buffer, (__rb) => {
|
|
489
490
|
try {
|
|
490
491
|
return FfiConverterTypeAccessToken.lift(__rb);
|
|
@@ -512,11 +513,11 @@ class GoogleAuth extends UniffiAbstractObject {
|
|
|
512
513
|
throw __error;
|
|
513
514
|
}
|
|
514
515
|
}
|
|
515
|
-
async refreshRejectedToken(staleAccessToken, asyncOpts_) {
|
|
516
|
+
async refreshRejectedToken(staleAccessToken, login = undefined, asyncOpts_) {
|
|
516
517
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
517
518
|
try {
|
|
518
519
|
return await uniffiRustCallAsync(uniffiCaller, () => {
|
|
519
|
-
return _bindings_ffi_default().uniffi_dbx_tools_google_fn_method_googleauth_refresh_rejected_token(uniffiTypeGoogleAuthObjectFactory.clonePointer(this), FfiConverterString.lower(staleAccessToken, _bindings_ffi_default().rustbuffer_alloc));
|
|
520
|
+
return _bindings_ffi_default().uniffi_dbx_tools_google_fn_method_googleauth_refresh_rejected_token(uniffiTypeGoogleAuthObjectFactory.clonePointer(this), FfiConverterString.lower(staleAccessToken, _bindings_ffi_default().rustbuffer_alloc), FfiConverterOptionalBoolean.lower(login, _bindings_ffi_default().rustbuffer_alloc));
|
|
520
521
|
}, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_poll_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_cancel_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_complete_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_free_rust_buffer, (__rb) => {
|
|
521
522
|
try {
|
|
522
523
|
return FfiConverterTypeAccessToken.lift(__rb);
|
|
@@ -541,11 +542,11 @@ class GoogleAuth extends UniffiAbstractObject {
|
|
|
541
542
|
_bindings_ffi_default().rustbuffer_free(__rb);
|
|
542
543
|
}
|
|
543
544
|
}
|
|
544
|
-
async token(asyncOpts_) {
|
|
545
|
+
async token(login = undefined, asyncOpts_) {
|
|
545
546
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
546
547
|
try {
|
|
547
548
|
return await uniffiRustCallAsync(uniffiCaller, () => {
|
|
548
|
-
return _bindings_ffi_default().uniffi_dbx_tools_google_fn_method_googleauth_token(uniffiTypeGoogleAuthObjectFactory.clonePointer(this));
|
|
549
|
+
return _bindings_ffi_default().uniffi_dbx_tools_google_fn_method_googleauth_token(uniffiTypeGoogleAuthObjectFactory.clonePointer(this), FfiConverterOptionalBoolean.lower(login, _bindings_ffi_default().rustbuffer_alloc));
|
|
549
550
|
}, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_poll_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_cancel_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_complete_rust_buffer, _bindings_ffi_default().ffi_dbx_tools_google_rust_future_free_rust_buffer, (__rb) => {
|
|
550
551
|
try {
|
|
551
552
|
return FfiConverterTypeAccessToken.lift(__rb);
|
|
@@ -623,6 +624,7 @@ var uniffiTypeGoogleAuthObjectFactory = (() => {
|
|
|
623
624
|
var FfiConverterTypeGoogleAuth = new FfiConverterObject(uniffiTypeGoogleAuthObjectFactory);
|
|
624
625
|
var FfiConverterOptionalTypeAuthOptions = new FfiConverterOptional(FfiConverterTypeAuthOptions);
|
|
625
626
|
var FfiConverterOptionalString = new FfiConverterOptional(FfiConverterString);
|
|
627
|
+
var FfiConverterOptionalBoolean = new FfiConverterOptional(FfiConverterBool);
|
|
626
628
|
function uniffiEnsureInitialized() {
|
|
627
629
|
const bindingsContractVersion = 30;
|
|
628
630
|
const scaffoldingContractVersion = _bindings_ffi_default().ffi_dbx_tools_google_uniffi_contract_version();
|
|
@@ -632,19 +634,19 @@ function uniffiEnsureInitialized() {
|
|
|
632
634
|
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_func_create_google_auth() !== 8482) {
|
|
633
635
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_func_create_google_auth");
|
|
634
636
|
}
|
|
635
|
-
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_method_googleauth_force_refresh_token() !==
|
|
637
|
+
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_method_googleauth_force_refresh_token() !== 40331) {
|
|
636
638
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_force_refresh_token");
|
|
637
639
|
}
|
|
638
640
|
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_method_googleauth_logout() !== 28220) {
|
|
639
641
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_logout");
|
|
640
642
|
}
|
|
641
|
-
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_method_googleauth_refresh_rejected_token() !==
|
|
643
|
+
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_method_googleauth_refresh_rejected_token() !== 47983) {
|
|
642
644
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_refresh_rejected_token");
|
|
643
645
|
}
|
|
644
646
|
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_method_googleauth_status() !== 21388) {
|
|
645
647
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_status");
|
|
646
648
|
}
|
|
647
|
-
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_method_googleauth_token() !==
|
|
649
|
+
if (_bindings_ffi_default().uniffi_dbx_tools_google_checksum_method_googleauth_token() !== 53387) {
|
|
648
650
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_token");
|
|
649
651
|
}
|
|
650
652
|
}
|
|
@@ -662,7 +664,7 @@ async function uniffiInitAsync() {}
|
|
|
662
664
|
|
|
663
665
|
// index.ts
|
|
664
666
|
var PACKAGE_IDENTIFIER = "@dbx-tools/google-rs";
|
|
665
|
-
var PACKAGE_VERSION = "0.6.
|
|
667
|
+
var PACKAGE_VERSION = "0.6.191";
|
|
666
668
|
export {
|
|
667
669
|
_bindings_default as uniffiModule,
|
|
668
670
|
uniffiInitAsync,
|
package/package.json
CHANGED
|
@@ -7,14 +7,14 @@
|
|
|
7
7
|
"directory": "packages/js/node/google-rs"
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@dbx-tools/core-rs": "0.6.
|
|
11
|
-
"@dbx-tools/shared-core": "0.6.
|
|
10
|
+
"@dbx-tools/core-rs": "0.6.191",
|
|
11
|
+
"@dbx-tools/shared-core": "0.6.191",
|
|
12
12
|
"@ubjs/core": "0.31.0-5",
|
|
13
13
|
"@ubjs/node": "0.31.0-5"
|
|
14
14
|
},
|
|
15
15
|
"main": "./lib/index.js",
|
|
16
16
|
"license": "Apache-2.0",
|
|
17
|
-
"version": "0.6.
|
|
17
|
+
"version": "0.6.191",
|
|
18
18
|
"types": "./index.ts",
|
|
19
19
|
"type": "module",
|
|
20
20
|
"exports": {
|
|
@@ -30,11 +30,12 @@
|
|
|
30
30
|
"lib"
|
|
31
31
|
],
|
|
32
32
|
"optionalDependencies": {
|
|
33
|
-
"@dbx-tools/google-rs-linux-x64-gnu": "0.6.
|
|
34
|
-
"@dbx-tools/google-rs-linux-arm64-gnu": "0.6.
|
|
35
|
-
"@dbx-tools/google-rs-darwin-x64": "0.6.
|
|
36
|
-
"@dbx-tools/google-rs-darwin-arm64": "0.6.
|
|
37
|
-
"@dbx-tools/google-rs-win32-x64-msvc": "0.6.
|
|
33
|
+
"@dbx-tools/google-rs-linux-x64-gnu": "0.6.191",
|
|
34
|
+
"@dbx-tools/google-rs-linux-arm64-gnu": "0.6.191",
|
|
35
|
+
"@dbx-tools/google-rs-darwin-x64": "0.6.191",
|
|
36
|
+
"@dbx-tools/google-rs-darwin-arm64": "0.6.191",
|
|
37
|
+
"@dbx-tools/google-rs-win32-x64-msvc": "0.6.191",
|
|
38
|
+
"@dbx-tools/google-rs-win32-arm64-msvc": "0.6.191"
|
|
38
39
|
},
|
|
39
40
|
"dbxToolsConfig": {
|
|
40
41
|
"uniffi": true,
|
package/src/_bindings-ffi.ts
CHANGED
|
@@ -281,7 +281,7 @@ const DEFINITIONS = {
|
|
|
281
281
|
hasRustCallStatus: false,
|
|
282
282
|
},
|
|
283
283
|
"uniffi_dbx_tools_google_fn_method_googleauth_force_refresh_token": {
|
|
284
|
-
args: [FfiType.Handle],
|
|
284
|
+
args: [FfiType.Handle, FfiType.RustBuffer],
|
|
285
285
|
ret: FfiType.Handle,
|
|
286
286
|
hasRustCallStatus: false,
|
|
287
287
|
},
|
|
@@ -291,7 +291,7 @@ const DEFINITIONS = {
|
|
|
291
291
|
hasRustCallStatus: false,
|
|
292
292
|
},
|
|
293
293
|
"uniffi_dbx_tools_google_fn_method_googleauth_refresh_rejected_token": {
|
|
294
|
-
args: [FfiType.Handle, FfiType.RustBuffer],
|
|
294
|
+
args: [FfiType.Handle, FfiType.RustBuffer, FfiType.RustBuffer],
|
|
295
295
|
ret: FfiType.Handle,
|
|
296
296
|
hasRustCallStatus: false,
|
|
297
297
|
},
|
|
@@ -301,7 +301,7 @@ const DEFINITIONS = {
|
|
|
301
301
|
hasRustCallStatus: true,
|
|
302
302
|
},
|
|
303
303
|
"uniffi_dbx_tools_google_fn_method_googleauth_token": {
|
|
304
|
-
args: [FfiType.Handle],
|
|
304
|
+
args: [FfiType.Handle, FfiType.RustBuffer],
|
|
305
305
|
ret: FfiType.Handle,
|
|
306
306
|
hasRustCallStatus: false,
|
|
307
307
|
},
|
|
@@ -413,11 +413,11 @@ interface NativeModuleInterface {
|
|
|
413
413
|
uniffi_dbx_tools_google_fn_clone_googleauth(ptr: bigint, uniffi_out_err: UniffiRustCallStatus): bigint;
|
|
414
414
|
uniffi_dbx_tools_google_fn_free_googleauth(ptr: bigint, uniffi_out_err: UniffiRustCallStatus): void;
|
|
415
415
|
uniffi_dbx_tools_google_fn_func_create_google_auth(options: Uint8Array): bigint;
|
|
416
|
-
uniffi_dbx_tools_google_fn_method_googleauth_force_refresh_token(uniffiSelf: bigint): bigint;
|
|
416
|
+
uniffi_dbx_tools_google_fn_method_googleauth_force_refresh_token(uniffiSelf: bigint, login: Uint8Array): bigint;
|
|
417
417
|
uniffi_dbx_tools_google_fn_method_googleauth_logout(uniffiSelf: bigint): bigint;
|
|
418
|
-
uniffi_dbx_tools_google_fn_method_googleauth_refresh_rejected_token(uniffiSelf: bigint, staleAccessToken: Uint8Array): bigint;
|
|
418
|
+
uniffi_dbx_tools_google_fn_method_googleauth_refresh_rejected_token(uniffiSelf: bigint, staleAccessToken: Uint8Array, login: Uint8Array): bigint;
|
|
419
419
|
uniffi_dbx_tools_google_fn_method_googleauth_status(uniffiSelf: bigint, uniffi_out_err: UniffiRustCallStatus): Uint8Array;
|
|
420
|
-
uniffi_dbx_tools_google_fn_method_googleauth_token(uniffiSelf: bigint): bigint;
|
|
420
|
+
uniffi_dbx_tools_google_fn_method_googleauth_token(uniffiSelf: bigint, login: Uint8Array): bigint;
|
|
421
421
|
ffi_dbx_tools_google_uniffi_contract_version(): number;
|
|
422
422
|
uniffi_dbx_tools_google_checksum_func_create_google_auth(): number;
|
|
423
423
|
uniffi_dbx_tools_google_checksum_method_googleauth_force_refresh_token(): number;
|
package/src/_bindings.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { type UniffiRustFutureContinuationCallback, type UniffiForeignFutureDrop
|
|
|
11
11
|
} from "./_bindings-ffi.ts";
|
|
12
12
|
import { type AccessToken, type AuthOptions, AuthError,
|
|
13
13
|
} from "@dbx-tools/core-rs";
|
|
14
|
-
import { type FfiConverter, type UniffiByteArray, type UniffiGcObject, type UniffiHandle, type UniffiObjectFactory, AbstractFfiConverterByteArray, Cursor, FfiConverterObject, FfiConverterOptional, FfiConverterUInt64, RustBuffer, UniffiAbstractObject, UniffiInternalError, UniffiRustCaller, destructorGuardSymbol, pointerLiteralSymbol, uniffiCreateFfiConverterString, uniffiCreateRecord, uniffiRustCallAsync, uniffiTypeNameSymbol,
|
|
14
|
+
import { type FfiConverter, type UniffiByteArray, type UniffiGcObject, type UniffiHandle, type UniffiObjectFactory, AbstractFfiConverterByteArray, Cursor, FfiConverterBool, FfiConverterObject, FfiConverterOptional, FfiConverterUInt64, RustBuffer, UniffiAbstractObject, UniffiInternalError, UniffiRustCaller, destructorGuardSymbol, pointerLiteralSymbol, uniffiCreateFfiConverterString, uniffiCreateRecord, uniffiRustCallAsync, uniffiTypeNameSymbol,
|
|
15
15
|
} from "@ubjs/core";
|
|
16
16
|
import { uniffiModule as uniffiDbxToolsCoreModule } from "@dbx-tools/core-rs";
|
|
17
17
|
const { FfiConverterTypeAccessToken, FfiConverterTypeAuthError, FfiConverterTypeAuthOptions } = uniffiDbxToolsCoreModule.converters;
|
|
@@ -195,7 +195,7 @@ export interface GoogleAuthLike {
|
|
|
195
195
|
/**
|
|
196
196
|
* Refresh ADC even when the current token is outside its refresh window.
|
|
197
197
|
*/
|
|
198
|
-
forceRefreshToken(asyncOpts_?: { signal: AbortSignal }) /*throws*/: Promise<AccessToken>;
|
|
198
|
+
forceRefreshToken(login?: boolean | undefined, asyncOpts_?: { signal: AbortSignal }) /*throws*/: Promise<AccessToken>;
|
|
199
199
|
/**
|
|
200
200
|
* Clear the in-process access-token cache without modifying ADC.
|
|
201
201
|
*/
|
|
@@ -203,7 +203,7 @@ export interface GoogleAuthLike {
|
|
|
203
203
|
/**
|
|
204
204
|
* Reuse a concurrent replacement or refresh the rejected access token.
|
|
205
205
|
*/
|
|
206
|
-
refreshRejectedToken(staleAccessToken: string, asyncOpts_?: { signal: AbortSignal }) /*throws*/: Promise<AccessToken>;
|
|
206
|
+
refreshRejectedToken(staleAccessToken: string, login?: boolean | undefined, asyncOpts_?: { signal: AbortSignal }) /*throws*/: Promise<AccessToken>;
|
|
207
207
|
/**
|
|
208
208
|
* Return the selected ADC path and short-lived token storage mode.
|
|
209
209
|
*/
|
|
@@ -211,7 +211,7 @@ export interface GoogleAuthLike {
|
|
|
211
211
|
/**
|
|
212
212
|
* Return a cached token or refresh it from ADC.
|
|
213
213
|
*/
|
|
214
|
-
token(asyncOpts_?: { signal: AbortSignal }) /*throws*/: Promise<AccessToken>;
|
|
214
|
+
token(login?: boolean | undefined, asyncOpts_?: { signal: AbortSignal }) /*throws*/: Promise<AccessToken>;
|
|
215
215
|
}
|
|
216
216
|
/**
|
|
217
217
|
* @deprecated Use `GoogleAuthLike` instead.
|
|
@@ -240,14 +240,14 @@ private constructor(pointer: UniffiHandle) {
|
|
|
240
240
|
/**
|
|
241
241
|
* Refresh ADC even when the current token is outside its refresh window.
|
|
242
242
|
*/
|
|
243
|
-
async forceRefreshToken(asyncOpts_?: { signal: AbortSignal }): Promise<AccessToken> /*throws*/ {
|
|
243
|
+
async forceRefreshToken(login: boolean | undefined = undefined, asyncOpts_?: { signal: AbortSignal }): Promise<AccessToken> /*throws*/ {
|
|
244
244
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
245
245
|
try {
|
|
246
246
|
return await uniffiRustCallAsync(
|
|
247
247
|
/*rustCaller:*/ uniffiCaller,
|
|
248
248
|
/*rustFutureFunc:*/ () => {
|
|
249
249
|
return nativeModule().uniffi_dbx_tools_google_fn_method_googleauth_force_refresh_token(
|
|
250
|
-
uniffiTypeGoogleAuthObjectFactory.clonePointer(this)
|
|
250
|
+
uniffiTypeGoogleAuthObjectFactory.clonePointer(this),FfiConverterOptionalBoolean.lower(login, nativeModule().rustbuffer_alloc)
|
|
251
251
|
);
|
|
252
252
|
},
|
|
253
253
|
/*pollFunc:*/ nativeModule().ffi_dbx_tools_google_rust_future_poll_rust_buffer,
|
|
@@ -314,14 +314,14 @@ private constructor(pointer: UniffiHandle) {
|
|
|
314
314
|
/**
|
|
315
315
|
* Reuse a concurrent replacement or refresh the rejected access token.
|
|
316
316
|
*/
|
|
317
|
-
async refreshRejectedToken(staleAccessToken: string, asyncOpts_?: { signal: AbortSignal }): Promise<AccessToken> /*throws*/ {
|
|
317
|
+
async refreshRejectedToken(staleAccessToken: string, login: boolean | undefined = undefined, asyncOpts_?: { signal: AbortSignal }): Promise<AccessToken> /*throws*/ {
|
|
318
318
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
319
319
|
try {
|
|
320
320
|
return await uniffiRustCallAsync(
|
|
321
321
|
/*rustCaller:*/ uniffiCaller,
|
|
322
322
|
/*rustFutureFunc:*/ () => {
|
|
323
323
|
return nativeModule().uniffi_dbx_tools_google_fn_method_googleauth_refresh_rejected_token(
|
|
324
|
-
uniffiTypeGoogleAuthObjectFactory.clonePointer(this),FfiConverterString.lower(staleAccessToken, nativeModule().rustbuffer_alloc)
|
|
324
|
+
uniffiTypeGoogleAuthObjectFactory.clonePointer(this),FfiConverterString.lower(staleAccessToken, nativeModule().rustbuffer_alloc),FfiConverterOptionalBoolean.lower(login, nativeModule().rustbuffer_alloc)
|
|
325
325
|
);
|
|
326
326
|
},
|
|
327
327
|
/*pollFunc:*/ nativeModule().ffi_dbx_tools_google_rust_future_poll_rust_buffer,
|
|
@@ -377,14 +377,14 @@ private constructor(pointer: UniffiHandle) {
|
|
|
377
377
|
/**
|
|
378
378
|
* Return a cached token or refresh it from ADC.
|
|
379
379
|
*/
|
|
380
|
-
async token(asyncOpts_?: { signal: AbortSignal }): Promise<AccessToken> /*throws*/ {
|
|
380
|
+
async token(login: boolean | undefined = undefined, asyncOpts_?: { signal: AbortSignal }): Promise<AccessToken> /*throws*/ {
|
|
381
381
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
382
382
|
try {
|
|
383
383
|
return await uniffiRustCallAsync(
|
|
384
384
|
/*rustCaller:*/ uniffiCaller,
|
|
385
385
|
/*rustFutureFunc:*/ () => {
|
|
386
386
|
return nativeModule().uniffi_dbx_tools_google_fn_method_googleauth_token(
|
|
387
|
-
uniffiTypeGoogleAuthObjectFactory.clonePointer(this)
|
|
387
|
+
uniffiTypeGoogleAuthObjectFactory.clonePointer(this),FfiConverterOptionalBoolean.lower(login, nativeModule().rustbuffer_alloc)
|
|
388
388
|
);
|
|
389
389
|
},
|
|
390
390
|
/*pollFunc:*/ nativeModule().ffi_dbx_tools_google_rust_future_poll_rust_buffer,
|
|
@@ -504,6 +504,9 @@ const FfiConverterOptionalTypeAuthOptions = new FfiConverterOptional(FfiConverte
|
|
|
504
504
|
// FfiConverter for string | undefined
|
|
505
505
|
const FfiConverterOptionalString = new FfiConverterOptional(FfiConverterString);
|
|
506
506
|
|
|
507
|
+
// FfiConverter for boolean | undefined
|
|
508
|
+
const FfiConverterOptionalBoolean = new FfiConverterOptional(FfiConverterBool);
|
|
509
|
+
|
|
507
510
|
|
|
508
511
|
/**
|
|
509
512
|
* This should be called before anything else.
|
|
@@ -526,19 +529,19 @@ function uniffiEnsureInitialized() {
|
|
|
526
529
|
if (nativeModule().uniffi_dbx_tools_google_checksum_func_create_google_auth() !== 8482) {
|
|
527
530
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_func_create_google_auth");
|
|
528
531
|
}
|
|
529
|
-
if (nativeModule().uniffi_dbx_tools_google_checksum_method_googleauth_force_refresh_token() !==
|
|
532
|
+
if (nativeModule().uniffi_dbx_tools_google_checksum_method_googleauth_force_refresh_token() !== 40331) {
|
|
530
533
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_force_refresh_token");
|
|
531
534
|
}
|
|
532
535
|
if (nativeModule().uniffi_dbx_tools_google_checksum_method_googleauth_logout() !== 28220) {
|
|
533
536
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_logout");
|
|
534
537
|
}
|
|
535
|
-
if (nativeModule().uniffi_dbx_tools_google_checksum_method_googleauth_refresh_rejected_token() !==
|
|
538
|
+
if (nativeModule().uniffi_dbx_tools_google_checksum_method_googleauth_refresh_rejected_token() !== 47983) {
|
|
536
539
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_refresh_rejected_token");
|
|
537
540
|
}
|
|
538
541
|
if (nativeModule().uniffi_dbx_tools_google_checksum_method_googleauth_status() !== 21388) {
|
|
539
542
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_status");
|
|
540
543
|
}
|
|
541
|
-
if (nativeModule().uniffi_dbx_tools_google_checksum_method_googleauth_token() !==
|
|
544
|
+
if (nativeModule().uniffi_dbx_tools_google_checksum_method_googleauth_token() !== 53387) {
|
|
542
545
|
throw new UniffiInternalError.ApiChecksumMismatch("uniffi_dbx_tools_google_checksum_method_googleauth_token");
|
|
543
546
|
}
|
|
544
547
|
|