CloudBaseAuth class

Constructors

CloudBaseAuth(CloudBaseCore core)
factory

Properties

cache → AuthCache
no setterinherited
config → CloudBaseConfig
no setterinherited
core → CloudBaseCore
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

forceResetPwd({required String phone, String? code, String? passwd}) Future
getAccessToken() Future<String>
获取 accessToken
inherited
getAuthState() Future<CloudBaseAuthState?>
获取登录状态
getUserInfo() Future<CloudBaseUserInfo>
获取用户信息
hasExpiredAuthState() Future<bool>
是否存在已经过期的登录态 在getAuthStateh获得null以后,可以通过这个接口进一步区分 "没有登录态" 和 "登录态已过期"
linkWithTicket({required String ticket}) Future
绑定自定义登录
linkWithWeChat({required String wxAppId, String wxUniLink = "", bool? withUnionId = false}) Future
绑定微信
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
refreshAccessToken() Future<void>
刷新 accessToken
inherited
sendPhoneCode({required String phone}) Future<bool>
setAuthType(CloudBaseAuthType authType) Future<void>
inherited
setRefreshToken(String refreshToken) Future<void>
inherited
signInAnonymously() Future<CloudBaseAuthState>
匿名登录
signInByWx({required String wxAppId, required String wxUniLink}) Future<CloudBaseAuthState>
微信登录
signInWithPhone({required String phone, String? code, String? passwd}) Future
signInWithTicket({required String ticket}) Future<CloudBaseAuthState>
自定义登录
signOut() Future<void>
登出
signUpWithPhone({required String phone, String? code, String? passwd}) Future
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited