MethodChannelAliAuth class
阿里云一键登录类 原来的全屏登录和dialog 统一有配置参数isDislog来控制
- Inheritance
-
- Object
- PlatformInterface
- AliAuthPlatform
- MethodChannelAliAuth
Constructors
Properties
- appleLogin → Future
-
苹果登录iOS专用
no setteroverride
- checkCellularDataEnable → Future
-
no setteroverride
- eventChannel → EventChannel
-
声明监听回调通道
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- methodChannel → MethodChannel
-
声明回调通道
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
checkAuthAvailable(
String accessToken, String jwtToken, dynamic success(dynamic), dynamic error(dynamic)) → Future< void> -
调用之前先去用户服务端获取accessToken和jwtToken
inherited
-
dispose(
) → dynamic -
销毁监听
override
-
getConnection(
) → Future< String?> -
inherited
-
getCurrentCarrierName(
) → Future< String> -
强制关闭一键登录授权页面
override
-
getPlatformVersion(
) → Future< String?> -
override
-
getSdkVersion(
) → Future< String?> -
override
-
getVerifyToken(
dynamic success(dynamic), dynamic error(dynamic)) → Future< void> -
身份鉴权成功后才可调用获取Token接口。
inherited
-
initSdk(
AliAuthModel? config) → Future -
初始化SDK sk 必须
isDialog 是否使用Dialog 弹窗登录 非必须 默认值false 非Dialog登录
debug 是否开启调试模式 非必须 默认true 开启
使用一键登录传入 SERVICE_TYPE_LOGIN 2 使用号码校验传入 SERVICE_TYPE_AUTH 1 默认值 2
override
-
login(
{int timeout = 5000}) → Future -
一键登录
override
-
loginListen(
{bool type = true, required Function onEvent, Function? onError, dynamic isOnlyOne = true}) → dynamic -
数据监听
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
onChange(
{bool type = true}) → Stream? -
初始化监听
override
-
openPage(
String? pageRoute) → Future< void> -
pageRoute
override
-
pause(
) → dynamic -
暂停
override
-
quitPage(
) → Future< void> -
强制关闭一键登录授权页面
override
-
resume(
) → dynamic -
恢复
override
-
setLoggerEnable(
bool isEnable) → Future< void> -
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- onListener ↔ Stream?
-
监听器
getter/setter pair
- streamSubscription ↔ StreamSubscription?
-
为了控制Stream 暂停。恢复。取消监听 新建
getter/setter pair