2022-03-03 18:43:36 +03:00
|
|
|
import 'package:pigeon/pigeon.dart';
|
|
|
|
|
2022-03-24 19:39:12 +03:00
|
|
|
class UnlockResponse {
|
|
|
|
bool? isUnlocked;
|
|
|
|
bool? isRemembered;
|
|
|
|
}
|
|
|
|
|
2022-03-03 18:43:36 +03:00
|
|
|
@HostApi()
|
|
|
|
abstract class OathApi {
|
|
|
|
@async
|
|
|
|
void reset();
|
|
|
|
|
|
|
|
@async
|
2022-03-24 19:39:12 +03:00
|
|
|
UnlockResponse unlock(String password, bool remember);
|
2022-03-03 18:43:36 +03:00
|
|
|
|
|
|
|
@async
|
2022-03-22 13:07:28 +03:00
|
|
|
void setPassword(String? currentPassword, String newPassword);
|
2022-03-03 18:43:36 +03:00
|
|
|
|
|
|
|
@async
|
|
|
|
void unsetPassword(String currentPassword);
|
|
|
|
|
|
|
|
@async
|
|
|
|
void forgetPassword();
|
|
|
|
|
|
|
|
@async
|
|
|
|
String addAccount(String uri, bool requireTouch);
|
|
|
|
|
|
|
|
@async
|
2022-03-22 13:07:28 +03:00
|
|
|
String renameAccount(String uri, String name, String? issuer);
|
2022-03-03 18:43:36 +03:00
|
|
|
|
|
|
|
@async
|
|
|
|
void deleteAccount(String uri);
|
|
|
|
|
|
|
|
@async
|
|
|
|
String refreshCodes();
|
|
|
|
|
|
|
|
@async
|
|
|
|
String calculate(String uri);
|
|
|
|
}
|
|
|
|
|
|
|
|
@HostApi()
|
|
|
|
abstract class AppApi {
|
|
|
|
@async
|
|
|
|
void setContext(int subPageIndex);
|
|
|
|
}
|
|
|
|
|
|
|
|
@FlutterApi()
|
|
|
|
abstract class FOathApi {
|
|
|
|
@async
|
|
|
|
void updateSession(String sessionJson);
|
|
|
|
|
|
|
|
@async
|
|
|
|
void updateOathCredentials(String credentialListJson);
|
|
|
|
}
|
|
|
|
|
|
|
|
@FlutterApi()
|
|
|
|
abstract class FManagementApi {
|
|
|
|
@async
|
|
|
|
void updateDeviceInfo(String deviceInfoJson);
|
|
|
|
}
|
|
|
|
|
|
|
|
@FlutterApi()
|
|
|
|
abstract class FDialogApi {
|
|
|
|
@async
|
2022-03-16 11:13:31 +03:00
|
|
|
void showDialogApi(String dialogMessage);
|
2022-03-03 18:43:36 +03:00
|
|
|
|
|
|
|
@async
|
|
|
|
void closeDialogApi();
|
|
|
|
}
|
|
|
|
|
|
|
|
@HostApi()
|
|
|
|
abstract class HDialogApi {
|
|
|
|
@async
|
|
|
|
void dialogClosed();
|
|
|
|
}
|